[Twisted-Python] non-blocking and non-blocking.
lists at itamarst.org
Wed Nov 14 04:25:42 EST 2001
Kevin Turner wrote:
> So, if you run something like the following through manhole:
> def spam(n=300):
> for i in xrange(n):
> print "iiIiiIiI", i
> the whole mess comes back when the command has finished completion, and
> receiving that much data seems to take the protocol-decoder a while to
> decode. Long enough that it can cause a hiccup, or outright stall, in
> the GUI. So it might be nice to do that processing in incremental bit
> so it shares time better. In twisted.python terms, it'd be in a Looping
> construct, or in GTK terms, you'd add it on an idle handler.
Or, you could return a Deferred and dispatch the action to be done by a
More information about the Twisted-Python