Skip to content

Commit

Permalink
Fix environ assertion
Browse files Browse the repository at this point in the history
  • Loading branch information
MilesCranmer committed Jan 26, 2024
1 parent 4037c2d commit d325c42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pysr/julia_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import warnings

# Required to avoid segfaults (https://juliapy.github.io/PythonCall.jl/dev/faq/)
if os.environ["PYTHON_JULIACALL_HANDLE_SIGNALS"] not in {"yes", ""}:
if os.environ.get("PYTHON_JULIACALL_HANDLE_SIGNALS", "yes") != "yes":
warnings.warn(
"PYTHON_JULIACALL_HANDLE_SIGNALS environment variable is set to something other than 'yes' or ''. "
+ "You will experience segfaults if running with multithreading."
Expand Down

0 comments on commit d325c42

Please sign in to comment.