chore(deps): relax pymdown-extensions upper bound to allow 11.x#10332
Open
tschm wants to merge 1 commit into
Open
chore(deps): relax pymdown-extensions upper bound to allow 11.x#10332tschm wants to merge 1 commit into
tschm wants to merge 1 commit into
Conversation
The `<11` cap has been in place since the initial commit as a conventional major-version guard, not because of a known incompatibility. Now that pymdown-extensions 11.x is out, the cap prevents downstream projects from upgrading while keeping marimo installed. Relax it to `<12`, matching how the other markdown-stack dependencies are capped (`markdown<4`, `pygments<3`). Verified against pymdown-extensions 11.0.1: - Nothing marimo imports from `pymdownx` changed (superfences `RE_NESTED_FENCE_START` and friends, `pymdownx.emoji.to_alt`, and the `pymdownx.blocks` API used by the docs extension). - 11.0 drops Python 3.9, which is already below marimo's `requires-python = ">=3.10"`. - 11.0's only breaking change is `pymdownx.b64` restricting relative links to `base_path` by default. marimo enables b64 only under WASM and already scopes it to the notebook directory, so the new default matches the existing intent. - `tests/` (minus `test_cli`) produces an identical result on 11.0.1 and 10.21.3. Also replace the stale "Pinned to specific version for introduction of codeblock handling" comment with the actual reasons for the lower bound. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates marimo’s runtime dependency constraints to allow pymdown-extensions 11.x, aligning the upper-bound strategy with the rest of the markdown stack while keeping the existing safety floor tied to known pygments compatibility.
Changes:
- Relax
pymdown-extensionsupper bound from<11to<12inpyproject.toml. - Update the dependency snapshot to reflect the new constraint.
- Replace the stale “pinned for codeblock handling” note with more specific lower-bound rationale.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
pyproject.toml |
Relaxes pymdown-extensions upper bound to <12 and clarifies why the lower bound is >=10.21.2. |
tests/snapshots/dependencies.txt |
Updates the dependency snapshot to match the new pymdown-extensions constraint. |
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.
This pull request was authored by a coding agent.
📝 Summary
Closes #10328
pymdown-extensionswas capped at<11. That cap has been there since the initial commit as a conventional major-version guard — the git history shows every subsequent change only ever moved the lower bound. Withpymdown-extensions11.x released, the cap blocks downstream projects from upgrading while keeping marimo installed:This relaxes it to
>=10.21.2,<12, matching how the rest of the markdown stack is capped (markdown<4,pygments<3).It also replaces the stale
# Pinned to specific version for introduction of codeblock handling.comment with the actual reasons for the lower bound — that comment predates the two bumps that set the current floor and no longer described it.Compatibility with 11.x
Checked each of 11.0's changes against how marimo uses
pymdownx:requires-python = ">=3.10", andpymdown-extensions11.x declares>=3.10pymdownx.b64restricts relative links tobase_pathby default (newrestrict_pathoption)b64only under WASM (marimo/_output/md.py), scoped to the notebook directory. Restricting tobase_pathmatches the existing intent — the code comment there already says b64 stays off elsewhere because "app users could potentially use it to grab files they shouldn't have access to." The new default is strictly tighter, so norestrict_pathoverride is set (which also keeps 10.x working, since the option doesn't exist there).pymdownx.tabbedempty-title fixEvery
pymdownxsymbol marimo imports still exists and behaves the same on 11.0.1:superfences.RE_NESTED_FENCE_STARTand the other superfences internals (marimo/_convert/markdown/to_ir.py,marimo/_convert/ipynb/to_ir.py),pymdownx.emoji.to_alt, and thepymdownx.blocks/pymdownx.blocks.blockAPI that the docsmarimo-embedextension is built on (docs/blocks/__init__.py).Verification
Ran the CI test selection (
pytest tests/ -k "not test_cli", ~11k tests) twice onpymdown-extensions==11.0.1and once on10.21.3. The results are identical — same pass count, same failure set. The failures present in all three runs are pre-existing and local to my machine (they come from amanager = "pixi"setting in my user-level~/.config/marimo/marimo.tomlleaking intotests/_code_mode/; unrelated to markdown).The
pymdownx.b64WASM round-trip is covered by the existingtest_md_with_b64_in_wasm, which actually inlines a PNG and passes on 11.0.1. I also rendered amarimo-embedblock through the docs extension on 11.0.1 to confirm the docs blocks API still works.One thing for maintainers to note
CI won't actually exercise 11.x yet. The
docsgroup pinsmkdocs-material==9.6.20, which requirespymdown-extensions~=10.2; because uv resolves all groups together, the whole-workspace resolution stays on 10.x regardless of this cap. So the 11.x verification above was done by force-installingpymdown-extensions==11.0.1into the test environment.#10333 lifts that pin, which lets CI resolve 11.x. The two PRs are independent and can merge in either order — this one relaxes the cap, that one lets the resolver act on it.
📋 Pre-Review Checklist
✅ Merge Checklist
tests/snapshots/dependencies.txtsnapshot asserted bytests/test_project_dependencies.pyis updated to the new constraint; no new behavior to test.🤖 Generated with Claude Code