New submission from Pau Aliagas <[EMAIL PROTECTED]>: I wanted to use urllib2 with something as usual as binding to a given network interface and it was incredibly complex. I also did not like the usual propodes solution to timeout the connections: set the global socket timeour. I needed a different timeout for each connection.
So I took my time, I learnt about httplib and urllib2 and made a patch to enhance both libraries. BindingHTTPConnectionWithTimeout extends HTTPConection with supports timeouts and a binding address. BindingHTTPHandlerWithTimeout extends HTTPHandler and basically uses the new http class provided. The patch is really simple and would make a great addition to the standard library. I've tried to follow the style amd copied similar methods, giving the due credits. I hope you find it useful and consider it for inclusion. ---------- components: Library (Lib) files: urllib2_util.py messages: 65215 nosy: pau severity: normal status: open title: BindingHTTPConnectionWithTimeout and BindingHTTPHandlerWithTimeout type: feature request versions: Python 2.4, Python 2.5 Added file: http://bugs.python.org/file9988/urllib2_util.py __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2600> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com