Jon Dufresne added the comment:

I decided to try a new direction.

Instead of modifying _TemporaryFileCloser to handle urllib, I've changed urllib 
classes to not inherit from _TemporaryFileCloser. The urllib classes are not 
temporary files as built by tempfile, so I believe this makes more sense. There 
is a small amount of code copied to the existing class, but I believe this 
cleans up the inheritance in a way that makes more sense for the given objects 
and requires fewer workarounds.

All feedback on this alternative approach is welcome. Thanks.

----------
Added file: 
http://bugs.python.org/file45852/namedtemporaryfile-resourcewarning-4.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue28867>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to