[docs] [issue29344] sock_recv not detected a coroutine
Yury Selivanov
report at bugs.python.org
Wed Feb 1 15:06:00 EST 2017
Yury Selivanov added the comment:
I think the original idea was to document that all methods of the loop are coroutines, so that:
1. if a user needs a Future object they call ensure_future:
fut = asyncio.ensure_future(loop.method())
2. it gives us ability to refactor things. For instance, sock_connect was a method that returned Futures, but at one point of 3.5 we changed it to be coroutine. Because the method was documented as a coroutine, it wasn't strictly a backwards incompatible way.
In general, I think it would be safer for us to simple make all loop methods coroutines. Or, less radical, just keeping the status quo: document everything as a coroutine.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue29344>
_______________________________________
More information about the docs
mailing list