asyncio icon indicating copy to clipboard operation
asyncio copied to clipboard

Add abc.Awaitable, abc.Coroutine and abc.Generator classes to asyncio

Open 1st1 opened this issue 10 years ago • 2 comments

I think we could package in a fallback module for collections.abc (similarly to what we do with selectors.py) to have better support for generators & coroutines compiled with Cython.

1st1 avatar Jun 27 '15 02:06 1st1

See also http://bugs.python.org/msg245776

1st1 avatar Jun 27 '15 02:06 1st1

I updated the backports_abc package. It now has an explicit installation procedure. I also added a pure-ABC implementation of inspect.isawaitable() as there is no other way to produce an Awaitable in pre-3.5 CPython versions than by implementing __await__().

I think it's ready to become a dependency of the asyncio backports now.

For reference:

https://pypi.python.org/pypi/backports_abc

https://github.com/cython/backports_abc

scoder avatar Jul 03 '15 20:07 scoder