"The manual appears to depend on the location of Nixpkgs"

I can build my configuration.nix and deploy it in abfd31179174133ab8131139d650297bf4da63b7 13 days ago but for the last week or so i get an absurd error if I do any subsequent builds off of the configuration when I switch to it.

  • nix channel --update
  • morph deploy # works
  • morph deploy # fails
  • nix channel --rollback to known-working nixpkgs+nixos
  • morph deploy # still fails!
  • switch-to-configuration to the previous build
  • morph build # works
error: 1 dependencies of derivation '/nix/store/05fn8wprjnf3kwszjsnx8nfj7wgc4pzr-generated-docbook.drv' failed to build
error: 1 dependencies of derivation '/nix/store/96j4h13sap7j1jf5h16p12plwhixbabv-nixos-manual-combined.drv' failed to build
error: 1 dependencies of derivation '/nix/store/h38lqvqq71fh7qipg466lv0k7c7nw8im-nixos-manpages.drv' failed to build
error: 1 dependencies of derivation '/nix/store/w54xvpy47w68v84624l805w9zdnm7dfv-nixos-manual-html.drv' failed to build
error: 1 dependencies of derivation '/nix/store/nr42kfzl867180gyy9la55q1nc8w23nd-system-path.drv' failed to build
error: 1 dependencies of derivation '/nix/store/qmn52h53cr6j2x8zv9nkl2f35pwkh36q-nixos-system-virtuous-cassette-22.05pre378108.556ce9a40ab.drv' failed to build

The system is failing to generate the manual for every option in nixpkgs afaict containing a relative path pointing to the version of nixpkgs:

          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/rename.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/services/x11/desktop-managers/cinnamon.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/system/etc/etc.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/system/etc/etc.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/system/etc/etc.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/system/etc/etc.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/system/etc/etc.nix" />
[...redacting much of this]
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/virtualisation/qemu-vm.nix" />
          <string value="3y2ymjdad71ilw7rpl71xwsj0pv9js36-nixpkgs/nixpkgs/nixos/modules/virtualisation/qemu-vm.nix" />
The manual appears to depend on the location of Nixpkgs, which is bad
since this prevents sharing via the NixOS channel.  This is typically
caused by an option default that refers to a relative path (see above
for hints about the offending path).

3y2ymjdad71ilw7rpl71xwsj0pv9js36 is the version of nixpkgs which the system was built for after running the nix-channel --update, and the version which the system is switched to.

I really am not sure what to make of this or any indication what could be wrong between my nixos, nixpkgs, and upstream… I don’t change any documentation.* options and I do use man configuration.nix often enough that I can’t simply disable this and get on with my life :confused: i’m not above bisecting the 2000 commits between here and there, but obviously i’d rather not since it’s a pretty invasive and time consuming thing to have to do on my live system.

anyone have an idea/lead/advice?

4 Likes
[nix-shell:~/Code/nixpkgs]$ cat /etc/os-release  | grep BUILD_ID
BUILD_ID="22.05.git.41cc1d5d958"

well, i still don’t have a solution or root cause to this incredibly frustrating situation, but “somehow” a morph deploy with NIX_PATH=nixos=/home/rrix/Code/nixpkgs/nixos:nixpkgs=/home/rrix/Code/nixpkgs from the misbehaving machine to a nixos mule i set up worked, and then from there I could morph deploy back to the misbehaving machine an “up to date” nixpkgs and derivation set.

I still cannot update without setting NIX_PATH, though…

I guess i just won’t use channels for now and update my nixpkgs checkout this way, keep my mule machine up to date, and pray that it continues to work. Though I’m now missing the binary cache for some big GUI applications like kstars and telegram-desktop which is kind of harshing my vibe.

If you use the commit for nixos-unstable listed here https://status.nixos.org/ then you shouldn’t have cache misses

Having a reproducer flake or something would make it much more likely that someone will look in to it

Maybe this has something to do with morph so I suggest checking their issues and filing one if there’s not one already

If you use the commit for nixos-unstable listed here https://status.nixos.org/ then you shouldn’t have cache misses

yep, i shouldn’t; i have a script which is polling channels.nix.gsc.io to checkout the latest channel status when I update my clone, and much of the things weren’t missing the cache but a handful of apps were even though I don’t customize them. shrug

anyways home-manager recreates ~/.nix-defexpr and then the nix-daemon nixos module sticks that path at the front of NIX_PATH unconditionally every time i invoke my deploy so this hack isn’t very long-term sustainable, but it’s Good Enough until I get fed up enough to wipe and reinitialize this system.

I can’t really get a flake of this system, or even replicate the issue on another machine running the same derivation (barring hardware-configuration etc) so I’m as lost as any one else would be … believe me i searched morph, nixpkgs, etc, issues trying to figure out what to debug or if anyone had seen this before – there is 1 google search result (the second result is this thread, the third result is the code which emits the error) for that error message which was closed in 2014 with “better handling” of symlink nixpkgs…

If it happened with my overridden NIX_PATH nixpkgs i could at least stick traces in to the docbook module to chase it down but since that copy of nixpkgs works I cannot without making my nix store rw and mucking about in it.

Hosted by Flying Circus.