[issue45254] HAS_SHMEM detection logic is duplicated in implementation and tests

2021-09-28 Thread Łukasz Langa
Łukasz Langa added the comment: The logic is currently duplicated because trying to import `shared_memory` is how support discovery is supposed to work in user code. `multiprocessing.managers` doesn't export HAS_SHMEM (it's not in `__all__` and it's not documented). Making tests rely on it

[issue45254] HAS_SHMEM detection logic is duplicated in implementation and tests

2021-09-24 Thread Terry J. Reedy
Change by Terry J. Reedy : -- nosy: +davin, pitrou versions: -Python 3.8 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue45254] HAS_SHMEM detection logic is duplicated in implementation and tests

2021-09-21 Thread Nikita Sobolev
Change by Nikita Sobolev : -- keywords: +patch pull_requests: +26883 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28487 ___ Python tracker ___

[issue45254] HAS_SHMEM detection logic is duplicated in implementation and tests

2021-09-21 Thread Nikita Sobolev
Change by Nikita Sobolev : -- components: +Tests versions: +Python 3.10, Python 3.11, Python 3.8, Python 3.9 ___ Python tracker ___

[issue45254] HAS_SHMEM detection logic is duplicated in implementation and tests

2021-09-21 Thread Nikita Sobolev
New submission from Nikita Sobolev : `HAS_SHMEM` is defined in `multiprocessing.managers` module https://github.com/python/cpython/blob/0bfa1106acfcddc03590e1f5d6789dbad3affe70/Lib/multiprocessing/managers.py#L35-L40 Later the same logic is duplicated in `_test_multiprocessing`: