Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot build set of derivations when the keys starts by a digit #5155

Open
RaitoBezarius opened this issue Aug 20, 2021 · 7 comments
Open

Cannot build set of derivations when the keys starts by a digit #5155

RaitoBezarius opened this issue Aug 20, 2021 · 7 comments
Labels

Comments

@RaitoBezarius
Copy link
Member

Describe the bug

Instantiating the set of derivations when the keys contain an underscore is aborted and no paths are provided.

Steps To Reproduce

  1. nix-instantiate -E 'with import <nixpkgs> {}; { "3" = fish; "2" = bash; }' does nothing
  2. nix-instantiate -E 'with import <nixpkgs> {}; { a = fish; b = bash; }' returns the paths

Expected behavior

Expect result should be the one of the second step.

nix-env --version output

nix-env (Nix) 2.4pre20210802_47e96bb

@stale
Copy link

stale bot commented Apr 16, 2022

I marked this as stale due to inactivity. → More info

@stale stale bot added the stale label Apr 16, 2022
@RaitoBezarius
Copy link
Member Author

Still a bug for me.

@stale stale bot removed the stale label Apr 16, 2022
@stale stale bot added the stale label Oct 30, 2022
@lf-
Copy link
Member

lf- commented Mar 3, 2024

reproduces:

nix-instantiate --version
nix-instantiate (Nix) 2.18.1

@stale stale bot removed the stale label Mar 3, 2024
@Lunaphied
Copy link
Contributor

reproduces:

nix-instantiate --version
nix-instantiate (Nix) 2.19.2

@Lunaphied
Copy link
Contributor

For additional context:

nix eval --expr 'with import <nixpkgs> {}; { "3" = fish; "2" = bash; }' --impure results in seemingly evaluating all of Nixpkgs and naturally hits a segfault before completing, (this also happens with the a, b version).

In nix repl both versions work correctly.

@thufschmitt
Copy link
Member

nix eval --expr 'with import <nixpkgs> {}; { "3" = fish; "2" = bash; }' --impure results in seemingly evaluating all of Nixpkgs and naturally hits a segfault before completing, (this also happens with the a, b version).

Yes, that one is normal(ish). nix eval will try to deeply evaluate the derivations (and not just print their output/drv path like nix-instantiate or nix repl do, and that doesn't work because Nixpkgs is too scary for Nix. You can pass --json to work around it

@thufschmitt
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants