[Stackless] stackless.run() returns tuple????

Paul Sijben sijben at eemvalley.com
Sun Jul 15 10:13:14 CEST 2007

I will send some sample code when I reproduce it reliably in a testscript.

However what I am seeing is that val=stackless.run() at some random
point terminates and then val contains: (a float,(1,[]))
This is the format I use in the channels I use as queues, the float is
the result of calling time.time()

Going back in my trace to what was in that queue at that time I see that
the [] was a /filled/ list. Well the value has already been collected
from the queue, so I assume for the time being that the garbage
collector has removed the contents. Now I do not know what makes
stackless.run() terminate like this, but the value seems to be what was
on the stack when it did....

And of course I am running my project in multiple threads (I already
have set the script to only one CPU).

Also the problem started because I replaced timedchannels with regular
ones because the timed ones cost way too much time. The code is muuuuuch
faster now but with this undesirable side-effect.


Christian Tismer wrote:
> On 14.07.2007, at 12:32, Paul Sijben wrote:
>> BTW: on closer inspection the tuple is likely the value in a channel
>> Paul Sijben wrote:
>>> What does it mean if stackless.run() returns a tuple to me? Shouldn't
>>> that function only return when the rest of the tasklets have
>>> terminated???
> Paul,
> this makes little sense without sample code.
> thanks -- chris
> --
> Christian Tismer             :^)   <mailto:tismer at stackless.com>
> tismerysoft GmbH             :     Have a break! Take a ride on Python's
> Johannes-Niemeyer-Weg 9A     :    *Starship* http://starship.python.net/
> 14109 Berlin                 :     PGP key -> http://wwwkeys.pgp.net/
> work +49 30 802 86 56  mobile +49 173 24 18 776  fax +49 30 80 90 57 05
> PGP 0x57F3BF04       9064 F4E1 D754 C2FF 1619  305B C09C 5A3B 57F3 BF04
>       whom do you want to sponsor today?   http://www.stackless.com/
> ------------------------------------------------------------------------
> _______________________________________________
> Stackless mailing list
> Stackless at stackless.com
> http://www.stackless.com/mailman/listinfo/stackless

Paul Sijben                    	tel: +31334566488
Eemvalley Technology       	fax: +31334557523
the Netherlands                	http://eemvalley.com    

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.stackless.com/pipermail/stackless/attachments/20070715/25f4364e/attachment.htm>
-------------- next part --------------
Stackless mailing list
Stackless at stackless.com

More information about the Stackless mailing list