It's not intuitively clear why multiple yielding the same Defferred in
function decorated with defer.inlineCallbacks get different results:

 

@defer.inlineCallbacks

def f():

                d = defer.succeed(1)

                result = yield d

print result

                result = yield d

print result

 

Output:

1

None

 

Probably we SHOULD NOT think if "d" was or was not yielded before when using
inlineCallbacks..

 

Are they some workarounds?

 

_______________________________________________
Twisted-Python mailing list
Twisted-Python@twistedmatrix.com
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Reply via email to