[docs] [issue19809] Doc: subprocess should warn uses on race conditions when multiple threads spawn child processes
Leonardo Santagada
report at bugs.python.org
Wed Jul 24 08:30:27 EDT 2019
Leonardo Santagada <santagada at gmail.com> added the comment:
This is still the case on windows as the pipes created to talk to the process might be inherited by two or more simultaneous CreateProcess calls.
I've found a suggested solution to this:
https://devblogs.microsoft.com/oldnewthing/20111216-00/?p=8873
By only inheriting the stdout/err/in handles and them supporting close_fds for windows.
Would more users be interested in a proper patch for this? For us now we have a lock around Popen.__init__ but that obviously doesn't suport subinterpreters and other calls to CreateProcess that might happen.
----------
nosy: +santagada
versions: +Python 3.6, Python 3.7, Python 3.8, Python 3.9
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue19809>
_______________________________________
More information about the docs
mailing list