Skip to content

Commit b6a3d5f

Browse files
authored
Correct return type of asyncio.AbstractEventLoop.getaddrinfo and analogs in subclasses (#15788)
1 parent 4c28d1d commit b6a3d5f

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

stdlib/asyncio/base_events.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ class BaseEventLoop(AbstractEventLoop):
115115
type: int = 0,
116116
proto: int = 0,
117117
flags: int = 0,
118-
) -> list[tuple[AddressFamily, SocketKind, int, str, tuple[str, int] | tuple[str, int, int, int]]]: ...
118+
) -> list[tuple[AddressFamily, SocketKind, int, str, tuple[str, int] | tuple[str, int, int, int] | tuple[int, bytes]]]: ...
119119
async def getnameinfo(self, sockaddr: tuple[str, int] | tuple[str, int, int, int], flags: int = 0) -> tuple[str, str]: ...
120120

121121
if sys.version_info >= (3, 12):

stdlib/asyncio/events.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ class AbstractEventLoop:
205205
type: int = 0,
206206
proto: int = 0,
207207
flags: int = 0,
208-
) -> list[tuple[AddressFamily, SocketKind, int, str, tuple[str, int] | tuple[str, int, int, int]]]: ...
208+
) -> list[tuple[AddressFamily, SocketKind, int, str, tuple[str, int] | tuple[str, int, int, int] | tuple[int, bytes]]]: ...
209209
@abstractmethod
210210
async def getnameinfo(self, sockaddr: tuple[str, int] | tuple[str, int, int, int], flags: int = 0) -> tuple[str, str]: ...
211211

0 commit comments

Comments
 (0)