[issue2464] urllib2 can't handle http://www.wikispaces.com

Senthil report at bugs.python.org
Fri May 16 05:08:07 CEST 2008


Senthil <orsenthil at users.sourceforge.net> added the comment:

The issue is not just with null character. If you observe now the
diretion is 302-302-200 and there is no null character.
However, still urllib2 is unable to handle multiple redirection properly
(IIRC, there is a portion of code to handle multiple redirection and
exit on infinite loop)
>>> url = "http://www.wikispaces.com"
>>> opened = urllib.urlopen(url)
>>> print opened.geturl()
http://www.wikispaces.com?responseToken=344289da354a29c67d48928dbe72042a
>>> print opened.read()
<html>
<head><title>400 Bad Request</title></head>
<body bgcolor="white">
<center><h1>400 Bad Request</h1></center>
<hr><center>nginx/0.6.30</center>
</body>
</html>

Needs a relook, IMO.

----------
nosy: +orsenthil

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2464>
__________________________________


More information about the Python-bugs-list mailing list