Finding the source of an exception in a python multiprocessing program

William Ray Wing wrw at mac.com
Wed Apr 24 17:09:20 EDT 2013


On Apr 24, 2013, at 4:31 PM, Neil Cerutti <neilc at norwich.edu> wrote:

> On 2013-04-24, William Ray Wing <wrw at mac.com> wrote:
>> When I look at the pool module, the error is occurring in
>> get(self, timeout=None) on the line after the final else:
>> 
>>    def get(self, timeout=None):
>>        self.wait(timeout)
>>        if not self._ready:
>>            raise TimeoutError
>>        if self._success:
>>            return self._value
>>        else:
>>            raise self._value
> 
> The code that's failing is in self.wait. Somewhere in there you
> must be masking an exception and storing it in self._value
> instead of letting it propogate and crash your program. This is
> hiding the actual context.
> 
> -- 
> Neil Cerutti
> -- 
> http://mail.python.org/mailman/listinfo/python-list

I'm sorry, I'm not following you.  The "get" routine (and thus self.wait) is part of the "pool" module in the Python multiprocessing library.
None of my code has a class or function named "get".

-Bill




More information about the Python-list mailing list