Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError('context has already been set') #201

Closed
arabnejad opened this issue May 12, 2021 · 1 comment
Closed

RuntimeError('context has already been set') #201

arabnejad opened this issue May 12, 2021 · 1 comment
Assignees
Labels

Comments

@arabnejad
Copy link
Collaborator

Found a bug? Please fill out the sections below. 馃憤

Describe the bug

when we call ensemble runs, on linux, we may get a RuntimeError on the set_start_method("fork") line in MultiProcessingPool.py file

Relevant logs and/or media (optional)

    set_start_method("fork")
  File "/usr/lib/python3.8/multiprocessing/context.py", line 243, in set_start_method
    raise RuntimeError('context has already been set')

Platform details (optional)

  • OS: Linux
  • FabSim3 2.8
  • Python 3.8
@arabnejad arabnejad added the bug label May 12, 2021
@arabnejad arabnejad added this to the VECMA M36 Release milestone May 12, 2021
@arabnejad arabnejad self-assigned this May 12, 2021
@arabnejad
Copy link
Collaborator Author

one possible approach is to checking the current start method with get_start_method,
however, this function (get_start_method) will explicitly set the start method. After calling this - you will be unable to set the change method

so, in this case the safest method is to use try .. except

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant