Repository navigation
Move docs off MkDocs onto ProperDocs, upgrade Material to 9.7, fix broken links - #341
Merged
Merged
Conversation
MkDocs has been unmaintained upstream since August 2024, and its planned v2 explicitly drops support for existing themes, plugins and config files. The docs group had no upper bound on `mkdocs`, so a v2 release to PyPI would have broken the docs build outright. Switch the build engine to ProperDocs, a drop-in fork of MkDocs 1.x that is committed to no breaking changes. Its output is byte-identical to MkDocs apart from the `<meta name="generator">` tag, and `mike` detects and drives it automatically from 2.2 onwards, so `docs/_deploy.py` and the build-docs workflow need no changes. `mkdocs` is still pulled in transitively by mkdocs-material and mike, so it is capped below v2. Also bump Material for MkDocs from 9.5 to 9.7. That is the final feature release before it goes to end of life in November 2026, and it folds in the features that used to be exclusive to Insiders. The rendered output is unchanged apart from asset hashes and a FontAwesome 6 to 7 bump. Finally, drop mkdocs-github-admonitions-plugin and its `gh-admonitions` entry. Nothing in docs/ uses GitHub-style `> [!NOTE]` alerts, so it was dead configuration. Verified by building the site with both the old and new toolchains and diffing: the same 30 pages are produced, and the visible text of every page is identical except for the two pages whose source changed on main. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CBo3PGTF2T7gT2X1wut1Ft
Commit e608f63 split `documentation/panels.md` into `panels/overview.md`, `panels/tips.md` and `panels/advanced.md`, but two references to the old path were missed: - The comparison page linked to `panels/panels.md`, which rendered as a dead link. - The `groups_and_sorting.md` redirect pointed at `documentation/panels.md`, so the redirect page was skipped entirely and the old v1.8 URL 404'd. It now resolves to the overview page again. Also fix the panels overview image, which had one `../` too many and so never rendered, and mark `documentation/structure.md` as `not_in_nav`. That page is a deliberate under-construction stub whose nav entry is commented out, so the build no longer reports it as an oversight. It is still published, exactly as before. The docs now build with no warnings. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CBo3PGTF2T7gT2X1wut1Ft
Nothing stopped the links fixed in the previous commit from rotting again: a rename that orphans a link only produced a warning, and the build carried on and published the dead link. `strict: true` turns any warning into a build failure, which covers plugin warnings too. That matters here, because the broken `mkdocs-redirects` target was reported by the plugin rather than by the link checker, so no amount of `validation:` config would have caught it. The two `validation.links` options default to `info`, meaning broken anchors and malformed internal links are silently ignored. Raised to `warn` so `strict` acts on them. Neither surfaces any existing problem; the docs build clean today. Verified by reintroducing each of the three bugs from the previous commit in turn, plus a link to a non-existent anchor: each one now aborts the build. Also verified through `mike deploy`, which is the path CI actually uses, since `strict` has to survive mike's config handling to be worth anything. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CBo3PGTF2T7gT2X1wut1Ft
Dropping this in 003d852 was wrong. The check behind it grepped only the docs directory, but `docs/changelog.md` and `docs/contributing.md` are thin wrappers that pull in the root CHANGELOG.md and CONTRIBUTING.md via include-markdown, and those files contain five GitHub-style alerts: four in the changelog, one in the contributing guide. Without the plugin they rendered as plain blockquotes with a literal "[!WARNING]" or "[!NOTE]" as the first line of body text. The plugin has to run after include-markdown for this to work, since the alerts arrive with the included content, so it goes back in the same position it was in before, now with a comment saying why. Re-verified against origin/main properly this time, by text-diffing every page rather than sampling: the only difference across all 30 shared pages is the new changelog entries themselves, plus the groups_and_sorting redirect page this branch restores. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CBo3PGTF2T7gT2X1wut1Ft
pyproject-fmt aligns trailing comments to the longest entry in the list, so adding `mkdocs-github-admonitions-plugin` back in 70de252 shifted the column and left the `mike` comment two spaces short. I ran the formatter after the earlier edits to this list but not after that one, which is what broke the prek job. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CBo3PGTF2T7gT2X1wut1Ft
Collaborator
|
Ah, TIL about ProperDocs. I did know MkDocs was unmaintained but I didn't know there was a replacement. Cool! |
Owner
Author
|
Yes - it's a bit of a mess but it's something. I don't see it as much more than a stopgap though to be honest, as mkdocs-material is still unmaintained now. Zensical is being touted as the successor and seems very nice to use, but it's still early days and it doesn't have much in the way of customisability yet. My favourite is still Astro (see other proof-of-concept PR #342). |
Collaborator
Collaborator
|
Oh! Looked more carefully. I see the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

MkDocs has been unmaintained since August 2024 and its planned v2 drops support for existing themes, plugins and config files — and our
mkdocspin had no upper bound, so a v2 release to PyPI would have broken the docs build outright. Material for MkDocs is also EOL on 5 November 2026.This swaps the build engine for ProperDocs (a drop-in fork of MkDocs 1.x), bumps Material 9.5 → 9.7, fixes some long-standing broken links, and turns on
strictso links can't rot again. The site looks and works exactly as before — verified page by page. The eventual move to Zensical is deliberately not attempted here.Two things worth a second opinion, both covered below: the
mikefloor bump, and whetherstrictis too sharp an edge.Details
Changes
Build engine → ProperDocs
ProperDocs is a fork of MkDocs 1.x committed to no breaking changes. Its output is byte-identical to MkDocs apart from the
<meta name="generator">tag, andmikedetects and drives it automatically, sodocs/_deploy.pyand.github/workflows/build-docs.ymlneed no changes at all.One gotcha worth flagging for review:
mikeonly gained ProperDocs detection in 2.2. The oldmike>=2.1.3floor would have let a resolve land on 2.1.3 and silently keep building through MkDocs, so the floor is bumped.mkdocsis still pulled in transitively by mkdocs-material and mike, so it is capped below v2.Material for MkDocs 9.5 → 9.7
The final feature release, which folds in the features that used to be exclusive to Insiders. Builds clean with no config changes. Rendered output is unchanged apart from asset hashes and a FontAwesome 6 → 7 bump.
Fixed broken links
e608f63splitdocumentation/panels.mdintopanels/{overview,tips,advanced}.mdand left two references behind:panels/panels.md, a dead link.groups_and_sorting.mdredirect pointed atdocumentation/panels.md. Because the target did not exist, mkdocs-redirects skipped the page entirely, so the old v1.8 URL/documentation/groups_and_sorting/was returning a hard 404 rather than redirecting. It resolves again now.Also fixed the panels overview image, which had one
../too many and so never rendered, and marked the under-constructiondocumentation/structure.mdasnot_in_nav(it is still published, exactly as before).strict: trueNothing stopped those links from rotting again.
strictturns any warning into a build failure, including plugin warnings — which matters, because the broken redirect target was reported by mkdocs-redirects rather than by the link checker, so novalidation:setting would have caught it.validation.links.anchorsandunrecognized_linksdefault toinfo, meaning broken anchors pass silently; both are raised towarnsostrictacts on them. Neither surfaces any existing problem.Trade-off worth a second opinion:
strictis indiscriminate. If the social-cards, rss or glightbox plugins ever emit a warning,mainstops publishing docs until someone fixes it. Happy to drop thestrictcommit if that is too sharp an edge.Testing
Built
origin/mainwith its own toolchain (MkDocs 1.6.1, Material 9.5.50) and this branch with the new one, then text-diffed every page:mainis missing here. One page is added: the restoredgroups_and_sortingredirect.mike deploy --update-aliases 1.9 latestin a scratch clone: builds via ProperDocs, writes togh-pages,mike listreports1.9 [latest],versions.jsoncorrect, version-selector markup unchanged.mike deploypath that CI uses.prek run -aclean locally (minusactionlint, which needs a Go download, andmypy, which needs project deps — both pass in CI).Not verified: social card generation. The sandbox blocks
fonts.google.com, which the plugin fetches Kode Mono from, so the comparison builds ran without it. The plugin loads fine under ProperDocs — it gets as far as the font fetch — but the first CI run is what will confirm the cards still render. Worth watching on merge, particularly now thatstrictwould turn a warning from it into a failed deploy.A correction, for the record
An earlier revision of this branch dropped
mkdocs-github-admonitions-pluginas unused. That was wrong, and70de252puts it back.docs/changelog.mdanddocs/contributing.mdare thin wrappers that pull in the rootCHANGELOG.mdandCONTRIBUTING.mdvia include-markdown, and those two files contain five GitHub-style alerts that rendered as plain blockquotes with a literal[!WARNING]in the body text without the plugin. The net change to that plugin's config in this PR is now just a comment explaining that it has to run after include-markdown.Why not Zensical
Zensical is the official successor and where this should eventually land, but at 0.0.53 it is not ready for this project specifically. Building these docs with it: the
editor.htmloverride fails outright (minijinja has no.items()on maps), the blog plugin is unsupported so every existing post URL changes and archive/category pages vanish, RSS and redirects produce no output, andinclude-markdownmarkers pass through raw (the changelog page drops from 74 KB to 21 KB). Worth revisiting once blog support lands.