From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Sat, 26 Apr 2025 19:46:11 +0000 (+0200) Subject: [3.13] gh-133016: Fix a reference to removed `asyncio.futures.TimeoutError` (GH-13301... X-Git-Tag: v3.13.4~216 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3a1a2a0b4989c2c47973f40a18e863879a8631b3;p=thirdparty%2FPython%2Fcpython.git [3.13] gh-133016: Fix a reference to removed `asyncio.futures.TimeoutError` (GH-133019) (#133023) gh-133016: Fix a reference to removed `asyncio.futures.TimeoutError` (GH-133019) Just use the builtin `TimeoutError`, and remove the import of `futures`. (cherry picked from commit 8d6d7386a35b4a6fdd7d599f2184780bb83cc306) Co-authored-by: John --- diff --git a/Lib/test/test_asyncio/utils.py b/Lib/test/test_asyncio/utils.py index ce2408fc1aab..d9a2939be13e 100644 --- a/Lib/test/test_asyncio/utils.py +++ b/Lib/test/test_asyncio/utils.py @@ -28,7 +28,6 @@ except ImportError: # pragma: no cover from asyncio import base_events from asyncio import events from asyncio import format_helpers -from asyncio import futures from asyncio import tasks from asyncio.log import logger from test import support @@ -120,7 +119,7 @@ def run_until(loop, pred, timeout=support.SHORT_TIMEOUT): loop.run_until_complete(tasks.sleep(delay)) delay = max(delay * 2, 1.0) else: - raise futures.TimeoutError() + raise TimeoutError() def run_once(loop):