Patches item #1462790, was opened at 2006-04-01 20:33
Message generated for change (Comment added) made by gbrandl
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1462790&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Library (Lib)
Group: Python 2.5
>Status: Closed
>Resolution: Accepted
Priority: 5
Submitted By: John J Lee (jjlee)
Assigned to: Nobody/Anonymous (nobody)
Summary: urllib2.ProxyHandler broken recently for non-userinfo case

Initial Comment:
urllib2.ProxyHandler was broken by rev 42133, for
authorities that do not contain a userinfo component
(i.e. when the joe:password bit in
joe:[EMAIL PROTECTED]:port is missing).

Example code to trigger the bug (raises TypeError):

import urllib2
proxy_handler = urllib2.ProxyHandler({"http":
"localhost:3128"})
urllib2.build_opener(proxy_handler).open('http://python.org/')


The patch allows use of the :port notation as 42133
intended, but preserves correct userinfo handling.

The patch also adds a unit test for ProxyHandler, and a
doctest for parsing of proxy specification strings
(which may either be a URL with authority or just an
authority).


----------------------------------------------------------------------

>Comment By: Georg Brandl (gbrandl)
Date: 2006-04-02 20:45

Message:
Logged In: YES 
user_id=849994

Patch looks good (and comes with test, which is very
important for code quality). Thanks very much!

(rev. 43553)

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1462790&group_id=5470
_______________________________________________
Patches mailing list
[email protected]
http://mail.python.org/mailman/listinfo/patches

Reply via email to