[JOSS]: numpy requirement not satisfied after pip install
Closed this issue · 5 comments
In a clean virtual environment, installing the python interface following INSTALL.md
does not provide a usable library because the numpy requirement is not satisfied
Steps to reproduce
$ git clone git@github.com/fenics/basix.git
$ python3 -m venv basix-test
$ . basix-test/bin/activate
$ cd basix
$ pip install .
[wait...]
$ cat << EOF | python
import basix
celltype = basix.CellType.triangle
pts = basix.create_lattice(celltype, 1, basix.LatticeType.equispaced, True)
EOF
Traceback (most recent call last):
File "<stdin>", line 3, in <module>
ModuleNotFoundError: No module named 'numpy'
I guess that numpy should be specified as a requirement in pyproject.toml
?
I'll take a look at this and #370. pyproject.toml isn't supported by scikit-build which is what we are using to do the pip install .
combined C++/Python build. As I'm sure you're aware Python packaging is in a transition mess especially for combined Python/C++ projects.
In the meantime, here are the test requirements which are used in our binary wheel builds:
test-requires = ["pytest", "pytest-xdist", "numpy", "sympy", "numba", "scipy"]
From: https://github.com/FEniCS/basix/blob/main/pyproject.toml#L10
scikit-build doesn't even support setup.cfg
which was a transition step between old-fashioned setup.py
and modern pyproject.toml
I'll take a look at this and #370. pyproject.toml isn't supported by scikit-build which is what we are using to do the
pip install .
combined C++/Python build. As I'm sure you're aware Python packaging is in a transition mess especially for combined Python/C++ projects.In the meantime, here are the test requirements which are used in our binary wheel builds:
test-requires = ["pytest", "pytest-xdist", "numpy", "sympy", "numba", "scipy"]
From: https://github.com/FEniCS/basix/blob/main/pyproject.toml#L10
Thanks!
Let me know here if that fixes the issues.
Thanks, that worked for me.