[ python-Bugs-918368 ] urllib doesn't correct server returned urls
SourceForge.net
noreply at sourceforge.net
Thu Mar 18 17:38:22 EST 2004
Bugs item #918368, was opened at 2004-03-17 22:41
Message generated for change (Comment added) made by robzed
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=918368&group_id=5470
Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Rob Probin (robzed)
Assigned to: Nobody/Anonymous (nobody)
Summary: urllib doesn't correct server returned urls
Initial Comment:
On a URL request where the server returns a URL with spaces in,
urllib doesn't correct it before requesting the new page.
I think this is technically a server error, however, it does work
from web browsers (Mozilla, Safari) but not from Python urllib.
I would suggest that when urllib is following "moved temporarily"
links (or similar) from a server it translates spaces to %20.
See example program file for more including detailed server/client
transactions text.
----------------------------------------------------------------------
>Comment By: Rob Probin (robzed)
Date: 2004-03-18 22:38
Message:
Logged In: YES
user_id=1000470
I've tested a change to "redirect_internal(self, url, fp, errcode, errmsg,
headers, data)" in "urllib.py" that adds a single line newurl =
newurl.replace(" ","%20") after the basejoin() function call that appears
to fix the problem.
This information is placed in the public domain.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=918368&group_id=5470
More information about the Python-bugs-list
mailing list