[Stackless] Killing a tasklet waiting on PyChannel_Receive in C module fails

Chris Jacobson mainecoon at gmail.com
Mon Feb 23 21:31:32 CET 2009

Not directly, though in that case my main concern is how to propagate
the exception upwards - it seems like it gets eaten or ignored if it
occurs when the tasklet is suspended in a C function.

The C++ extensions will be sparse enough that I can handle all channel
receives failing and manually propagate the exception, if this is
possible, but I was under the impression calling PyTasklet_Kill would
do the same as raising an exception, and this fails as well.

- Chris

On Mon, Feb 23, 2009 at 4:24 AM, Richard Tew <richard.m.tew at gmail.com> wrote:
> On Mon, Feb 23, 2009 at 4:24 AM, Chris Jacobson <mainecoon at gmail.com> wrote:
>> If a tasklet that is currently in a C function waiting on a
>> PyChannel_Receive is killed from another tasklet, the receiving
>> tasklet resumes with NULL returned on the Receive, and doesn't die.
> Generally, when an API function returns NULL, it indicates a Python
> exception has happened.  Have you tried looking at what that exception
> is?
> Cheers,
> Richard.

More information about the Stackless mailing list