Skip to content

Conversation

@roberth
Copy link
Member

@roberth roberth commented Dec 2, 2025

Motivation

Unblock Nixpkgs.
Get the nice new page level table of contents to appear in the menu!

Context


Add 👍 to pull requests you find important.

The Nix maintainer team uses a GitHub project board to schedule and track reviews.

Fixes NixOS#14628

- Remove mdbook-linkcheck dependency and configuration (was blocking
  upgrades to mdbook 0.5.0+, configured with warning-policy = "ignore"
  due to false positives, and redundant with lychee-based link checking)
- Update substitute.py and anchors.jq to handle 'items' (mdbook 0.5.x)
  in addition to 'sections' (mdbook 0.4.x), as per mdbook 0.5.0
  changelog: "Book::sections was renamed to Book::items"
  https://github.com/rust-lang/mdBook/blob/master/CHANGELOG.md#05-migration-guide
Use `or ""` fallback for postInstall attribute which may not exist in
newer nixpkgs versions of lowdown.
@roberth roberth requested a review from edolstra as a code owner December 2, 2025 01:51
@roberth roberth mentioned this pull request Dec 2, 2025
21 tasks
@roberth roberth added backport 2.31-maintenance Automatically creates a PR against the branch backport 2.32-maintenance Automatically creates a PR against the branch labels Dec 2, 2025
Copy link
Member

@Ericson2314 Ericson2314 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean we need your link checking PR even more now?

@roberth
Copy link
Member Author

roberth commented Dec 2, 2025

I'm sure mdbook-linkcheck will be updated at some point, but lychee is more capable anyway, in terms of checking the fragments too. Glad we have this better alternative now.
(There's potential for mdbook-linkcheck to have better UX by operating on the markdown, but that's even more hypothetical now)

@roberth
Copy link
Member Author

roberth commented Dec 2, 2025

I've added backport labels so that Nixpkgs can update mdbook. Only two labels for now; we'll see how that goes.

@Ericson2314 Ericson2314 added this pull request to the merge queue Dec 2, 2025
Merged via the queue into NixOS:master with commit ec6789f Dec 2, 2025
19 checks passed
@internal-nix-ci
Copy link

Successfully created backport PR for 2.31-maintenance:

@internal-nix-ci
Copy link

Successfully created backport PR for 2.32-maintenance:

@roberth roberth added backport 2.28-maintenance Automatically creates a PR against the branch backport 2.29-maintenance Automatically creates a PR against the branch backport 2.30-maintenance Automatically creates a PR against the branch labels Dec 2, 2025
@internal-nix-ci
Copy link

Backport failed for 2.28-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.28-maintenance
git worktree add -d .worktree/backport-14690-to-2.28-maintenance origin/2.28-maintenance
cd .worktree/backport-14690-to-2.28-maintenance
git switch --create backport-14690-to-2.28-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.29-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.29-maintenance
git worktree add -d .worktree/backport-14690-to-2.29-maintenance origin/2.29-maintenance
cd .worktree/backport-14690-to-2.29-maintenance
git switch --create backport-14690-to-2.29-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.30-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.30-maintenance
git worktree add -d .worktree/backport-14690-to-2.30-maintenance origin/2.30-maintenance
cd .worktree/backport-14690-to-2.30-maintenance
git switch --create backport-14690-to-2.30-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.28-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.28-maintenance
git worktree add -d .worktree/backport-14690-to-2.28-maintenance origin/2.28-maintenance
cd .worktree/backport-14690-to-2.28-maintenance
git switch --create backport-14690-to-2.28-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.31-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.31-maintenance
git worktree add -d .worktree/backport-14690-to-2.31-maintenance origin/2.31-maintenance
cd .worktree/backport-14690-to-2.31-maintenance
git switch --create backport-14690-to-2.31-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.32-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.32-maintenance
git worktree add -d .worktree/backport-14690-to-2.32-maintenance origin/2.32-maintenance
cd .worktree/backport-14690-to-2.32-maintenance
git switch --create backport-14690-to-2.32-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.29-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.29-maintenance
git worktree add -d .worktree/backport-14690-to-2.29-maintenance origin/2.29-maintenance
cd .worktree/backport-14690-to-2.29-maintenance
git switch --create backport-14690-to-2.29-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.30-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.30-maintenance
git worktree add -d .worktree/backport-14690-to-2.30-maintenance origin/2.30-maintenance
cd .worktree/backport-14690-to-2.30-maintenance
git switch --create backport-14690-to-2.30-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.28-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.28-maintenance
git worktree add -d .worktree/backport-14690-to-2.28-maintenance origin/2.28-maintenance
cd .worktree/backport-14690-to-2.28-maintenance
git switch --create backport-14690-to-2.28-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.31-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.31-maintenance
git worktree add -d .worktree/backport-14690-to-2.31-maintenance origin/2.31-maintenance
cd .worktree/backport-14690-to-2.31-maintenance
git switch --create backport-14690-to-2.31-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.29-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.29-maintenance
git worktree add -d .worktree/backport-14690-to-2.29-maintenance origin/2.29-maintenance
cd .worktree/backport-14690-to-2.29-maintenance
git switch --create backport-14690-to-2.29-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.32-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.32-maintenance
git worktree add -d .worktree/backport-14690-to-2.32-maintenance origin/2.32-maintenance
cd .worktree/backport-14690-to-2.32-maintenance
git switch --create backport-14690-to-2.32-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.30-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.30-maintenance
git worktree add -d .worktree/backport-14690-to-2.30-maintenance origin/2.30-maintenance
cd .worktree/backport-14690-to-2.30-maintenance
git switch --create backport-14690-to-2.30-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.31-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.31-maintenance
git worktree add -d .worktree/backport-14690-to-2.31-maintenance origin/2.31-maintenance
cd .worktree/backport-14690-to-2.31-maintenance
git switch --create backport-14690-to-2.31-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@internal-nix-ci
Copy link

Backport failed for 2.32-maintenance, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 2.32-maintenance
git worktree add -d .worktree/backport-14690-to-2.32-maintenance origin/2.32-maintenance
cd .worktree/backport-14690-to-2.32-maintenance
git switch --create backport-14690-to-2.32-maintenance
git cherry-pick -x 2636f50dd41fe357ec64430aeeb772328ab2d7cb 0aef1ddb9ee5b706be03e4956af9300fdbed4a97

@xokdvium
Copy link
Contributor

xokdvium commented Dec 2, 2025

Hm, how come the backport action has gone crazy?

@roberth
Copy link
Member Author

roberth commented Dec 2, 2025

I think it happened because I added labels later. I guess it gets an event per label, but then tries to apply all of them for each event?

Anyway, backports 2.31 and 2.32 worked. I'll do 2.30 now.

@nunotexbsd
Copy link

nunotexbsd commented Dec 2, 2025

I did apply patch to nix and rebuilded with mdbook 0.5.1 and it seems that a suffix was added to generated docs:

ex: book.js -> book-a0b12cfe.js

===> Checking for items in STAGEDIR missing from pkg-plist
Error: Orphaned: %%DOCSDIR%%/manual/ayu-highlight-3fdfc3ac.css
Error: Orphaned: %%DOCSDIR%%/manual/book-a0b12cfe.js
Error: Orphaned: %%DOCSDIR%%/manual/clipboard-1626706a.min.js
Error: Orphaned: %%DOCSDIR%%/manual/css/chrome-ae938929.css
<snip>

===> Checking for items in pkg-plist which are not in STAGEDIR
Error: Missing: %%DOCSDIR%%/manual/ayu-highlight.css
Error: Missing: %%DOCSDIR%%/manual/book.js
Error: Missing: %%DOCSDIR%%/manual/clipboard.min.js
Error: Missing: %%DOCSDIR%%/manual/css/chrome.css
<snip>

@roberth
Copy link
Member Author

roberth commented Dec 3, 2025

@nunotexbsd Those are cache busting suffixes, and as long as they're only in "support" resources that are not linked directly, they're perfectly fine.
I don't see them on any html files, so I don't think we have a real problem here.
Thank you for checking ❤️

edolstra added a commit that referenced this pull request Dec 3, 2025
@edolstra edolstra mentioned this pull request Dec 9, 2025
roberth added a commit to roberth/nixpkgs that referenced this pull request Dec 17, 2025
Update to latest Nix master which includes mdbook 0.5 support merged in
PR NixOS#14690.

NixOS/nix#14690
roberth added a commit to roberth/nixpkgs that referenced this pull request Dec 17, 2025
Update to latest Nix master which includes mdbook 0.5 support merged in
PR NixOS#14690.

NixOS/nix#14690
philiptaron added a commit to philiptaron/nixpkgs that referenced this pull request Jan 8, 2026
## Bug fixes (crashes)

- Fix segfaults from `toView()` when compiled with newer nixpkgs (NixOS/nix#14154)
- Fix use-after-move in `DerivationGoal::repairClosure` and `SampleStack` (NixOS/nix#14086)
- Fix assertion failure on partially valid derivation outputs (NixOS/nix#14137)
- Fix `RestrictedStore::addDependency` recursion causing crashes (NixOS/nix#14729)
- Fix crash on flakerefs containing newlines (NixOS/nix#14450)

## Bug fixes (functionality)

- Fix fakeSSH check breaking SSH copies with `user@host` format (NixOS/nix#14150)
- Fix `builtins.dirOf` regression from Nix 2.23 (NixOS/nix#14515)
- Restore missing `isAllowed` check in `ChrootLinuxDerivationBuilder` (NixOS/nix#14531)
- Fix curl with c-ares failing to resolve DNS in sandbox on macOS (NixOS/nix#14792)
- Fix tarball percent decoding for `file://` URIs (NixOS/nix#14729)
- `exportReferencesGraph`: Handle heterogeneous arrays (NixOS/nix#13861)
- Fix filesystem ops in store optimization (NixOS/nix#14676)

## Bug fixes (output)

- Fix double-quoting of paths in logs (NixOS/nix#14210)
- Include path in world-writable error messages (NixOS/nix#14785)

## Improvements

- Better git refnames validation (NixOS/nix#14253)
- Use pure/restricted eval for help pages (NixOS/nix#14156)
- Improve store-reference compatibility with IPv6 ZoneId literals (NixOS/nix#14134)
- Correct `build-dir` error in manual (NixOS/nix#14745)

## Build system

- Add mdbook 0.5 support (NixOS/nix#14690)
- Drop legacy Apple SDK pattern (NixOS/nix#13976)

https://github.com/NixOS/nix/releases/tag/2.31.3
philiptaron added a commit to philiptaron/nixpkgs that referenced this pull request Jan 8, 2026
Changelog of fixes:

## Bug fixes (crashes)

- Fix segfaults from `toView()` when compiled with newer nixpkgs (NixOS/nix#14154)
- Fix use-after-move in `DerivationGoal::repairClosure` and `SampleStack` (NixOS/nix#14086)
- Fix assertion failure on partially valid derivation outputs (NixOS/nix#14137)
- Fix `RestrictedStore::addDependency` recursion causing crashes (NixOS/nix#14729)
- Fix crash on flakerefs containing newlines (NixOS/nix#14450)

## Bug fixes (functionality)

- Fix fakeSSH check breaking SSH copies with `user@host` format (NixOS/nix#14150)
- Fix `builtins.dirOf` regression from Nix 2.23 (NixOS/nix#14515)
- Restore missing `isAllowed` check in `ChrootLinuxDerivationBuilder` (NixOS/nix#14531)
- Fix curl with c-ares failing to resolve DNS in sandbox on macOS (NixOS/nix#14792)
- Fix tarball percent decoding for `file://` URIs (NixOS/nix#14729)
- `exportReferencesGraph`: Handle heterogeneous arrays (NixOS/nix#13861)
- Fix filesystem ops in store optimization (NixOS/nix#14676)

## Bug fixes (output)

- Fix double-quoting of paths in logs (NixOS/nix#14210)
- Include path in world-writable error messages (NixOS/nix#14785)

## Improvements

- Better git refnames validation (NixOS/nix#14253)
- Use pure/restricted eval for help pages (NixOS/nix#14156)
- Improve store-reference compatibility with IPv6 ZoneId literals (NixOS/nix#14134)
- Correct `build-dir` error in manual (NixOS/nix#14745)

## Build system

- Add mdbook 0.5 support (NixOS/nix#14690)
- Drop legacy Apple SDK pattern (NixOS/nix#13976)

https://github.com/NixOS/nix/releases/tag/2.31.3
philiptaron added a commit to philiptaron/nixpkgs that referenced this pull request Jan 15, 2026
Changelog of fixes:

## Bug fixes (crashes)

- Fix segfaults from `toView()` when compiled with newer nixpkgs (NixOS/nix#14154)
- Fix use-after-move in `DerivationGoal::repairClosure` and `SampleStack` (NixOS/nix#14086)
- Fix assertion failure on partially valid derivation outputs (NixOS/nix#14137)
- Fix `RestrictedStore::addDependency` recursion causing crashes (NixOS/nix#14729)
- Fix crash on flakerefs containing newlines (NixOS/nix#14450)

## Bug fixes (functionality)

- Fix fakeSSH check breaking SSH copies with `user@host` format (NixOS/nix#14150)
- Fix `builtins.dirOf` regression from Nix 2.23 (NixOS/nix#14515)
- Restore missing `isAllowed` check in `ChrootLinuxDerivationBuilder` (NixOS/nix#14531)
- Fix curl with c-ares failing to resolve DNS in sandbox on macOS (NixOS/nix#14792)
- Fix tarball percent decoding for `file://` URIs (NixOS/nix#14729)
- `exportReferencesGraph`: Handle heterogeneous arrays (NixOS/nix#13861)
- Fix filesystem ops in store optimization (NixOS/nix#14676)

## Bug fixes (output)

- Fix double-quoting of paths in logs (NixOS/nix#14210)
- Include path in world-writable error messages (NixOS/nix#14785)

## Improvements

- Better git refnames validation (NixOS/nix#14253)
- Use pure/restricted eval for help pages (NixOS/nix#14156)
- Improve store-reference compatibility with IPv6 ZoneId literals (NixOS/nix#14134)
- Correct `build-dir` error in manual (NixOS/nix#14745)

## Build system

- Add mdbook 0.5 support (NixOS/nix#14690)
- Drop legacy Apple SDK pattern (NixOS/nix#13976)

https://github.com/NixOS/nix/releases/tag/2.31.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport 2.28-maintenance Automatically creates a PR against the branch backport 2.29-maintenance Automatically creates a PR against the branch backport 2.30-maintenance Automatically creates a PR against the branch backport 2.31-maintenance Automatically creates a PR against the branch backport 2.32-maintenance Automatically creates a PR against the branch documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fails to build with mdbook >= 0.5.0

4 participants