diff --git a/stdlib/asyncio/sslproto.pyi b/stdlib/asyncio/sslproto.pyi index b56b1547db8a..04197c8d2978 100644 --- a/stdlib/asyncio/sslproto.pyi +++ b/stdlib/asyncio/sslproto.pyi @@ -156,9 +156,10 @@ class SSLProtocol(_SSLProtocolBase): def _check_handshake_timeout(self) -> None: ... def _on_handshake_complete(self, handshake_exc: BaseException | None) -> None: ... def _fatal_error(self, exc: BaseException, message: str = "Fatal error on transport") -> None: ... - def _abort(self) -> None: ... if sys.version_info >= (3, 11): + def _abort(self, exc: BaseException | None) -> None: ... def get_buffer(self, n: int) -> memoryview: ... else: + def _abort(self) -> None: ... def _finalize(self) -> None: ... def _process_write_backlog(self) -> None: ... diff --git a/tests/stubtest_allowlists/py312.txt b/tests/stubtest_allowlists/py312.txt index 553717e306f5..aef0bdc20bd6 100644 --- a/tests/stubtest_allowlists/py312.txt +++ b/tests/stubtest_allowlists/py312.txt @@ -124,3 +124,7 @@ typing.SupportsAbs.__type_params__ typing.SupportsRound.__type_params__ typing_extensions.SupportsAbs.__type_params__ typing_extensions.SupportsRound.__type_params__ + +# Dunder that exists on all runtime-checkable protocols on py312+ +# TODO teach stubtest about this so we don't have to allowlist it +.+\.__non_callable_proto_members__