Drop support for Python 3.5 (#4675)

Python 3.5 EOL was on 2020-09-30.
This commit is contained in:
Sebastian Rittau
2020-11-02 16:18:20 +01:00
committed by GitHub
parent 57b86e0e71
commit d2a7889fe0
64 changed files with 546 additions and 1174 deletions

View File

@@ -34,8 +34,7 @@ class BaseEventLoop(AbstractEventLoop, metaclass=ABCMeta):
def is_running(self) -> bool: ...
def is_closed(self) -> bool: ...
def close(self) -> None: ...
if sys.version_info >= (3, 6):
async def shutdown_asyncgens(self) -> None: ...
async def shutdown_asyncgens(self) -> None: ...
# Methods scheduling callbacks. All these return Handles.
if sys.version_info >= (3, 7):
def call_soon(self, callback: Callable[..., Any], *args: Any, context: Optional[Context] = ...) -> Handle: ...

View File

@@ -3,8 +3,7 @@ import sys
LOG_THRESHOLD_FOR_CONNLOST_WRITES: int
ACCEPT_RETRY_DELAY: int
if sys.version_info >= (3, 6):
DEBUG_STACK_DEPTH: int
DEBUG_STACK_DEPTH: int
if sys.version_info >= (3, 7):
SSL_HANDSHAKE_TIMEOUT: float
SENDFILE_FALLBACK_READBUFFER_SIZE: int

View File

@@ -33,8 +33,6 @@ class Future(Awaitable[_T], Iterable[_T]):
_exception: BaseException
_blocking = False
_log_traceback = False
if sys.version_info < (3, 6):
_tb_logger: Type[_TracebackLogger]
def __init__(self, *, loop: Optional[AbstractEventLoop] = ...) -> None: ...
def __repr__(self) -> str: ...
def __del__(self) -> None: ...

View File

@@ -48,13 +48,7 @@ class _SSLProtocolTransport(transports._FlowControlMixin, transports.Transport):
_loop: events.AbstractEventLoop
_ssl_protocol: SSLProtocol
_closed: bool
if sys.version_info >= (3, 6):
def __init__(self, loop: events.AbstractEventLoop, ssl_protocol: SSLProtocol) -> None: ...
else:
def __init__(
self, loop: events.AbstractEventLoop, ssl_protocol: SSLProtocol, app_protocol: protocols.BaseProtocol
) -> None: ...
def __init__(self, loop: events.AbstractEventLoop, ssl_protocol: SSLProtocol) -> None: ...
def get_extra_info(self, name: str, default: Optional[Any] = ...) -> Dict[str, Any]: ...
def set_protocol(self, protocol: protocols.BaseProtocol) -> None: ...
def get_protocol(self) -> protocols.BaseProtocol: ...

View File

@@ -9,9 +9,8 @@ class BaseTransport:
def get_extra_info(self, name: Any, default: Any = ...) -> Any: ...
def is_closing(self) -> bool: ...
def close(self) -> None: ...
if sys.version_info >= (3, 5):
def set_protocol(self, protocol: BaseProtocol) -> None: ...
def get_protocol(self) -> BaseProtocol: ...
def set_protocol(self, protocol: BaseProtocol) -> None: ...
def get_protocol(self) -> BaseProtocol: ...
class ReadTransport(BaseTransport):
if sys.version_info >= (3, 7):