mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-10-17 11:31:25 +08:00
Use Final for undocumented constants (#12450)
This commit is contained in:
1 parent
1f4d0a815f
commit
9a77f6006d
10 files changed
+60
-61
No files matched your search
@@ -2,7 +2,7 @@ import sys
|
||||
from _typeshed import ReadableBuffer, StrOrBytesPath
|
||||
from collections.abc import Callable, Collection, Iterable, Mapping, Sequence
|
||||
from types import TracebackType
|
||||
from typing import IO, Any, AnyStr, Generic, Literal, TypeVar, overload
|
||||
from typing import IO, Any, AnyStr, Final, Generic, Literal, TypeVar, overload
|
||||
from typing_extensions import Self, TypeAlias
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
@@ -74,8 +74,8 @@ _T = TypeVar("_T")
|
||||
|
||||
# These two are private but documented
|
||||
if sys.version_info >= (3, 11):
|
||||
_USE_VFORK: bool
|
||||
_USE_POSIX_SPAWN: bool
|
||||
_USE_VFORK: Final[bool]
|
||||
_USE_POSIX_SPAWN: Final[bool]
|
||||
|
||||
class CompletedProcess(Generic[_T]):
|
||||
# morally: _CMD
|
||||
@@ -1810,9 +1810,9 @@ else:
|
||||
text: bool | None = None,
|
||||
) -> Any: ... # morally: -> str | bytes
|
||||
|
||||
PIPE: int
|
||||
STDOUT: int
|
||||
DEVNULL: int
|
||||
PIPE: Final[int]
|
||||
STDOUT: Final[int]
|
||||
DEVNULL: Final[int]
|
||||
|
||||
class SubprocessError(Exception): ...
|
||||
|
||||
|
||||
Reference in new issue
Block a user