diff --git a/stdlib/@tests/stubtest_allowlists/py313.txt b/stdlib/@tests/stubtest_allowlists/py313.txt index 3b02a73ab..e153e52f5 100644 --- a/stdlib/@tests/stubtest_allowlists/py313.txt +++ b/stdlib/@tests/stubtest_allowlists/py313.txt @@ -12,9 +12,7 @@ _ctypes.pointer _ctypes.sizeof _thread.interrupt_main _thread.lock -_thread.stack_size _thread.start_joinable_thread -_thread.start_new_thread _tkinter.create asyncio.AbstractEventLoop.create_server asyncio.AbstractServer.abort_clients @@ -111,7 +109,6 @@ site.register_readline sre_compile.SRE_FLAG_TEMPLATE sre_constants.SRE_FLAG_TEMPLATE sre_parse.SRE_FLAG_TEMPLATE -threading.stack_size tkinter.Misc.after_info tkinter.Misc.busy tkinter.Misc.busy_cget diff --git a/stdlib/_thread.pyi b/stdlib/_thread.pyi index 4ea9aa060..304cb79ec 100644 --- a/stdlib/_thread.pyi +++ b/stdlib/_thread.pyi @@ -13,7 +13,7 @@ error = RuntimeError def _count() -> int: ... @final class LockType: - def acquire(self, blocking: bool = ..., timeout: float = ...) -> bool: ... + def acquire(self, blocking: bool = True, timeout: float = -1) -> bool: ... def release(self) -> None: ... def locked(self) -> bool: ... def __enter__(self) -> bool: ... @@ -22,14 +22,14 @@ class LockType: ) -> None: ... @overload -def start_new_thread(function: Callable[[Unpack[_Ts]], object], args: tuple[Unpack[_Ts]]) -> int: ... +def start_new_thread(function: Callable[[Unpack[_Ts]], object], args: tuple[Unpack[_Ts]], /) -> int: ... @overload -def start_new_thread(function: Callable[..., object], args: tuple[Any, ...], kwargs: dict[str, Any]) -> int: ... +def start_new_thread(function: Callable[..., object], args: tuple[Any, ...], kwargs: dict[str, Any], /) -> int: ... def interrupt_main() -> None: ... def exit() -> NoReturn: ... def allocate_lock() -> LockType: ... def get_ident() -> int: ... -def stack_size(size: int = ...) -> int: ... +def stack_size(size: int = 0, /) -> int: ... TIMEOUT_MAX: float diff --git a/stdlib/threading.pyi b/stdlib/threading.pyi index 1ecadef50..c441a0468 100644 --- a/stdlib/threading.pyi +++ b/stdlib/threading.pyi @@ -61,7 +61,7 @@ if sys.version_info >= (3, 10): def gettrace() -> TraceFunction | None: ... def getprofile() -> ProfileFunction | None: ... -def stack_size(size: int = ...) -> int: ... +def stack_size(size: int = 0, /) -> int: ... TIMEOUT_MAX: float