diff --git a/stdlib/os/__init__.pyi b/stdlib/os/__init__.pyi index 7d4b8adcd..e92dd7a09 100644 --- a/stdlib/os/__init__.pyi +++ b/stdlib/os/__init__.pyi @@ -33,6 +33,9 @@ from . import path as _path if sys.version_info >= (3, 9): from types import GenericAlias +if sys.platform != "win32": + from resource import struct_rusage + # This unnecessary alias is to work around various errors path = _path @@ -962,8 +965,8 @@ else: def waitid(__idtype: int, __ident: int, __options: int) -> waitid_result | None: ... - def wait3(options: int) -> tuple[int, int, Any]: ... - def wait4(pid: int, options: int) -> tuple[int, int, Any]: ... + def wait3(options: int) -> tuple[int, int, struct_rusage]: ... + def wait4(pid: int, options: int) -> tuple[int, int, struct_rusage]: ... def WCOREDUMP(__status: int) -> bool: ... def WIFCONTINUED(status: int) -> bool: ... def WIFSTOPPED(status: int) -> bool: ...