diff --git a/stdlib/@tests/stubtest_allowlists/py314.txt b/stdlib/@tests/stubtest_allowlists/py314.txt index 0fcdcbb84d97..76d0408730dd 100644 --- a/stdlib/@tests/stubtest_allowlists/py314.txt +++ b/stdlib/@tests/stubtest_allowlists/py314.txt @@ -40,6 +40,9 @@ concurrent.interpreters._queues.UNBOUND_REMOVE importlib.util.Loader.exec_module # See Lib/importlib/_abc.py. Might be defined for backwards compatibility +# Condition functions are exported in __init__ +threading.Condition.locked +multiprocessing.dummy.Condition.locked # ==================================== # Pre-existing errors from Python 3.13 diff --git a/stdlib/threading.pyi b/stdlib/threading.pyi index 7b0f15bdfa2e..8a2b68dcd1cf 100644 --- a/stdlib/threading.pyi +++ b/stdlib/threading.pyi @@ -144,6 +144,9 @@ class Condition: ) -> None: ... def acquire(self, blocking: bool = True, timeout: float = -1) -> bool: ... def release(self) -> None: ... + if sys.version_info >= (3, 14): + def locked(self) -> bool: ... + def wait(self, timeout: float | None = None) -> bool: ... def wait_for(self, predicate: Callable[[], _T], timeout: float | None = None) -> _T: ... def notify(self, n: int = 1) -> None: ...