[Twisted-Python] Re: Re: Re: rewrite of flow.py completed
Clark C. Evans
cce at clarkevans.com
Wed Apr 16 17:14:39 EDT 2003
On Wed, Apr 16, 2003 at 02:03:06PM +0200, Philippe Lafoucrière wrote:
| I solved the problem. It was a missing import (QueryIterator). But any
| exception is raised when using flow. It's too hard to debug, even for few
| lines of code.
The flow module should be much better in 'debug' land now
as I think I'm capturing exceptions correctly. By default,
the DeferredFlow object catches exceptions and uses
deferred's errback. It also allows you to pass a
callable which creates a generator, in case you
forget to use () to invoke.
If you want the old behavior (compatible with the default
behavior of DeferredList) then use failureAsResult to
treat failure objects the same as any other result,
returning a list of results to the callback.
More information about the Twisted-Python