I have an in-house package which, for legacy reasons, uses PyCall.jl instead of PythonCall.jl. My package includes a deps/build.jl
which installs Python dependencies with e.g. Conda.add("somepackage")
. However, PyCall.jl defaulted to the system Python and failed to import the packages installed by Conda.jl on a Linux server. Upon closer reading of the README of PyCall.jl, it seems that this is expected, as Conda.jl is the default backend for only Mac and Windows:
By default on Mac and Windows systems,
Pkg.add("PyCall")
orPkg.build("PyCall")
will use the Conda.jl package to install a minimal Python distribution (via Miniconda) that is private to Julia (not in yourPATH
).
I could tell the users of my package to manually rerun Pkg.build("PyCall")
after specifying Conda.jl as the backend, but this is not very user-friendly, as I prefer the setup to be automatically handled by Pkg when installing my package. Any suggestions?