Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions stdlib/@tests/stubtest_allowlists/py313.txt
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ codecs.replace_errors # Runtime incorrectly has `self`
codecs.strict_errors # Runtime incorrectly has `self`
codecs.xmlcharrefreplace_errors # Runtime incorrectly has `self`

# The concrete Unix event loop accepts this Python 3.13 parameter, but the
# abstract runtime signature has not been updated.
asyncio.events.AbstractEventLoop.create_unix_server # parameter `cleanup_socket`

# These multiprocessing proxy methods have *args, **kwargs signatures at runtime,
# But have more precise (accurate) signatures in the stub
multiprocessing.managers._BaseDictProxy.__iter__
Expand Down
4 changes: 4 additions & 0 deletions stdlib/@tests/stubtest_allowlists/py314.txt
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,10 @@ codecs.replace_errors # Runtime incorrectly has `self`
codecs.strict_errors # Runtime incorrectly has `self`
codecs.xmlcharrefreplace_errors # Runtime incorrectly has `self`

# The concrete Unix event loop accepts this Python 3.13 parameter, but the
# abstract runtime signature has not been updated.
asyncio.events.AbstractEventLoop.create_unix_server # parameter `cleanup_socket`

# These multiprocessing proxy methods have *args, **kwargs signatures at runtime,
# But have more precise (accurate) signatures in the stub
multiprocessing.managers._BaseDictProxy.__iter__
Expand Down
4 changes: 4 additions & 0 deletions stdlib/@tests/stubtest_allowlists/py315.txt
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,10 @@ codecs.replace_errors # Runtime incorrectly has `self`
codecs.strict_errors # Runtime incorrectly has `self`
codecs.xmlcharrefreplace_errors # Runtime incorrectly has `self`

# The concrete Unix event loop accepts this Python 3.13 parameter, but the
# abstract runtime signature has not been updated.
asyncio.events.AbstractEventLoop.create_unix_server # parameter `cleanup_socket`

# These multiprocessing proxy methods have *args, **kwargs signatures at runtime,
# but have more precise (accurate) signatures in the stub.
multiprocessing.managers._BaseDictProxy.__iter__
Expand Down
12 changes: 12 additions & 0 deletions stdlib/@tests/test_cases/asyncio/check_events-py313.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
from __future__ import annotations

import asyncio
import sys
from collections.abc import Callable

if sys.version_info >= (3, 13):

async def check_abstract_event_loop_create_unix_server_cleanup_socket(
loop: asyncio.AbstractEventLoop, protocol_factory: Callable[[], asyncio.Protocol]
) -> None:
await loop.create_unix_server(protocol_factory, cleanup_socket=False)
39 changes: 27 additions & 12 deletions stdlib/asyncio/events.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -422,18 +422,33 @@ class AbstractEventLoop:
ssl_handshake_timeout: float | None = None,
ssl_shutdown_timeout: float | None = None,
) -> Transport | None: ...
async def create_unix_server(
self,
protocol_factory: _ProtocolFactory,
path: StrPath | None = None,
*,
sock: socket | None = None,
backlog: int = 100,
ssl: _SSLContext = None,
ssl_handshake_timeout: float | None = None,
ssl_shutdown_timeout: float | None = None,
start_serving: bool = True,
) -> Server: ...
if sys.version_info >= (3, 13):
async def create_unix_server(
self,
protocol_factory: _ProtocolFactory,
path: StrPath | None = None,
*,
sock: socket | None = None,
backlog: int = 100,
ssl: _SSLContext = None,
ssl_handshake_timeout: float | None = None,
ssl_shutdown_timeout: float | None = None,
start_serving: bool = True,
cleanup_socket: bool = True,
) -> Server: ...
else:
async def create_unix_server(
self,
protocol_factory: _ProtocolFactory,
path: StrPath | None = None,
*,
sock: socket | None = None,
backlog: int = 100,
ssl: _SSLContext = None,
ssl_handshake_timeout: float | None = None,
ssl_shutdown_timeout: float | None = None,
start_serving: bool = True,
) -> Server: ...
else:
@abstractmethod
async def start_tls(
Expand Down
Loading