examples scripts

non_blocking Module

Write some non-blocking cooperative code.

non_blocking.do_less_expensive_things(*args, **kwargs)[source]
Perform one expensive computation cooperatively with any
other iterator passed into twisted’s cooperate, then use it’s result to pass into the second computation.
Parameters:number
Returns:
non_blocking.do_some_expensive_things(*args, **kwargs)[source]
Perform one expensive computation cooperatively with any
other iterator passed into twisted’s cooperate, then use it’s result to pass into the second computation.
Parameters:number
Returns:
non_blocking.expensive(number)[source]
non_blocking.expensive2(number)[source]
non_blocking.main(reactor)[source]