Controlling source IP address within urllib2

John J. Lee jjl at
Wed Jun 8 01:02:57 CEST 2005

"Dan" <tojuso at> writes:

> John,
> Thanks for your input.  I can kind of see the light in this, but I'm
> having difficulty knowing where the "do_open" method comes from.  Also,


> I'll need to follow redirects, so I assume then I would add a
> HTTPRedirectHandler instance to the urllib2.build_opener. (?)  Thanks

No.  It does that by default.


More information about the Python-list mailing list