Re: [Twisted-Python] stop conditions and deferToThread()

2009-06-12 Thread Thomas Jakobsen
Thanks for the replies. In my particular case, adding a global running as Tim Allen pointed out, actually did it. Regards, Thomas ___ Twisted-Python mailing list Twisted-Python@twistedmatrix.com http://twistedmatrix.com/cgi-bin/mailman/listinfo/tw

Re: [Twisted-Python] stop conditions and deferToThread()

2009-06-10 Thread Jean-Paul Calderone
On Wed, 10 Jun 2009 12:04:16 +0200, Thomas Jakobsen wrote: >Hi > >As discussed in a previous thread > > http://twistedmatrix.com/pipermail/twisted-python/2009-May/019717.html > >a task put in its own thread via deferToThread() won't stop even >though the reactor has stopped. It has to carry out

Re: [Twisted-Python] stop conditions and deferToThread()

2009-06-10 Thread Tim Allen
I'm not sure this is the problem you're facing, but... On Wed, Jun 10, 2009 at 12:04:16PM +0200, Thomas Jakobsen wrote: > import time > from twisted.internet import reactor > from twisted.internet.threads import deferToThread > > running = True > > def foo(): >while running: >print "

Re: [Twisted-Python] stop conditions and deferToThread()

2009-06-10 Thread Phil Mayers
Thomas Jakobsen wrote: > Hi > > As discussed in a previous thread > >http://twistedmatrix.com/pipermail/twisted-python/2009-May/019717.html > > a task put in its own thread via deferToThread() won't stop even > though the reactor has stopped. It has to carry out its own check that > the reac