Repository navigation
Check anchors, and the links in admonitions and tabs, with lychee - #41
Merged
Merged
Conversation
lychee reads Markdown as CommonMark, so the four-space-indented content of admonitions and content tabs was code to it, and their links went unchecked. One of them redirected permanently from docs.microsoft.com to learn.microsoft.com. lychee now also checks the links in code, apart from the local preview address, and each link's anchor or text fragment. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
uv run --group links also installed the project and the dev group, including actionlint-py, which uv builds from source by downloading actionlint. A failed download there would fail the weekly link check, so the task now installs the links group alone. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
patrick-5546
commented
Dec 3, 2026
Owner
Author
|
Answers to your review:
|
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.
lychee now checks each link's anchor, and the links inside admonitions and content tabs, which it skipped before.
Changes
include_verbatim = truechecks the links in code as well. The only addition besides those two is the README'sgit cloneURL.exclude_loopback = trueskips the README's preview address,http://localhost:8000.include_fragments = "full"checks that each link's anchor is on its page, along with the text of the one text fragment (#:~:text=), on the Atlassian rebase page. The strict build already checks the anchors in links between pages.make linksinstalls only lychee:uv run --only-group links. Before,--group linksalso installed the project and the dev group. That includes actionlint-py, which uv builds from source by downloading actionlint, so a failed download, after an update empties the cache, could have failed the weekly check.Not changed, and why
check_githubinlychee-lib/src/checker/website.rs). lychee uses the token only after a request fails, to ask GitHub's API whether the repository exists. For a link with a path, such as a file page, it still reports the failure. The throttling and accepted 429/503 already cover the rate limits.Verification
make lintandmake buildpass.make linksreports 235 links, 225 unique: 232 OK, 0 errors and 3 excluded (two LinkedIn profiles and the preview address). The only redirect left is thegit cloneURL,notes.git, which is right forgit clone.acceptallows, so its 7 links still aren't really checked.lychee.tomlchanges.