File tree Expand file tree Collapse file tree 2 files changed +396
-396
lines changed Expand file tree Collapse file tree 2 files changed +396
-396
lines changed Original file line number Diff line number Diff line change 21
21
import sys
22
22
import threading
23
23
import weakref
24
- from asyncio import TimeoutError , wait_for
24
+ from asyncio import wait_for
25
25
from typing import Any , Optional , TypeVar
26
26
27
27
import pymongo ._asyncio_lock
33
33
34
34
_T = TypeVar ("_T" )
35
35
36
- # Needed to support 3.13 asyncio fixes in older versions of Python
36
+ # Needed to support 3.13 asyncio fixes (https://github.com/python/cpython/issues/112202)
37
+ # in older versions of Python
37
38
if sys .version_info >= (3 , 13 ):
38
39
Lock = asyncio .Lock
39
40
Condition = asyncio .Condition
@@ -83,7 +84,7 @@ def _release_locks() -> None:
83
84
async def _async_cond_wait (condition : Condition , timeout : Optional [float ]) -> bool :
84
85
try :
85
86
return await wait_for (condition .wait (), timeout )
86
- except TimeoutError :
87
+ except asyncio . TimeoutError :
87
88
return False
88
89
89
90
You can’t perform that action at this time.
0 commit comments