[issue9205] Parent process hanging in multiprocessing if children terminate unexpectedly

Ask Solem report at bugs.python.org
Wed Jul 14 16:05:04 CEST 2010


Ask Solem <askh at opera.com> added the comment:

Jesse wrote,


> We can work around the shutdown issue (really, bug 9207) by
> ignoring the exception such as shutdown.patch does, or passing in
> references/adding references to the functions those methods need. Or (as Brett suggested) converting them to class methods and adding references to the class. Or passing them in via the signature like this _handle_workers(arg, _debug=debug), etc.


Greg wrote,

> Another option would be to enable only for the worker handler.  I
> don't have a particularly great sense of what the Right Thing to
> do here is.

I don't think _make_shutdown_safe should be added to the result handler.
If the error can indeed happen there, then we need to solve it in a way that enables it to finish the work.

Jesse, how hard is it to fix the worker handler by passing the references? Note that _worker_handler is not important to complete shutdown at this point, but it may be in the future (it seems termination.patch already changes this)

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue9205>
_______________________________________


More information about the Python-bugs-list mailing list