diff --git a/stdlib/_thread.pyi b/stdlib/_thread.pyi index 152362edc..dba8664fb 100644 --- a/stdlib/_thread.pyi +++ b/stdlib/_thread.pyi @@ -43,3 +43,6 @@ if sys.version_info >= (3, 8): @property def thread(self) -> Thread | None: ... _excepthook: Callable[[_ExceptHookArgs], Any] + +if sys.version_info >= (3, 12): + def daemon_threads_allowed() -> bool: ... diff --git a/tests/stubtest_allowlists/py312.txt b/tests/stubtest_allowlists/py312.txt index 32258bef9..373b7c9c2 100644 --- a/tests/stubtest_allowlists/py312.txt +++ b/tests/stubtest_allowlists/py312.txt @@ -1,6 +1,5 @@ # Uncategorised, from Python 3.12 _ctypes.SIZEOF_TIME_T -_thread.daemon_threads_allowed argparse.BooleanOptionalAction.__init__ array.array.__class_getitem__ asyncio.BaseEventLoop.create_connection