Views
TwistedOnStackless
last edited 3 years ago by rmtew
TwistedFramework can take advantage of Stackless with some helper functions created by ChristopherArmstrong. The helper functions are located in sandbox/radix/threadless.py in SVN.
From the original announcement:
It offers two functions: blockOn and deferredTasklet.
deferredTasklet is a function decorator that you should use on your stacklessy code that you want to integrate with Twisted.
blockOn is a function that you should pass a Deferred to wait for it to fire. Use it in your stacklessy-code.
There's a TEST function (that's automatically run when you execute the module) that shows this off with some somewhat helpful comments. There are also prints sprinkled throughout the code to show you what's going on.
Stackless Python