[Twisted-Python] How to force synchronous behavior

Scott Lamb slamb at slamb.org
Sat Oct 29 13:41:45 EDT 2005

On 29 Oct 2005, at 09:50, Jean-Paul Calderone 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.
> Because there seems to be so much confusion on this point,
> let me re-iterate Itamar's response:
> deferredResult is *broken*.  It does not work now.  It never
> worked in the past.  If you use it, your program will suck and
> die and you will be sad and the only advise you will get
> to fix it will be to stop using deferredResult, which will
> probably mean rewriting a significant portion of your program,
> since you cannot write asynchronous programs synchronously and
> expect them to work.
> This is not a conditional point.  It does not depend on
> anything.  It is a simple, unavoidable fact.  Disregard it at
> your own certain peril.

Why does twisted contain functions which are never to be used? If it  
can't be fixed, why not remove it?

Scott Lamb <http://www.slamb.org/>

More information about the Twisted-Python mailing list