MB005: invalid-syntax¶
🚨 Breaking ❌ Not Fixable
MB005: Cell contains code that throws a SyntaxError on compilation.
What it does¶
Attempts to compile each cell using marimo's internal compiler and catches any SyntaxError exceptions that occur during the compilation process.
Why is this bad?¶
Cells with syntax errors cannot be executed, making the notebook non-functional. SyntaxErrors prevent marimo from creating the dependency graph and running the reactive execution system, breaking the core functionality of the notebook.
Examples¶
Problematic:
Problematic:
Problematic:
Solution:
Solution:
Solution: