Martin Panter added the comment: urllib2_redirect_fix.2.patch adds a test.
I was tempted to remove the whole block of code setting the path to “/”, but there is one minor disadvantage: if a redirect points to a so-called “malformed” URL without any path component, like “http://example.net” or “http://example.net?query”, geturl() would return this URL verbatim. ---------- stage: test needed -> patch review versions: +Python 3.6 Added file: http://bugs.python.org/file39501/urllib2_redirect_fix.2.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14132> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com