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: attribute 'overrideScope'' missing #411

Open
andy-bell101 opened this issue Nov 30, 2024 · 1 comment
Open

error: attribute 'overrideScope'' missing #411

andy-bell101 opened this issue Nov 30, 2024 · 1 comment

Comments

@andy-bell101
Copy link

andy-bell101 commented Nov 30, 2024

When rebuilding my system on the latest nixpkgs-unstable, I get the following error:

       … while calling the 'head' builtin
         at /nix/store/4wjygyks9w9z3548738hpfjnaqvwxmcw-source/lib/attrsets.nix:1574:11:
         1573|         || pred here (elemAt values 1) (head values) then
         1574|           head values
             |           ^
         1575|         else

       … while evaluating the attribute 'value'
         at /nix/store/4wjygyks9w9z3548738hpfjnaqvwxmcw-source/lib/modules.nix:816:9:
          815|     in warnDeprecation opt //
          816|       { value = addErrorContext "while evaluating the option `${showOption loc}':" value;
             |         ^
          817|         inherit (res.defsFinal') highestPrio;

       … while evaluating the option `system.build.toplevel':

       … while evaluating definitions from `/nix/store/4wjygyks9w9z3548738hpfjnaqvwxmcw-source/nixos/modules/system/activation/top-level.nix':

       … while evaluating the option `system.systemBuilderArgs':

       … while evaluating definitions from `/nix/store/4wjygyks9w9z3548738hpfjnaqvwxmcw-source/nixos/modules/system/activation/top-level.nix':

       … while evaluating the option `system.build.installBootLoader':

       … while evaluating definitions from `/nix/store/4wjygyks9w9z3548738hpfjnaqvwxmcw-source/nixos/modules/system/boot/loader/external/external.nix':

       … while evaluating the option `boot.loader.external.installHook':

       (stack trace truncated; use '--show-trace' to show the full, detailed trace)

       error: attribute 'overrideScope'' missing
       at /nix/store/xb195011i3my7fda4bqzygml3j3x6r9k-source/lib/default.nix:53:34:
           52|
           53|   overrideToolchain = toolchain: self.overrideScope' (_final: _prev: {
             |                                  ^
           54|     cargo = toolchain;
       Did you mean overrideScope?

I think the root cause is just that the flake.lock needs updating to pick up the latest changes in crane. It looks like there is a PR to update the lockfile in progress #408, but the build is broken.

@andy-bell101 andy-bell101 changed the title Broken on nixpkgs-unstable error: attribute 'overrideScope'' missing Nov 30, 2024
@Coca162
Copy link

Coca162 commented Dec 2, 2024

For anybody who wants a temporary fix you can override crane to the specific commit where they started using overrideScope by doing nix flake update --override-input lanzaboote/crane github:ipetkov/crane/f2926e34a1599837f3256c701739529d772e36e7 since it doesn't seem like it breaks with lanzaboote

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

No branches or pull requests

2 participants