Skip to content

Commit

Permalink
Workaround for multiprocessing shared memory limits
Browse files Browse the repository at this point in the history
This affects musl libc and macos, see:
sagemath#36741 (comment)

We are working on a better fix to avoid using multiprocessing in
sage.features, but this will do meanwhile.

There is agreement that disabling the lock is completely harmless, since
the counter is not really used for anything; disabling the lock fixes
the issues that we had on 10.4.beta0.
  • Loading branch information
tornaria committed Mar 31, 2024
1 parent b693ea9 commit 7a65d53
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sage/features/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def __init__(self, name, spkg=None, url=None, description=None, type='optional')
# shared among subprocesses. Thus we use the Value class from the
# multiprocessing module (cf. self._seen of class AvailableSoftware)
from multiprocessing import Value
self._num_hidings = Value('i', 0)
self._num_hidings = Value('i', 0, lock=False)

try:
from sage.misc.package import spkg_type
Expand Down

0 comments on commit 7a65d53

Please sign in to comment.