tzickel <icebr...@yahoo.com> added the comment:

Reverting the code will cause another class of problems, like the reason I 
fixed it. Programs written such as the example that Pablo gave (and what I've 
seen) will quietly leak child processes, file descriptors (for the pipes) and 
memory to a variety degree might not be detected, or in the end detected in a 
big error or crash.

Also in some ResourceWarnings (if not all), the resources are closed in the end 
(like in sockets), here without this code patch you cannot implicitly reclaim 
the resources (because there is a Thread involved here), which I think is a 
high bar for the user to think about.

You can also enable multiprocessing's debug logging to see how the code behaves 
with and without the fix:
https://stackoverflow.com/a/1353037

I also agree with Pablo that there is code in the stdlib that holdes reference 
between child and parent. There is also code that has circular reference (for 
example Python 2's OrderedDict) and that is ok as well (not that this is the 
situation here).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue34172>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to