Skip to content

Commit bc805f6

Browse files
authored
[multiprocessing] Update BaseListProxy, multiprocessing.managers.list (#15070)
1 parent 8dcca56 commit bc805f6

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

stdlib/@tests/stubtest_allowlists/py314.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
# ====================================================================
44

55
multiprocessing.managers.BaseListProxy.clear
6+
# inspect.signature gives the wrong signature
67
multiprocessing.managers.BaseListProxy.copy
78
multiprocessing.managers.DictProxy.__ior__
89
multiprocessing.managers._BaseDictProxy.__ior__

stdlib/multiprocessing/managers.pyi

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,8 @@ class BaseListProxy(BaseProxy, MutableSequence[_T]):
192192
def count(self, value: _T, /) -> int: ...
193193
def insert(self, index: SupportsIndex, object: _T, /) -> None: ...
194194
def remove(self, value: _T, /) -> None: ...
195+
if sys.version_info >= (3, 14):
196+
def copy(self) -> list[_T]: ...
195197
# Use BaseListProxy[SupportsRichComparisonT] for the first overload rather than [SupportsRichComparison]
196198
# to work around invariance
197199
@overload
@@ -326,8 +328,9 @@ class SyncManager(BaseManager):
326328
def dict(self, iterable: Iterable[list[str]], /) -> DictProxy[str, str]: ...
327329
@overload
328330
def dict(self, iterable: Iterable[list[bytes]], /) -> DictProxy[bytes, bytes]: ...
331+
# Overloads are copied from builtins.list.__init__
329332
@overload
330-
def list(self, sequence: Sequence[_T], /) -> ListProxy[_T]: ...
333+
def list(self, iterable: Iterable[_T], /) -> ListProxy[_T]: ...
331334
@overload
332335
def list(self) -> ListProxy[Any]: ...
333336
if sys.version_info >= (3, 14):

0 commit comments

Comments
 (0)