Skip to content

Commit 26ffe74

Browse files
committed
Fix ABC registration for SetProxy in multiprocessing.managers
Register _BaseSetProxy as MutableSet instead of MutableMapping. SetProxy implements set semantics and does not implement the mapping protocol, so the previous ABC registration caused incorrect type classification. Signed-off-by: Yongtao Huang <yongtaoh2022@gmail.com>
1 parent 19c72d2 commit 26ffe74

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/multiprocessing/managers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1224,7 +1224,7 @@ def __isub__(self, value):
12241224

12251225
__class_getitem__ = classmethod(types.GenericAlias)
12261226

1227-
collections.abc.MutableMapping.register(_BaseSetProxy)
1227+
collections.abc.MutableSet.register(_BaseSetProxy)
12281228

12291229

12301230
ArrayProxy = MakeProxyType('ArrayProxy', (

0 commit comments

Comments
 (0)