[Twisted-Python] how to implement sleep?

Itamar Turner-Trauring itamar at itamarst.org
Sun Sep 19 09:20:53 EDT 2010

On Sun, 2010-09-19 at 22:41 +1000, Andrew Bennetts wrote:
> ruslan usifov wrote:
> >    Hello
> > 
> >    Twisted is great, but how cant i emulate sleep behaviour in syested. I
> <http://twistedmatrix.com/documents/10.1.0/api/twisted.internet.task.deferLater.html>

Specifically, deferLater is a wrapper for reactor.callLater that works
well with inlineCallbacks, since it returns a Deferred, so you can do
"yield deferLater(reactor, 3, lambda: None)".

More information about the Twisted-Python mailing list