Replace m2r2 with myst-parser for docs builds#14808
Open
rtibbles wants to merge 2 commits into
Open
Conversation
The root-relative repo paths rendered as broken links on the built docs site. myst-parser resolves document cross-references strictly, so they also need to be correct for the build to pass once it replaces m2r2. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
m2r2 is unmaintained and pins old mistune versions, which blocked dependabot's mistune security update in learningequality#14794. myst-parser handles both of m2r2's jobs: parsing .md source files (the howtos) and including markdown files in rst documents, via docutils' include directive with the :parser: option in place of mdinclude. This drops mistune from the dependency tree entirely. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
Build Artifacts
Smoke test screenshot |
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.
Summary
Replaces unmaintained
m2r2withmyst-parserfor the docs build, droppingmistune(whose security update it was blocking in #14794) from the dependency tree entirely.References
Supersedes #14794, where the reviewer suggested this replacement.
Reviewer guidance
Check the docs CI job and the readthedocs build pass and produce valid output. Pages touched by this change to spot-check in the readthedocs preview: changelog, contributing/authors, contributing/code_of_conduct, and howtos/working_with_urls_and_api_endpoints (link targets at the bottom).
AI usage
Implemented with Claude Code; it verified the change with strict
-Wdocs builds on Python 3.9 and 3.11 locally, and I reviewed the diff.