Opened 10 years ago

Closed 10 years ago

#3829 closed (fixed)

Windows setup failed

Reported by: gjgaughan@… Owned by: Adrian Holovaty
Component: Tools Version: 0.96
Severity: Keywords:
Cc: dev@… Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

I could be doing something daft, but I had to change the following line in setup.py:

package = dirpath[len_root_dir:].lstrip('/').replace('/', '.')

to:

package = dirpath[len_root_dir:].lstrip('
').replace('
', '.')

to make it install under Windows.

Attachments (1)

3829.diff (545 bytes) - added by Gary Wilson <gary.wilson@…> 10 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 Changed 10 years ago by Simon G. <dev@…>

Cc: dev@… added
Component: UncategorizedTools
Owner: changed from Jacob to Adrian Holovaty

Hmm. That does look like we're assuming a *nix enviroment. Can someone else who runs windows confirm this?

comment:2 Changed 10 years ago by gjgaughan@…

If it is a problem, this would be better (assuming os.path is imported):

package = dirpath[len_root_dir:].lstrip(os.path.sep).replace(os.path.sep, '.')

comment:3 Changed 10 years ago by gjgaughan@…

Or better:

package = dirpath[len_root_dir:].lstrip(os.path.sep).replace(os.path.sep, os.path.curdir)

Changed 10 years ago by Gary Wilson <gary.wilson@…>

Attachment: 3829.diff added

comment:4 Changed 10 years ago by Gary Wilson <gary.wilson@…>

Has patch: set
Patch needs improvement: set
Triage Stage: UnreviewedAccepted

Just noticed that this line also uses lstrip() which isn't available in Python 2.3, is it?

comment:5 Changed 10 years ago by Malcolm Tredinnick

Gary, lstrip and rstrip are both in 2.3.

comment:6 Changed 10 years ago by Gary Wilson <gary.wilson@…>

Patch needs improvement: unset

Cool, I was confusing with rsplit. I don't have access to a windows machine, would someone who does like to test the patch?

comment:7 Changed 10 years ago by Malcolm Tredinnick

Resolution: fixed
Status: newclosed

This was fixed in a different way in [4912].

Note: See TracTickets for help on using tickets.
Back to Top