Bump matplotlib pin in tutorials to avoid Path.__deepcopy__ recursion - #10702
Open
afonsojanu wants to merge 1 commit into
Open
Bump matplotlib pin in tutorials to avoid Path.__deepcopy__ recursion#10702afonsojanu wants to merge 1 commit into
afonsojanu wants to merge 1 commit into
Conversation
plots.py, dataflow.py, and markdown.py were pinned to matplotlib==3.10.1, which hits an infinite recursion in Path.__deepcopy__ during savefig(bbox_inches="tight") under marimo's sandboxed edit mode. The fix for that landed upstream in matplotlib/matplotlib#30198; 3.10.9 already carries it and is already used by sql.py in this same directory. Fixes marimo-team#10680
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
All contributors have signed the CLA ✍️ ✅ |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the PEP 723 dependency pins for several built-in tutorials to avoid a matplotlib recursion bug triggered during figure rendering in --sandbox edit mode.
Changes:
- Bump
matplotlibpin from3.10.1to3.10.9inplots.py,dataflow.py, andmarkdown.pytutorial headers. - Align these tutorials’ matplotlib version with
sql.py, which already uses3.10.9.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| marimo/_tutorials/plots.py | Updates tutorial dependency pin to matplotlib==3.10.9 to avoid the sandbox rendering recursion. |
| marimo/_tutorials/markdown.py | Updates tutorial dependency pin to matplotlib==3.10.9 for consistency and to avoid the recursion. |
| marimo/_tutorials/dataflow.py | Updates tutorial dependency pin to matplotlib==3.10.9 to avoid the sandbox rendering recursion. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
3
to
8
| # requires-python = ">=3.12" | ||
| # dependencies = [ | ||
| # "marimo", | ||
| # "matplotlib==3.10.1", | ||
| # "matplotlib==3.10.9", | ||
| # "numpy==2.2.4", | ||
| # "polars==1.26.0", |
Author
|
I have read the CLA Document and I hereby sign the CLA |
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.
Closes #10680.
plots.py,dataflow.py, andmarkdown.pyundermarimo/_tutorials/are pinned tomatplotlib==3.10.1. That version hits an infinite recursion inPath.__deepcopy__when_render_figure_mimebundlecallssavefig(bbox_inches="tight"), which forces a full draw pass under marimo's sandboxed edit mode. The fix for that recursion landed upstream in matplotlib/matplotlib#30198, and 3.10.9 already carries it, the same versionsql.pyin this directory already uses without issue.Bumping the three affected tutorials to
matplotlib==3.10.9to match.