Skip to content

Add set() to multiprocessing.managers.SyncManager #129948

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
mmingyu opened this issue Feb 10, 2025 · 0 comments · Fixed by #129949
Closed

Add set() to multiprocessing.managers.SyncManager #129948

mmingyu opened this issue Feb 10, 2025 · 0 comments · Fixed by #129949
Labels
stdlib Python modules in the Lib dir topic-multiprocessing type-feature A feature request or enhancement

Comments

@mmingyu
Copy link
Contributor

mmingyu commented Feb 10, 2025

Feature or enhancement

Proposal:

The SyncManager provides support for various data structures such as dict, list, and queue, but oddly, it does not support set. This inconsistency feels little bit weird.

Unless there is a specific reason, I propose adding support for set as well.

from multiprocessing import managers

managers.SyncManager.set()
set.add('foo')
# ... something else ...

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Linked PRs

@mmingyu mmingyu added the type-feature A feature request or enhancement label Feb 10, 2025
mmingyu added a commit to mmingyu/cpython that referenced this issue Feb 10, 2025
@mmingyu mmingyu changed the title Add set() Support to multiprocessing.managers.SyncManager Add set() to multiprocessing.managers.SyncManager Feb 10, 2025
@picnixz picnixz added the stdlib Python modules in the Lib dir label Feb 11, 2025
gpshead added a commit that referenced this issue Feb 23, 2025
…9949)

The SyncManager provided support for various data structures such as dict, list, and queue, but oddly, not set.
This introduces support for set by defining SetProxy and registering it with SyncManager.

---
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
seehwan pushed a commit to seehwan/cpython that referenced this issue Apr 16, 2025
python#129949)

The SyncManager provided support for various data structures such as dict, list, and queue, but oddly, not set.
This introduces support for set by defining SetProxy and registering it with SyncManager.

---
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stdlib Python modules in the Lib dir topic-multiprocessing type-feature A feature request or enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants