[issue18879] tempfile.NamedTemporaryFile can close the file too early, if not assigning to a variable

Zdeněk Pavlas report at bugs.python.org
Fri Nov 29 16:02:41 CET 2013


Zdeněk Pavlas added the comment:

Hit this issue too, but with the "read" method.  I think that providing a custom read() and write() methods in the wrapper class that override __getattr__ is a sufficient solution. These are the attributes most likely to be used as the "tail".

----------
nosy: +Zdeněk.Pavlas

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


More information about the Python-bugs-list mailing list