mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-28 14:46:55 +08:00
Fix various __all__-related typos and omissions (#7378)
This commit is contained in:
@@ -10,6 +10,9 @@ if sys.platform == "win32":
|
||||
__all__ = ("pipe", "Popen", "PIPE", "PipeHandle")
|
||||
else:
|
||||
__all__ = ["socketpair", "pipe", "Popen", "PIPE", "PipeHandle"]
|
||||
import socket
|
||||
|
||||
socketpair = socket.socketpair
|
||||
|
||||
class _WarnFunction(Protocol):
|
||||
def __call__(
|
||||
|
||||
@@ -6,7 +6,7 @@ from types import TracebackType
|
||||
from typing import Any, Callable, Iterable, Iterator, TextIO
|
||||
from typing_extensions import Literal
|
||||
|
||||
__all__ = ["FTP", "error_reply", "error_temp", "error_perm", "error_proto", "all_errors"]
|
||||
__all__ = ["FTP", "error_reply", "error_temp", "error_perm", "error_proto", "all_errors", "FTP_TLS"]
|
||||
|
||||
MSG_OOB: Literal[1]
|
||||
FTP_PORT: Literal[21]
|
||||
|
||||
@@ -20,7 +20,8 @@ __all__ = [
|
||||
"normalize",
|
||||
"LC_CTYPE",
|
||||
"LC_COLLATE",
|
||||
"LC_MESSAGES" "LC_TIME",
|
||||
"LC_MESSAGES",
|
||||
"LC_TIME",
|
||||
"LC_MONETARY",
|
||||
"LC_NUMERIC",
|
||||
"LC_ALL",
|
||||
|
||||
@@ -62,6 +62,7 @@ if sys.version_info >= (3, 8):
|
||||
"get_context",
|
||||
"get_logger",
|
||||
"get_start_method",
|
||||
"parent_process",
|
||||
"log_to_stderr",
|
||||
"reducer",
|
||||
"set_executable",
|
||||
|
||||
@@ -11,6 +11,11 @@ from multiprocessing.sharedctypes import SynchronizedArray, SynchronizedBase
|
||||
from typing import Any, TypeVar, Union, overload
|
||||
from typing_extensions import Literal
|
||||
|
||||
if sys.version_info >= (3, 8):
|
||||
__all__ = ()
|
||||
else:
|
||||
__all__: list[str] = []
|
||||
|
||||
_LockLike = Union[synchronize.Lock, synchronize.RLock]
|
||||
_CT = TypeVar("_CT", bound=_CData)
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@ class RegexFlag(enum.IntFlag):
|
||||
T = sre_compile.SRE_FLAG_TEMPLATE
|
||||
TEMPLATE = T
|
||||
if sys.version_info >= (3, 11):
|
||||
NO_FLAG: int
|
||||
NOFLAG: int
|
||||
|
||||
A = RegexFlag.A
|
||||
ASCII = RegexFlag.ASCII
|
||||
@@ -146,7 +146,7 @@ UNICODE = RegexFlag.UNICODE
|
||||
T = RegexFlag.T
|
||||
TEMPLATE = RegexFlag.TEMPLATE
|
||||
if sys.version_info >= (3, 11):
|
||||
NO_FLAG = RegexFlag.NO_FLAG
|
||||
NOFLAG = RegexFlag.NOFLAG
|
||||
_FlagsType = Union[int, RegexFlag]
|
||||
|
||||
if sys.version_info < (3, 7):
|
||||
|
||||
@@ -155,14 +155,12 @@ else:
|
||||
"AsyncGeneratorType",
|
||||
"MethodType",
|
||||
"BuiltinFunctionType",
|
||||
"ClassMethodDescriptorType",
|
||||
"ModuleType",
|
||||
"TracebackType",
|
||||
"FrameType",
|
||||
"GetSetDescriptorType",
|
||||
"MemberDescriptorType",
|
||||
"new_class",
|
||||
"resolve_bases",
|
||||
"prepare_class",
|
||||
"DynamicClassAttribute",
|
||||
"coroutine",
|
||||
|
||||
@@ -16,5 +16,4 @@ hashlib.scrypt
|
||||
os.startfile
|
||||
|
||||
# Exists at runtime, but missing from stubs
|
||||
asyncio.windows_utils.socketpair
|
||||
venv.EnvBuilder.include_binary
|
||||
|
||||
Reference in New Issue
Block a user