[Stackless] Problems with removing tasklet.

Håvard Engum Havard.Engum at idi.ntnu.no
Wed Oct 9 08:54:21 CEST 2002


Hello!

I have been having problems with removing tasklets that are running.

I am only calling the remove() method for the tasklet which has
a reference in a list. Here agenttasklets is the list:

self.agenttasklets[agentID].remove()

I am getting this error-message:

File "controller.py", line 232, in _removeAgent
    self.agenttasklets[agentID].remove()
RuntimeError: The current tasklet cannot be removed. Use
t=tasklet().capture()

We have tried using:

temp = stackless.tasklet(self.agenttasklets[agentID]).capture()
temp.remove()

But without much luck.

Does anyone know a solution for this?


-- 
Håvard Engum

_______________________________________________
Stackless mailing list
Stackless at www.tismer.com
http://www.tismer.com/mailman/listinfo/stackless



More information about the Stackless mailing list