4 ms·
Here's a use case I pose every time Nix comes up in these discussions. For $REASONS I want python 3.7.10, and the full scientific stack (numpy, scipy, pandas,
by kristjansson 5y ago
Here's a use case I pose every time Nix comes up in these discussions.
For $REASONS I want python 3.7.10, and the full scientific stack (numpy, scipy, pandas, numba, matplotlib, ...) at the latest compatible versions along with pytorch. I don't mind waiting for things to compile. How, if at all, can Nix help me get into an environment that meets those constraints? Can it help without requiring me to find and copy hashes of things?
- zeec123 5y agohttps://github.com/nix-community/poetry2nix https://github.com/nix-community/poetry2nix
- ris 5y ago> requiring me to find and copy hashes of things Put an incorrect hash in. Run the build. The error will tell you what hash it actually got. Copy that. Run build again.
- amelius 5y agoThis is how I use Conda, which uses libsolv under the hood to figure out compatible versions. This makes me wonder: does Nix use libsolv, or a similar idea?
- rgoulter 5y agoNix wouldn't. Roughly, Nix's approach is to describe packages as a function of it dependencies as inputs. (And all the inputs have all their dependencies described in Nix, too). Nix doesn't do things like "install latest version of X". (One of Nix's principles is build reproducibility; the package should have the same behaviour if built with the same input). Tools like mach-nix or poetry2nix wrap around nix.. as I understand, they adapt the requirements.txt or whatever and pass it into Nix in a way that Nix can understand.
- akdor1154 5y agoI have a similar question and want to ask the nix crowd about an approach - how well does it work to have nix just manage the nativeish stuff like Python and maybe the compiler chain, but still use the language's package manager (pip/poetry) for language deps ? Both for parent's quandary, and for when you're working with a group and don't want to force everyone else to use Nix.
- wefpijfewijefwi 5y ago