Spaces:
Sleeping
Sleeping
Better help message for PyCall errors
Browse files- pysr/julia_helpers.py +11 -1
pysr/julia_helpers.py
CHANGED
|
@@ -81,7 +81,17 @@ def install(julia_project=None, quiet=False, precompile=None): # pragma: no cov
|
|
| 81 |
if precompile == False:
|
| 82 |
os.environ["JULIA_PKG_PRECOMPILE_AUTO"] = "0"
|
| 83 |
|
| 84 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 85 |
Main, init_log = init_julia(julia_project, quiet=quiet, return_aux=True)
|
| 86 |
io_arg = _get_io_arg(quiet)
|
| 87 |
|
|
|
|
| 81 |
if precompile == False:
|
| 82 |
os.environ["JULIA_PKG_PRECOMPILE_AUTO"] = "0"
|
| 83 |
|
| 84 |
+
try:
|
| 85 |
+
julia.install(quiet=quiet)
|
| 86 |
+
except julia.tools.PyCallInstallError:
|
| 87 |
+
raise RuntimeError(
|
| 88 |
+
"Installing PyCall.jl failed. "
|
| 89 |
+
"Please delete the folder `~/.julia/packages/PyCall` folder, "
|
| 90 |
+
"and re-try installation. For further assistance, "
|
| 91 |
+
"please see the issue "
|
| 92 |
+
"https://github.com/MilesCranmer/PySR/issues/257."
|
| 93 |
+
)
|
| 94 |
+
|
| 95 |
Main, init_log = init_julia(julia_project, quiet=quiet, return_aux=True)
|
| 96 |
io_arg = _get_io_arg(quiet)
|
| 97 |
|