Message92772
I can reproduce the problem (or at least get the same symptom) by doing
this (in 2.4.6, 2.5.4 and 2.6.2):
import subprocess, signal
signal.signal(signal.SIGCLD, signal.SIG_IGN)
subprocess.Popen(['echo','foo']).wait()
The echo command completes, but the subprocess command throws the "no
child" exception. It seems like the subprocess command should either:
- detect that SIGCLD is not set correctly and throw a more informative
exception before running the command.
- override SIGCLD during the running of the sub-command. Not sure what
the UNIX correctness implications of this are.
- or allow the child to zombie without throwing an exception. The fact
that the programmer has overridden SIGCLD sort of implies that reaping
of zombie children has been switched off.
I don't have good enough understanding of the underlying implementation
to know if this is a reproducer as requested or if this should be a new
bug. Please advise and I will file a new bug if requested.
This is a follow-up to trying to resolve this problem in the PEP 3143
python-daemon module. See this thread:
http://groups.google.com/group/comp.lang.python/browse_thread/thread/9a853d0308c8e55a |
|
Date |
User |
Action |
Args |
2009-09-17 15:37:30 | kanaka | set | recipients:
+ kanaka, gvanrossum, nnorwitz, abo, gregory.p.smith, astrand, siemer, exarkun, gjb1002, oefe, christian.heimes, dsagal, tom_culliton, benjamin.peterson, djc, grossetti, r.david.murray, yonas |
2009-09-17 15:37:30 | kanaka | set | messageid: <1253201850.24.0.990574988041.issue1731717@psf.upfronthosting.co.za> |
2009-09-17 15:37:28 | kanaka | link | issue1731717 messages |
2009-09-17 15:37:27 | kanaka | create | |
|