Yury Selivanov added the comment:
The patch looks good. 2 things:
- It appears it also touches Misc/NEWS a bit too much. Please make sure to not
to commit that.
- I'd also add a comment explaining why we ignore values passed to FI.send()
and simply send None. The reason is how Future.__iter__ is designed:
class Future:
def __iter__(self):
if not self.done():
self._asyncio_future_blocking = True
yield self # This tells Task to wait for completion.
assert self.done(), "yield from wasn't used with future"
return self.result() # May raise too.
^-- Future.__iter__ doesn't care about values that are pushed to the generator,
it just returns "self.result()".
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue28430>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com