error: attribute 'lib' missing
riley-martin opened this issue · 2 comments
riley-martin commented
I am using agenix on my nixos system, and today after doing nix flake update
, when I try to rebuild my system, there is this error:
building the system configuration...
warning: Git tree '/home/riley/dotfiles' is dirty
error:
… while calling the 'head' builtin
at /nix/store/lrmxkfadhlcrakza60w0mc8sc327a5qg-source/lib/attrsets.nix:960:11:
959| || pred here (elemAt values 1) (head values) then
960| head values
| ^
961| else
… while evaluating the attribute 'value'
at /nix/store/lrmxkfadhlcrakza60w0mc8sc327a5qg-source/lib/modules.nix:809:9:
808| in warnDeprecation opt //
809| { value = builtins.addErrorContext "while evaluating the option `${showOption loc}':" value;
| ^
810| inherit (res.defsFinal') highestPrio;
(stack trace truncated; use '--show-trace' to show the full trace)
error: attribute 'lib' missing
at /nix/store/vwdamz0pih84shjk6yv6ddriqd2hixax-source/flake.nix:48:12:
47| integration =
48| (darwin.lib.darwinSystem {
| ^
49| inherit system;
When I open the file referenced in the last part of the error, it is agenix's flake.nix. I'm not sure if agenix is causing the problem or if it is my fault, but any help would be appreciated. Agenix is installed using flakes.
cole-h commented
That's because you're overriding the darwin
input to ""
(which refers to the "self" flake, i.e. your dotfiles flake), and your dotfiles flake doesn't expose a lib
.
riley-martin commented
Thanks, that fixed it. Sorry for the trouble about my mistake.