[issue10554] Context managerment support for subprocess.Popen

Brian Curtin report at bugs.python.org
Fri Dec 3 03:12:16 CET 2010


Brian Curtin <curtin at acm.org> added the comment:

I updated the doc to be much more simple. I got used to sys.executable based tests :) New patch attached.

As for __del__, I think it should do it's thing, and the exit will do it's own. Context managers are traditionally used on file-based things, or things that can be opened or closed. Creating a Popen object will open one or more pipes, so we should just close those opened pipes.

----------
Added file: http://bugs.python.org/file19917/subprocess2.diff

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


More information about the Python-bugs-list mailing list