asyncio currently uses iterable coroutine directly to wrap awaitables with __await__ methods. This leads to unnecessary special casing and is confusing as asyncio does not supports using yield from now so it should not be used internally too. This will avoid checking for generators everywhere in public APIs (TBD for different issue).
kumaraditya303 commentedDec 8, 2022
•
edited
asyncio
currently uses iterable coroutine directly to wrap awaitables with__await__
methods. This leads to unnecessary special casing and is confusing asasyncio
does not supports usingyield from
now so it should not be used internally too. This will avoid checking for generators everywhere in public APIs (TBD for different issue).Linked PRs
_wrap_awaitable
as a coroutine inasyncio
internally #100128The text was updated successfully, but these errors were encountered: