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 2121import sys
2222import threading
2323import weakref
24- from asyncio import TimeoutError , wait_for
24+ from asyncio import wait_for
2525from typing import Any , Optional , TypeVar
2626
2727import pymongo ._asyncio_lock
3333
3434_T = TypeVar ("_T" )
3535
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
3738if sys .version_info >= (3 , 13 ):
3839 Lock = asyncio .Lock
3940 Condition = asyncio .Condition
@@ -83,7 +84,7 @@ def _release_locks() -> None:
8384async def _async_cond_wait (condition : Condition , timeout : Optional [float ]) -> bool :
8485 try :
8586 return await wait_for (condition .wait (), timeout )
86- except TimeoutError :
87+ except asyncio . TimeoutError :
8788 return False
8889
8990
You can’t perform that action at this time.
0 commit comments