{"record":{"id":"8ecbe3f4f3a0e690","repo":"zed-industries/zed","slug":"failed-to-parse-notebook","errorCode":null,"errorMessage":"Failed to parse notebook: {:?}","messagePattern":"Failed to parse notebook: (.+?)","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/repl/src/notebook/notebook_ui.rs","lineNumber":1967,"sourceCode":"let notebook = nbformat::parse_notebook(&file_content);\nlet notebook = match notebook {\n    Ok(nbformat::Notebook::V4(notebook)) => notebook,\n    Ok(nbformat::Notebook::Legacy(legacy_notebook)) => {\n        nbformat::upgrade_legacy_notebook(legacy_notebook)?\n    }\n    Ok(nbformat::Notebook::V3(v3_notebook)) => {\n        nbformat::upgrade_v3_notebook(v3_notebook)?\n    }\n    Err(e) => {\n        anyhow::bail!(\"Failed to parse notebook: {:?}\", e);\n    }\n};","sourceCodeStart":1949,"sourceCodeEnd":1985,"githubUrl":"https://github.com/zed-industries/zed/blob/f4178619acd0d47ea1f76a2025c42962c6d6638c/crates/repl/src/notebook/notebook_ui.rs#L1949-L1985","documentation":"Error raised while loading a notebook file in the notebook UI: `nbformat::parse_notebook` failed to interpret the serialized JSON as a valid notebook format (V4, V3, or legacy). The debug-formatted parse error is embedded in the message. Loading is aborted before cells are constructed.","triggerScenarios":"Thrown at crates/repl/src/notebook/notebook_ui.rs:1967 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Re-export or re-save the notebook from Jupyter to regenerate valid nbformat JSON.","Validate the notebook JSON structure manually and fix malformed cells, metadata, or nbformat version fields.","Open a different, known-good notebook to confirm the issue is specific to this file."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"f4178619acd0d47ea1f76a2025c42962c6d6638c","analyzedAt":"2026-08-20T19:29:52.058Z","contentChangedAt":"2026-08-20T19:29:52.058Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}