bmcage/odes

Install from nix doesn't work

goatchurchprime opened this issue · 3 comments

Instructions given here: https://scikits-odes.readthedocs.io/en/stable/installation.html#using-nix but updated to python310

> nix-shell -p python310
> nix-shell -p python310Packages.numpy
> nix-shell -p python310Packages.scikits-odes
> python
>>> import scikits.odes
ModuleNotFoundError

It's possible there's a compiler error:

INFO: CCompilerOpt.cache_flush[857] : write cache to path -> /build/scikits.odes-2.6.4/build/temp.linux-x86_64-cpython-310/ccompiler_opt_cache_ext.py
error: builder for '/nix/store/s0mwadpzrjhskd1pnj6z9l4mmdrwmdpy-python3.10-scikits.odes-2.6.4.drv' failed with exit code 1;

I don't know much about the build process, but it does a partial recompile every time I try to install it, which seems to mean the package is not happy. It would be nice if it gave more of an indication that I would be wasting my time going into python and looking for a package that it knows I want but isn't there. So it could be useful to add a pythonImportsCheck parameter into its buildPythonPackage call
https://github.com/NixOS/nixpkgs/blob/nixos-22.05/pkgs/development/python-modules/scikits-odes/default.nix#L38

Happy to accept a PR which fixes it (the nix instructions were added in #102, and the nix packaging isn't managed by us).

After getting a lot of help, this seems to work
flake.zip

It's not clear to me that there's anything we can do here, #146 makes the nix support more explicit that it is a third-party who has set this up.