We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent deab1e5 commit 5c30145Copy full SHA for 5c30145
Doc/library/asyncio-task.rst
@@ -293,6 +293,10 @@ Sleeping
293
``sleep()`` always suspends the current task, allowing other tasks
294
to run.
295
296
+ Setting the delay to 0 provides an optimized path to allow other
297
+ tasks to run. This can be used by long-running functions to avoid
298
+ blocking the event loop for the full duration of the function call.
299
+
300
.. _asyncio_example_sleep:
301
302
Example of coroutine displaying the current date every second
0 commit comments