[issue34476] asyncio.sleep(0) not documented

Andrew Svetlov report at bugs.python.org
Sun Sep 30 02:26:47 EDT 2018


Andrew Svetlov <andrew.svetlov at gmail.com> added the comment:

`asyncio.sleep()` always pauses the current task and switches execution to another one.
`asyncio.sleep(0)` has no special meaning (but it has internal optimization for the case).

Basically the same as `time.sleep(0)` for multithreaded program.

I doubt if we need to blow the documentation with all possible related details.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34476>
_______________________________________


More information about the Python-bugs-list mailing list