You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2002-09-25.19:22:58.000>created_at=<Date2002-08-06.19:26:03.000>labels= ['library']
title='Fix "file:" URL to have right no. of /\'s'updated_at=<Date2002-09-25.19:22:58.000>user='https://bugs.python.org/callenish'
If you run urlparse.urljoin() on a file: URL, the resulting URL
has together with the wrong number of '/'s in it.
Properly formed, the URL (assuming no netloc) should have
three slashes, so that it looks like "file:///...". The current
code drops that down to one.
The error appears to be in a condition in urlunsplit(). It
doesn't show up except in this one instance because the
test is only run iff the scheme is in the list of those that can
take a netloc and there is no netloc present in the URL.
Apparently, this is pretty rare.
Activity
callenish commentedon Aug 6, 2002
If you run urlparse.urljoin() on a file: URL, the resulting URL
has together with the wrong number of '/'s in it.
Properly formed, the URL (assuming no netloc) should have
three slashes, so that it looks like "file:///...". The current
code drops that down to one.
The error appears to be in a condition in urlunsplit(). It
doesn't show up except in this one instance because the
test is only run iff the scheme is in the list of those that can
take a netloc and there is no netloc present in the URL.
Apparently, this is pretty rare.
Patch attached that corrects the condition.
nnorwitz commentedon Sep 17, 2002
Logged In: YES
user_id=33168
Not sure who is best to review this? Fred? Jeremy?
Someone else?
This patch works for me. I have a test too. Assign back to
me if you want me to check it in.
freddrake commentedon Sep 25, 2002
Logged In: YES
user_id=3066
Looks good to me; go ahead and check it in with the tests.
Thanks!
nnorwitz commentedon Sep 25, 2002
Logged In: YES
user_id=33168
Checked in as: