Error message using unclear cell identifier instead of cell number
bug
### Describe the bug
When I try to run a cell whose ancestor raises an exception, I get the following message:
```
Ancestor raised: An ancestor raised an exception (NameError): (raised in cell: 918d2406-014b-4a20-9c9a-ba8cb7ab2ba2)
```
How do I know which cell this is referring to? Is it possible to change error messages like this one to have the number of the cell raising the error and possibly a hyperlink for easier discovery?
### Environment
<details>
```
marimo VS Code Extension Diagnostics
=====================================
Language Server (LSP):
UV Bin: Bundled (/Users/albi/.vscode/extensions/marimo-team.vscode-marimo-0.13.3-darwin-arm64/bundled/libs/bin/uv)
UV: 0.11.3 (45da18ac3 2026-04-01) ✓
Using bundled marimo-lsp via uvx
Python Extension:
Interpreter: /Users/albi/.cache/uv/environments-v2/analysis-slide-4a-7e7dcfc4bd200a5b/bin/python
Version: 3.14.3.final.0
Environment: VirtualEnvironment (analysis_slide_4A.py (3.14.3))
Python Language Server (ty):
Status: running ✓
Version: 0.0.26 (940305127 2026-03-26)
Binary: UvInstalled (/Users/albi/Library/Application Support/Code/User/globalStorage/marimo-team.vscode-marimo/libs/bin/ty)
Python: /Users/albi/.cache/uv/environments-v2/analysis-slide-4a-7e7dcfc4bd200a5b/bin/python (3.14.3.final.0)
Ruff Language Server:
Status: disabled
Reason: Ruff extension (charliermarsh.ruff) is not installed.
Extension Configuration:
Version: 0.13.3
UV integration disabled: false
System Information:
Host: desktop
IDE: Visual Studio Code
IDE version: 1.122.1
Platform: darwin
Architecture: arm64
Node version: v22.22.1
Common Issues:
1. If notebooks won't open:
- Check Python interpreter is selected
- Ensure marimo is installed
- Check 'marimo-lsp' output channel for errors
2. If features are missing:
- Ensure marimo version is >= 0.23.3
- Try reloading the window
```
</details>
### Steps to reproduce
Copy-paste this code in vscode, open with the Marimo extension and run the second cell.
```pyhton
# /// script
# requires-python = ">=3.10"
# dependencies = [
# "marimo>=0.23.8",
# ]
# ///
import marimo
__generated_with = "0.23.6"
app = marimo.App()
@app.cell
def _():
# Cell 1
items = ["gene_a", "gene_b", "gene_c"]
# This variable is defined before the failure
selected_gene = items[0]
# This line fails
missing_gene = items[3]
return (selected_gene,)
@app.cell
def _(selected_gene):
# Cell 2
print(selected_gene)
return
if __name__ == "__main__":
app.run()
```
1 条评论