multiprocessing deadlock

Gabriel Genellina gagsl-py2 at yahoo.com.ar
Sat Oct 24 04:49:00 EDT 2009


En Sat, 24 Oct 2009 02:48:38 -0300, Brian Quinlan <brian at sweetapp.com>  
escribió:
> On 24 Oct 2009, at 14:10, Gabriel Genellina wrote:
>> En Thu, 22 Oct 2009 23:18:32 -0300, Brian Quinlan <brian at sweetapp.com>  
>> escribió:
>>
>> I don't like a few things in the code:
>
> I'm actually not looking for workarounds. I want to know if this is a  
> multiprocessing bug or if I am misunderstanding the multiprocessing docs  
> somehow and my demonstrated usage pattern is somehow incorrect.

Those aren't really workarounds, but things to consider when trying to  
narrow down what's causing the problem. The example is rather long as it  
is, and it's hard to tell what's wrong since there are many places thay  
might fail. The busy wait might be relevant, or not; having a thousand  
zombie processes might be relevant, or not.

I don't have an OSX system to test, but on Windows your code worked fine;  
although removing the busy wait and joining the processes made for a  
better work load (with the original code, usually only one of the  
subprocesses in each run grabbed all items from the queue)

-- 
Gabriel Genellina




More information about the Python-list mailing list