2 from _typeshed import StrOrBytesPath
3 from os import PathLike, _ExecEnv, _ExecVArgs, stat_result as stat_result
4 from typing import Any, Iterable, NamedTuple, Sequence, Tuple, overload
5 from typing_extensions import final
8 class uname_result(NamedTuple):
16 class times_result(NamedTuple):
20 children_system: float
23 if sys.platform != "darwin":
24 class waitid_result(NamedTuple):
31 class sched_param(NamedTuple):
67 if sys.platform == "linux":
93 if sys.platform != "darwin":
94 POSIX_FADV_DONTNEED: int
95 POSIX_FADV_NOREUSE: int
96 POSIX_FADV_NORMAL: int
97 POSIX_FADV_RANDOM: int
98 POSIX_FADV_SEQUENTIAL: int
99 POSIX_FADV_WILLNEED: int
109 if sys.platform == "linux":
122 if sys.platform == "linux":
125 if sys.platform != "darwin":
126 SCHED_RESET_ON_FORK: int
146 def WCOREDUMP(__status: int) -> bool: ...
147 def WEXITSTATUS(status: int) -> int: ...
148 def WIFCONTINUED(status: int) -> bool: ...
149 def WIFEXITED(status: int) -> bool: ...
150 def WIFSIGNALED(status: int) -> bool: ...
151 def WIFSTOPPED(status: int) -> bool: ...
155 def WSTOPSIG(status: int) -> int: ...
156 def WTERMSIG(status: int) -> int: ...
165 def listdir(path: str | None = ...) -> list[str]: ...
167 def listdir(path: bytes) -> list[bytes]: ...
169 def listdir(path: int) -> list[str]: ...
171 def listdir(path: PathLike[str]) -> list[str]: ...
173 if sys.platform != "win32" and sys.version_info >= (3, 8):
175 path: StrOrBytesPath,
179 file_actions: Sequence[Tuple[Any, ...]] | None = ...,
180 setpgroup: int | None = ...,
181 resetids: bool = ...,
183 setsigmask: Iterable[int] = ...,
184 setsigdef: Iterable[int] = ...,
185 scheduler: tuple[Any, sched_param] | None = ...,
188 path: StrOrBytesPath,
192 file_actions: Sequence[Tuple[Any, ...]] | None = ...,
193 setpgroup: int | None = ...,
194 resetids: bool = ...,
196 setsigmask: Iterable[int] = ...,
197 setsigdef: Iterable[int] = ...,
198 scheduler: tuple[Any, sched_param] | None = ...,
201 if sys.platform == "win32":
202 environ: dict[str, str]
204 environ: dict[bytes, bytes]