Skip to content

Commit 0c2dae4

Browse files
authored
[multiprocessing] Update to 3.14 (#15427)
1 parent de55f7f commit 0c2dae4

File tree

2 files changed

+26
-15
lines changed

2 files changed

+26
-15
lines changed

stdlib/@tests/stubtest_allowlists/py314.txt

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,3 @@
1-
# ====================================================================
2-
# TODO: New errors in Python 3.14 that need to be fixed or moved below
3-
# ====================================================================
4-
5-
multiprocessing.managers.BaseListProxy.clear
6-
# inspect.signature gives the wrong signature
7-
multiprocessing.managers.BaseListProxy.copy
8-
multiprocessing.managers.DictProxy.__ior__
9-
multiprocessing.managers._BaseDictProxy.__ior__
10-
multiprocessing.managers._BaseDictProxy.__or__
11-
multiprocessing.managers._BaseDictProxy.__reversed__
12-
multiprocessing.managers._BaseDictProxy.__ror__
13-
multiprocessing.managers._BaseDictProxy.fromkeys
14-
15-
161
# =========================
172
# New errors in Python 3.14
183
# =========================
@@ -100,6 +85,9 @@ multiprocessing.managers._BaseSetProxy.__len__
10085
multiprocessing.managers._BaseSetProxy.clear
10186
multiprocessing.managers._BaseSetProxy.copy
10287
multiprocessing.managers._BaseSetProxy.pop
88+
multiprocessing.managers.BaseListProxy.clear
89+
multiprocessing.managers.BaseListProxy.copy
90+
multiprocessing.managers._BaseDictProxy.__reversed__
10391

10492

10593
# =============================================================

stdlib/multiprocessing/managers.pyi

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ from .util import Finalize as _Finalize
2626
__all__ = ["BaseManager", "SyncManager", "BaseProxy", "Token", "SharedMemoryManager"]
2727

2828
_T = TypeVar("_T")
29+
_T1 = TypeVar("_T1")
30+
_T2 = TypeVar("_T2")
2931
_KT = TypeVar("_KT")
3032
_VT = TypeVar("_VT")
3133
_S = TypeVar("_S")
@@ -94,6 +96,25 @@ if sys.version_info >= (3, 13):
9496
def keys(self) -> list[_KT]: ... # type: ignore[override]
9597
def items(self) -> list[tuple[_KT, _VT]]: ... # type: ignore[override]
9698
def values(self) -> list[_VT]: ... # type: ignore[override]
99+
if sys.version_info >= (3, 14):
100+
# Next methods are copied from builtins.dict
101+
@overload
102+
def fromkeys(self, iterable: Iterable[_T], value: None = None, /) -> dict[_T, Any | None]: ...
103+
@overload
104+
def fromkeys(self, iterable: Iterable[_T], value: _S, /) -> dict[_T, _S]: ...
105+
def __reversed__(self) -> Iterator[_KT]: ...
106+
@overload
107+
def __or__(self, value: dict[_KT, _VT], /) -> dict[_KT, _VT]: ...
108+
@overload
109+
def __or__(self, value: dict[_T1, _T2], /) -> dict[_KT | _T1, _VT | _T2]: ...
110+
@overload
111+
def __ror__(self, value: dict[_KT, _VT], /) -> dict[_KT, _VT]: ...
112+
@overload
113+
def __ror__(self, value: dict[_T1, _T2], /) -> dict[_KT | _T1, _VT | _T2]: ...
114+
@overload # type: ignore[misc]
115+
def __ior__(self, value: SupportsKeysAndGetItem[_KT, _VT], /) -> Self: ...
116+
@overload
117+
def __ior__(self, value: Iterable[tuple[_KT, _VT]], /) -> Self: ...
97118

98119
class DictProxy(_BaseDictProxy[_KT, _VT]):
99120
def __class_getitem__(cls, args: Any, /) -> GenericAlias: ...
@@ -193,6 +214,8 @@ class BaseListProxy(BaseProxy, MutableSequence[_T]):
193214
def insert(self, index: SupportsIndex, object: _T, /) -> None: ...
194215
def remove(self, value: _T, /) -> None: ...
195216
if sys.version_info >= (3, 14):
217+
# Next methods are copied from builtins.list
218+
def clear(self) -> None: ...
196219
def copy(self) -> list[_T]: ...
197220
# Use BaseListProxy[SupportsRichComparisonT] for the first overload rather than [SupportsRichComparison]
198221
# to work around invariance

0 commit comments

Comments
 (0)