[New-bugs-announce] [issue15755] subprocess.poll() does not handle errno.ECHILD "No child processes"
report at bugs.python.org
Tue Aug 21 21:07:25 CEST 2012
New submission from Todd Whiteman:
In the case of a "errno.ECHILD" exception - Python's subprocess module misses the fact that the process has already ended.
The following code will wait indefinitely, even though the launched process is quickly ended:
import subprocess, signal
p = subprocess.Popen(['echo','foo'])
while p.poll() is None:
pass # wait for the process to exit
Note: This is the exact same issue as issue1731717, but applying to the subprocess.poll() method instead of the subprocess.wait() method.
components: Library (Lib)
nosy: gregory.p.smith, twhitema
title: subprocess.poll() does not handle errno.ECHILD "No child processes"
versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce