nix-community / home-manager

Manage a user environment using Nix [maintainer=@rycee]
https://nix-community.github.io/home-manager/
MIT License
7.17k stars 1.85k forks source link

bug: Builder for home-configuration-reference-manpage.drv fails #5034

Open V4G4X opened 9 months ago

V4G4X commented 9 months ago

Are you following the right branch?

Is there an existing issue for this?

Issue description

I am trying darwin-rebuild check.

There's been no change to my config but I get this:

darwin-rebuild check
building the system configuration...
these 18 derivations will be built:
  /nix/store/x71ahc9cca66gi5g7vsy9xrflfmnlqln-home-configuration-reference-manpage.drv
  /nix/store/09mma3i0xwrx7y3kj869p8f999q203mb-home-manager-path.drv
  /nix/store/64rdnw351acl6fyqjviaqrk961mw9j7v-darwin-manual-html.drv
  /nix/store/75fpahdjnyhyj0xy0sk7xvlqfkzf4kb5-home-manager-applications.drv
  /nix/store/bi94n5bhh92y9hrmr981s99vy70iiisg-home-manager-files.drv
  /nix/store/jdaf2fvfhczdfq344f7raqnsvk9dpy25-home-manager-fonts.drv
  /nix/store/d8kkllim5srdwxyjjny5yp11hgz08avm-activation-script.drv
  /nix/store/byzrbxa4x7z0i4nqfbdfcnyhnp4fi27f-home-manager-generation.drv
  /nix/store/68r7rqgxrf0k1lysdf45j5nbj1460nnl-activation-varungawande.drv
  /nix/store/d3nzqzcidhsmrpklwh1yqvcm2fzdc524-darwin-help.drv
  /nix/store/hxvgacjrxl267vd8pmz134dcj2r8ag8m-darwin-manpages.drv
  /nix/store/8shfr1yvrs7gw4nivn9wqhgaz73qx74k-system-path.drv
  /nix/store/q9f5xcgnm6lxl1s3nfz4i0bgfc2dinjx-system-applications.drv
  /nix/store/mzwjfrgxixn59lpwxh8j2fkg5x2mkhgy-darwin-system-23.11pre533288.b604023e0a55+darwin4.drv
  /nix/store/68rwmlmmlivx5y3si5hdl53j14pln8cn-darwin-uninstaller.drv
  /nix/store/cpzj24xi9k710h5qps557im9m1jbhmhg-system-applications.drv
  /nix/store/fd4qd93ygjhmfj0cjgqnrqv0l8dnyahj-system-path.drv
  /nix/store/d21p95x9cslwkjnyb4707wpb467c11b7-darwin-system-23.11pre533288.b604023e0a55+darwin4.drv
building '/nix/store/hxvgacjrxl267vd8pmz134dcj2r8ag8m-darwin-manpages.drv'...
building '/nix/store/64rdnw351acl6fyqjviaqrk961mw9j7v-darwin-manual-html.drv'...
building '/nix/store/x71ahc9cca66gi5g7vsy9xrflfmnlqln-home-configuration-reference-manpage.drv'...
usage: nixos-render-docs
       [-h]
       [-j JOBS]
       {options,manual}
       ...
nixos-render-docs: error: unrecognized arguments: --header --footer /nix/store/xq96rpmlh4b1isx0sslkbbcfndl6jib3-options.json/share/doc/nixos/options.json /nix/store/d1aalqlzlawrplvng9g4d0jzfszx5zhd-home-configuration-reference-manpage/share/man/man5/home-configuration.nix.5
error: builder for '/nix/store/x71ahc9cca66gi5g7vsy9xrflfmnlqln-home-configuration-reference-manpage.drv' failed with exit code 2;
       last 6 log lines:
       > usage: nixos-render-docs
       >        [-h]
       >        [-j JOBS]
       >        {options,manual}
       >        ...
       > nixos-render-docs: error: unrecognized arguments: --header --footer /nix/store/xq96rpmlh4b1isx0sslkbbcfndl6jib3-options.json/share/doc/nixos/options.json /nix/store/d1aalqlzlawrplvng9g4d0jzfszx5zhd-home-configuration-reference-manpage/share/man/man5/home-configuration.nix.5
       For full logs, run 'nix log /nix/store/x71ahc9cca66gi5g7vsy9xrflfmnlqln-home-configuration-reference-manpage.drv'.
error: 1 dependencies of derivation '/nix/store/75fpahdjnyhyj0xy0sk7xvlqfkzf4kb5-home-manager-applications.drv' failed to build
error: 1 dependencies of derivation '/nix/store/jdaf2fvfhczdfq344f7raqnsvk9dpy25-home-manager-fonts.drv' failed to build
error: 1 dependencies of derivation '/nix/store/09mma3i0xwrx7y3kj869p8f999q203mb-home-manager-path.drv' failed to build
error: 1 dependencies of derivation '/nix/store/byzrbxa4x7z0i4nqfbdfcnyhnp4fi27f-home-manager-generation.drv' failed to build
error: 1 dependencies of derivation '/nix/store/68r7rqgxrf0k1lysdf45j5nbj1460nnl-activation-varungawande.drv' failed to build
error: 1 dependencies of derivation '/nix/store/d21p95x9cslwkjnyb4707wpb467c11b7-darwin-system-23.11pre533288.b604023e0a55+darwin4.drv' failed to build

How do I fix this?

Maintainer CC

No response

System information

- system: `"aarch64-darwin"`
 - host os: `Darwin 23.2.0, macOS 14.2.1`
 - multi-user?: `yes`
 - sandbox: `no`
 - version: `nix-env (Nix) 2.17.0`
 - channels(root): `"nixpkgs"`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixpkgs`
V4G4X commented 9 months ago

I referred to this, but their solution of doing a simple nix-channel --update didn't work for me.

rycee commented 9 months ago

You are almost certainly having an old Nixpkgs somewhere. Try running nix-channel --update both as root and as your regular user.

V4G4X commented 9 months ago

I am sure I had tried this before, but yes. This changed things.

I have now started getting a version mismatch in the logs.
How do I fix this?

❯ darwin-rebuild check
building the system configuration...
trace: warning: varungawande profile: You are using

  Home Manager version 23.11 and
  Nixpkgs version 24.05.

Using mismatched versions is likely to cause errors and unexpected
behavior. It is therefore highly recommended to use a release of Home
Manager that corresponds with your chosen release of Nixpkgs.

If you insist then you can disable this warning by adding

  home.enableNixpkgsReleaseCheck = false;

to your configuration.

ok
V4G4X commented 9 months ago

nvm.
So running nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager did it for me.

I was able to change the version of home-manager by listing nix-channels, and adding master (latest).
I had a couple of questions.

  1. Is this the recommended way to fix this issue?
  2. What command should I run to get my latest Nixpkgs version? (Here it's 24.05)
stale[bot] commented 6 months ago

Thank you for your contribution! I marked this issue as stale due to inactivity. Please be considerate of people watching this issue and receiving notifications before commenting 'I have this issue too'. We welcome additional information that will help resolve this issue. Please read the relevant sections below before commenting.

If you are the original author of the issue

* If this is resolved, please consider closing it so that the maintainers know not to focus on this. * If this might still be an issue, but you are not interested in promoting its resolution, please consider closing it while encouraging others to take over and reopen an issue if they care enough. * If you know how to solve the issue, please consider submitting a Pull Request that addresses this issue.

If you are not the original author of the issue

* If you are also experiencing this issue, please add details of your situation to help with the debugging process. * If you know how to solve the issue, please consider submitting a Pull Request that addresses this issue.

Memorandum on closing issues

Don't be afraid to manually close an issue, even if it holds valuable information. Closed issues stay in the system for people to search, read, cross-reference, or even reopen – nothing is lost! Closing obsolete issues is an important way to help maintainers focus their time and effort.