error:
… while calling the 'derivationStrict' builtin
at /builtin/derivation.nix:9:12: (source not available)
… while evaluating derivation 'nix-shell'
whose name attribute is located at /nix/store/2p9qcybzmx1rfayjw866rz8xljbw45g9-source/pkgs/stdenv/generic/make-derivation.nix:353:7
… while evaluating attribute 'nativeBuildInputs' of derivation 'nix-shell'
at /nix/store/2p9qcybzmx1rfayjw866rz8xljbw45g9-source/pkgs/stdenv/generic/make-derivation.nix:397:7:
396| depsBuildBuild = elemAt (elemAt dependencies 0) 0;
397| nativeBuildInputs = elemAt (elemAt dependencies 0) 1;
| ^
398| depsBuildTarget = elemAt (elemAt dependencies 0) 2;
(stack trace truncated; use '--show-trace' to show the full trace)
error: attribute 'dev' missing
at /nix/store/187phwwr5c87bnnvyac8lf69gz3yibn2-source/default.nix:86:45:
85| if pyProject.tool.poetry.group or { } != { }
86| then lib.flatten (map (g: getDeps pyProject.tool.poetry.group.${g}.dependencies) groups)
| ^
87| else [ ]
I tried to use previous commits of poetry2nix in case this was a bug but I got the exact same error. I’m out of idea, any help would be appreciated
Can you share your pyproject.toml and the version of Poetry you have been using? I suspect you have been using a version prior to 1.2.0, which is when dependency groups were added and the dev-dependencies section was deprecated.
What happens if you rename the lint group to dev? Your config should work AFAICT, but I’m curious if poetry2nix expects that specific dependency group name.
It seems to work, I’m not sure why it’s compiling numpy form source however but why not
After running for a while it stopped with the following error:
error: builder for '/nix/store/ivh0gwwk637p08mybq3c4azzmaka220k-python3.11-ismember-1.0.2.drv' failed with exit code 2;
last 10 log lines:
> File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
> File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
> File "<frozen importlib._bootstrap>", line 1126, in _find_and_load_unlocked
> File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
> File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
> File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
> File "<frozen importlib._bootstrap>", line 1140, in _find_and_load_unlocked
> ModuleNotFoundError: No module named 'setuptools'
I tried to use the documentation to fix the problem but it does not seems to work:
error:
… while calling the 'derivationStrict' builtin
at /builtin/derivation.nix:9:12: (source not available)
… while evaluating derivation 'nix-shell'
whose name attribute is located at /nix/store/gzf4zwcakda1nykn6h0avh45xhjhvsz4-source/pkgs/stdenv/generic/make-derivation.nix:353:7
… while evaluating attribute 'nativeBuildInputs' of derivation 'nix-shell'
at /nix/store/gzf4zwcakda1nykn6h0avh45xhjhvsz4-source/pkgs/stdenv/generic/make-derivation.nix:397:7:
396| depsBuildBuild = elemAt (elemAt dependencies 0) 0;
397| nativeBuildInputs = elemAt (elemAt dependencies 0) 1;
| ^
398| depsBuildTarget = elemAt (elemAt dependencies 0) 2;
(stack trace truncated; use '--show-trace' to show the full trace)
error: attribute 'defaultPoetryOverrides' missing
at /nix/store/v7zclrv4srqq3q9fnx0vj56lyp8bfynm-source/flake.nix:20:23:
19| projectDir = ./.;
20| overrides = poetry2nix.lib.defaultPoetryOverrides.extend
| ^
21| (self: super: {
FYI, I use a slightly different way to inject those overrides that works well for me, something like (sorry, I cannot include a real, stripped down example right now):