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

Error message "string '...' has a context which refers to a complete source and binary closure" makes no sense. #10651

Open
YorikSar opened this issue May 6, 2024 · 1 comment
Assignees
Labels

Comments

@YorikSar
Copy link
Contributor

YorikSar commented May 6, 2024

Describe the bug

I wanted to check something and ran nix build nixpkgs#hello.drvPath. I got this error:

error:
       … while evaluating the flake output attribute 'legacyPackages.aarch64-darwin.hello.drvPath'

       error: string '/nix/store/wzgg4k9ll80qrcsmkgvrzdhmlbb4s00x-hello-2.12.1.drv' has a context which refers to a complete source and binary closure. This is not supported at this time

I know a bit about Nix, but I can't understand what "a complete source and binary closure" means. I bet people who are less experienced with Nix wouldn't understand what does string having a context mean as well. Neither of these notions are mentioned in the documentation and errors should not require documentation to be understood. This error message should be changed.

Steps To Reproduce

Run nix build nixpkgs#hello.drvPath.

Expected behavior

A clear and concise error explaining unmet conditions should be displayed.

nix-env --version output

nix-env (Nix) 2.21.1

Priorities

Add 👍 to issues you find important.

@YorikSar YorikSar added the bug label May 6, 2024
@Ericson2314 Ericson2314 self-assigned this May 6, 2024
@Ericson2314
Copy link
Member

Ericson2314 commented May 6, 2024

In a previous restriction we decided to just make the CLI accept these really weird string context items (that we wish didn't exist), but I have yet to do it. That would make that message go away (in this context, at least).

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

2 participants