I am writing a small package for a personel project. It is dependant on a python package that is wrapping another code written in Fortran.
I know how to install it via pip in PyCall.jl and it works great. But I would like to have a setup to install it automatically if someone download my package. I am not that experienced in Julia but I’ve read a bit about the __ init __ function that I could maybe put in my main module containing the code to install the python package.
Let’s say I want to install numpy as an example:
using PyCall
run(`$(PyCall.python) -m pip install --upgrade numpy`)
Would I just need to write this lines in the init function? What would be the best way to do it then?
Thank you both for nice options. The thing that prevented me a bit from using PythonCall (while knowing nothing about the differences btw the 2 packages) was that it is not yet in 1.x.x version but appart from that, the packages seem quite equivalent. And reading a bit the docs, PythonCall seems indeed better for what I want. Is there a particular reason why it is not considered as production ready or something I should be aware of?