We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 40769e6 commit 5a25a91Copy full SHA for 5a25a91
jupyter_mcp_server/tools/execute_cell_tool.py
@@ -192,10 +192,14 @@ async def execute(
192
cell_id = ydoc.ycells[cell_index].get("id")
193
cell_source = ydoc.ycells[cell_index].get("source")
194
195
- if not cell_source or not cell_source.to_py().strip():
+ if isinstance(cell_source, str):
196
+ code_to_execute = cell_source
197
+ else:
198
+ code_to_execute = cell_source.to_py()
199
+
200
+ if not code_to_execute or not code_to_execute.strip():
201
return []
202
- code_to_execute = cell_source.to_py()
203
document_id = f"json:notebook:{file_id}"
204
205
# Execute with RTC metadata - outputs will sync automatically
0 commit comments