[issue37531] Fix regrtest timeout for subprocesses: regrtest -jN --timeout=SECONDS
Eryk Sun
report at bugs.python.org
Thu Aug 22 11:00:41 EDT 2019
Eryk Sun <eryksun at gmail.com> added the comment:
> It seems like self.stdout.read() hangs even after the child process
> has been killed.
This is an issue when the standard handles are inherited or duplicated to a grandchild process, and so on. In the case of Popen(sys.executable), the system is duplicating the standard handles implicitly because sys.executable is a console process (assuming it's python[_d].exe), among other criteria. An additional reference on the write side prevents the pipe from closing. fh.read() in the grandparent won't return as long as there's a writer that could potentially write more data.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue37531>
_______________________________________
More information about the Python-bugs-list
mailing list