summaryrefslogtreecommitdiffstats
path: root/Doc/library/asyncio-api-index.rst
diff options
context:
space:
mode:
authorKyle Stanley <aeros167@gmail.com>2020-05-19 03:03:28 (GMT)
committerGitHub <noreply@github.com>2020-05-19 03:03:28 (GMT)
commitcc2bbc2227c3f5ed9d8f6b3bd052e6f9e68279d2 (patch)
tree84839ab8dd6cc9969c3bb7516e20715a8273fb33 /Doc/library/asyncio-api-index.rst
parentd4fe098d1ee4f4056ac65cae55f5ffdd439dede0 (diff)
downloadcpython-cc2bbc2227c3f5ed9d8f6b3bd052e6f9e68279d2.zip
cpython-cc2bbc2227c3f5ed9d8f6b3bd052e6f9e68279d2.tar.gz
cpython-cc2bbc2227c3f5ed9d8f6b3bd052e6f9e68279d2.tar.bz2
bpo-32309: Implement asyncio.to_thread() (GH-20143)
Implements `asyncio.to_thread`, a coroutine for asynchronously running IO-bound functions in a separate thread without blocking the event loop. See the discussion starting from [here](https://github.com/python/cpython/pull/18410#issuecomment-628930973) in GH-18410 for context. Automerge-Triggered-By: @aeros
Diffstat (limited to 'Doc/library/asyncio-api-index.rst')
-rw-r--r--Doc/library/asyncio-api-index.rst3
1 files changed, 3 insertions, 0 deletions
diff --git a/Doc/library/asyncio-api-index.rst b/Doc/library/asyncio-api-index.rst
index d5b5659..047e5bb 100644
--- a/Doc/library/asyncio-api-index.rst
+++ b/Doc/library/asyncio-api-index.rst
@@ -48,6 +48,9 @@ await on multiple things with timeouts.
* - :class:`Task`
- Task object.
+ * - :func:`to_thread`
+ - Asychronously run a function in a separate OS thread.
+
* - :func:`run_coroutine_threadsafe`
- Schedule a coroutine from another OS thread.