[Twisted-Python] understanding deferreds

Andrew Bennetts andrew at bemusement.org
Sat Jan 30 02:16:01 EST 2010

twisted-web at udmvt.ru wrote:
> Is it true, that adding many callback functions as filters is elegant,
> but impractical solution?
> Since there is only a [linear] list of pairs (callback, errback), the last errbacks
> have to be complex to distinguish the failures, that came from the previous callback
> from failures, that traverse the errback chain from the beginning.

This is no different to regular Python code, which has a linear call stack which
can have exception handlers at any point on the stack.  The exact same tradeoffs
apply about which exceptions to raise and which to catch, and at what points.


More information about the Twisted-Python mailing list