[Twisted-Python] How to force synchronous behavior

Itamar Shtull-Trauring itamar at itamarst.org
Sat Oct 29 12:18:17 EDT 2005

On Sat, 2005-10-29 at 18:02 +0200, Marcin Kasperski wrote:

> There is deferredResult function somewhere in trial (twisted testing) 
> package,  deferredResult(somedeferred)  just waits  for this deferred -  
> yielding control to the reactor  repeatably. This is probably what 
> original poster looks for.

Do not use this function. If you do, we will just point and laugh when
your code breaks :)

However, deferredGenerator in twisted.internet.defer lets you write code
that *looks* synchronous.

More information about the Twisted-Python mailing list