mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-18 09:55:59 +08:00
Remove Python 3.6 branches from typeshed (#8269)
This commit is contained in:
@@ -96,21 +96,20 @@ class FileLoader(ResourceLoader, ExecutionLoader, metaclass=ABCMeta):
|
||||
def get_filename(self, name: str | None = ...) -> _Path: ...
|
||||
def load_module(self, name: str | None = ...) -> types.ModuleType: ...
|
||||
|
||||
if sys.version_info >= (3, 7):
|
||||
class ResourceReader(metaclass=ABCMeta):
|
||||
class ResourceReader(metaclass=ABCMeta):
|
||||
@abstractmethod
|
||||
def open_resource(self, resource: StrOrBytesPath) -> IO[bytes]: ...
|
||||
@abstractmethod
|
||||
def resource_path(self, resource: StrOrBytesPath) -> str: ...
|
||||
if sys.version_info >= (3, 10):
|
||||
@abstractmethod
|
||||
def open_resource(self, resource: StrOrBytesPath) -> IO[bytes]: ...
|
||||
def is_resource(self, path: str) -> bool: ...
|
||||
else:
|
||||
@abstractmethod
|
||||
def resource_path(self, resource: StrOrBytesPath) -> str: ...
|
||||
if sys.version_info >= (3, 10):
|
||||
@abstractmethod
|
||||
def is_resource(self, path: str) -> bool: ...
|
||||
else:
|
||||
@abstractmethod
|
||||
def is_resource(self, name: str) -> bool: ...
|
||||
def is_resource(self, name: str) -> bool: ...
|
||||
|
||||
@abstractmethod
|
||||
def contents(self) -> Iterator[str]: ...
|
||||
@abstractmethod
|
||||
def contents(self) -> Iterator[str]: ...
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
@runtime_checkable
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import importlib.abc
|
||||
import importlib.machinery
|
||||
import sys
|
||||
import types
|
||||
from _typeshed import StrOrBytesPath
|
||||
from collections.abc import Callable
|
||||
@@ -39,5 +38,4 @@ class LazyLoader(importlib.abc.Loader):
|
||||
def create_module(self, spec: importlib.machinery.ModuleSpec) -> types.ModuleType | None: ...
|
||||
def exec_module(self, module: types.ModuleType) -> None: ...
|
||||
|
||||
if sys.version_info >= (3, 7):
|
||||
def source_hash(source_bytes: bytes) -> int: ...
|
||||
def source_hash(source_bytes: bytes) -> int: ...
|
||||
|
||||
Reference in New Issue
Block a user