[Buildbot-devel] sleep in buildbot.process.buildstep.BuildStep

Boris Savelev boris.savelev at gmail.com
Mon Sep 9 07:22:59 UTC 2013


Oh! Wonderful. Thanks!
It works for me.

Now I return defer in .start() with callback that have inline callback -)
Twisted is magic...

2013/9/6 Dustin J. Mitchell <dustin at v.igoro.us>:
> You are correct.  Twisted Python is an asynchronous programming
> environment, where just about everything occurs in the main thread.
> So time.sleep is a big mistake.
>
> There are some basic how-to guides for Twisted, and a style guide in
> the Buildbot documentation (in the developer section).  You will
> probably want to use
>
>   yield task.deferLater(60)
>
> within an @defer.inlineCallbacks-decorated method.
>
> Among other things, see
> https://twistedmatrix.com/documents/11.0.0/core/howto/time.html
>
> Dustin



-- 
Boris




More information about the devel mailing list