Skip to content

Conversation

@dmadisetti
Copy link
Collaborator

📝 Summary

fixed #7026

If annotations without top-level resolution were quoted and containing quotes themselves, syntax breaking serialization occurred rendering a notebook un-openable.

This fixes this particular issue and additionally adds a defense guard such that invalid code should never be serialized.

@vercel
Copy link

vercel bot commented Nov 1, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
marimo-docs Ready Ready Preview Comment Nov 2, 2025 6:42pm

mscolnick
mscolnick previously approved these changes Nov 1, 2025
akshayka
akshayka previously approved these changes Nov 1, 2025
Copy link
Contributor

@akshayka akshayka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. But does it make sense to add a unit test for the unparsable code path?

@dmadisetti
Copy link
Collaborator Author

@akshayka I added a failure case by mocking. There's still an unhappy path where unparsable itself causes an issue- but at least we'll log an actionable error if that occurs

@dmadisetti
Copy link
Collaborator Author

Think CI will be fixed by #7034

@mscolnick mscolnick merged commit 8fbef8b into main Nov 2, 2025
34 of 59 checks passed
@mscolnick mscolnick deleted the dm/non-top-quote branch November 2, 2025 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Marimo ast parser got confused parsing something like: Final[Literal['int8']] resulting in SyntaxError

4 participants