Skip to content

Commit

Permalink
add general warning to use of fork,
Browse files Browse the repository at this point in the history
revert installation tips since Alessio has PR fix
  • Loading branch information
zm711 committed Nov 2, 2023
1 parent 22a7b79 commit 3e2f411
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/installation-tips-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ jobs:
run: python ./installation_tips/check_your_install.py --ci # ci flag turns off gui
- name: Windows cleanup
if: ${{ matrix.label == 'windows' }}
run: python ./installation_tips/cleanup_for_windows.py
run: python .installation_tips/cleanup_for_windows.py
6 changes: 4 additions & 2 deletions src/spikeinterface/core/job_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,8 +333,10 @@ def __init__(
mp_context = recording.get_preferred_mp_context()
if mp_context is not None and platform.system() == "Windows":
assert mp_context != "fork", "'fork' mp_context not supported on Windows!"
elif mp_context is not None and platform.system() == "Darwin":
warnings.warn('As of Python 3.8 "fork" is no longer considered safe on MacOS')
elif mp_context == "fork" and platform.system() == "Darwin":
warnings.warn('As of Python 3.8 "fork" is no longer considered safe on macOS')
elif mp_context == "fork":
warnings.warn('Use of "fork" will be deprecated in Python. Consider "spawn" in the future')

self.mp_context = mp_context

Expand Down

0 comments on commit 3e2f411

Please sign in to comment.