[issue28777] Add asyncio.Queue __aiter__, __anext__ methods
Matt Rasband
report at bugs.python.org
Fri Aug 18 09:32:10 EDT 2017
Matt Rasband added the comment:
I attempted this myself, it seemed to have too many costs associated for the stdlib and is something easy enough to wrap myself when I need this functionality with explicit semantics on how to "stop" the queue (using an `object()` sentinel). My implementation is flawed as the sentinel is global, instead of per queue instance, if you decide to use this at all.
See https://github.com/python/asyncio/pull/445
----------
nosy: +Matt Rasband
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28777>
_______________________________________
More information about the Python-bugs-list
mailing list