]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.11] Fix a code snippet typo in asyncio docs (GH-108427) (#111244)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 24 Oct 2023 06:35:49 +0000 (08:35 +0200)
committerGitHub <noreply@github.com>
Tue, 24 Oct 2023 06:35:49 +0000 (06:35 +0000)
Co-authored-by: A <5249513+Dumeng@users.noreply.github.com>
Doc/library/asyncio-task.rst

index 0944aef0ab619dfd5aacd9f6a14974fa207c1931..858c2996b87695e901d97970009a12e1f521e60f 100644 (file)
@@ -539,7 +539,7 @@ Shielding From Cancellation
 
    is equivalent to::
 
-       res = await something()
+       res = await shield(something())
 
    *except* that if the coroutine containing it is cancelled, the
    Task running in ``something()`` is not cancelled.  From the point