]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-101498 : Fix asyncio.Timeout example in docs (GH-101499)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Wed, 1 Feb 2023 18:19:11 +0000 (10:19 -0800)
committerGitHub <noreply@github.com>
Wed, 1 Feb 2023 18:19:11 +0000 (10:19 -0800)
Doc/library/asyncio-task.rstGH-timeout
(cherry picked from commit 95fb0e02582b5673eff49694eb0dce1d7df52301)

Co-authored-by: Raj <51259329+workingpayload@users.noreply.github.com>
Doc/library/asyncio-task.rst

index 24e43c3cbfcb93006acd57248c3117153ca22ac1..1fd7afad99a8303c674513ac79b39b17dcb7d963 100644 (file)
@@ -666,7 +666,7 @@ Timeouts
             except TimeoutError:
                 pass
 
-            if cm.expired:
+            if cm.expired():
                 print("Looks like we haven't finished on time.")
 
     Timeout context managers can be safely nested.