[issue19524] ResourceWarning when urlopen() forgets the HTTPConnection object

Martin Panter report at bugs.python.org
Sat Dec 28 23:36:02 CET 2013


Martin Panter added the comment:

Just discovered the same fix of manually closing the socket object was already made independently of my patch in the “default” branch! See Issue 12692.

http://hg.python.org/cpython/rev/92656b5df2f2

The main difference is my patch should also close the connection if HTTPConnection.getresponse() fails, which could be of some value. And the regression test could still be useful.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19524>
_______________________________________


More information about the Python-bugs-list mailing list