[issue4106] multiprocessing occasionally spits out exception during shutdown
report at bugs.python.org
Sat Oct 11 14:36:13 CEST 2008
Skip Montanaro <skip at pobox.com> added the comment:
Final comment before I see some feedback from the experts.
I have this code in the worker function's loop:
# quick pause to allow other stuff to happen a bit randomly
t = 0.1 * random.random()
If I eliminate the sleep altogether pretty much all hell breaks loose.
As I reduce the sleep time it gets noisier and noisier. I switched to
a fixed sleep time and reduced it as far as
At that point it was complaining about killing worker processes on
many of the runs, maybe 1 out of every 5 or 10 runs.
I suppose the moral of the story is to not use multiprocessing except
when you have long-running tasks.
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list