Remove Python 3.6 branches from typeshed (#8269)

This commit is contained in:
Alex Waygood
2022-07-11 09:55:17 +01:00
committed by GitHub
parent 29c17ffb47
commit edc0ecd857
114 changed files with 1016 additions and 2642 deletions

View File

@@ -1,10 +1,8 @@
import sys
from _typeshed import StrPath
from py_compile import PycInvalidationMode
from typing import Any, Protocol
if sys.version_info >= (3, 7):
from py_compile import PycInvalidationMode
__all__ = ["compile_dir", "compile_file", "compile_path"]
class _SupportsSearch(Protocol):
@@ -44,7 +42,7 @@ if sys.version_info >= (3, 9):
hardlink_dupes: bool = ...,
) -> int: ...
elif sys.version_info >= (3, 7):
else:
def compile_dir(
dir: StrPath,
maxlevels: int = ...,
@@ -68,45 +66,12 @@ elif sys.version_info >= (3, 7):
invalidation_mode: PycInvalidationMode | None = ...,
) -> int: ...
else:
def compile_dir(
dir: StrPath,
maxlevels: int = ...,
ddir: StrPath | None = ...,
force: bool = ...,
rx: _SupportsSearch | None = ...,
quiet: int = ...,
legacy: bool = ...,
optimize: int = ...,
workers: int = ...,
) -> int: ...
def compile_file(
fullname: StrPath,
ddir: StrPath | None = ...,
force: bool = ...,
rx: _SupportsSearch | None = ...,
quiet: int = ...,
legacy: bool = ...,
optimize: int = ...,
) -> int: ...
if sys.version_info >= (3, 7):
def compile_path(
skip_curdir: bool = ...,
maxlevels: int = ...,
force: bool = ...,
quiet: int = ...,
legacy: bool = ...,
optimize: int = ...,
invalidation_mode: PycInvalidationMode | None = ...,
) -> int: ...
else:
def compile_path(
skip_curdir: bool = ...,
maxlevels: int = ...,
force: bool = ...,
quiet: int = ...,
legacy: bool = ...,
optimize: int = ...,
) -> int: ...
def compile_path(
skip_curdir: bool = ...,
maxlevels: int = ...,
force: bool = ...,
quiet: int = ...,
legacy: bool = ...,
optimize: int = ...,
invalidation_mode: PycInvalidationMode | None = ...,
) -> int: ...