{"record":{"id":"a53721c02505250e","repo":"zed-industries/zed","slug":"invalid-snippet-name-in-source-e","errorCode":null,"errorMessage":"Invalid snippet '{name}' in {source:?}: {e:#}","messagePattern":"Invalid snippet '(.+?)' in (.+?): (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/snippet_provider/src/lib.rs","lineNumber":58,"sourceCode":"        .snippets\n        .into_iter()\n        .map(move |(name, snippet)| {\n            let snippet_name = name.clone();\n            let prefixes = snippet\n                .prefix\n                .map_or_else(move || vec![snippet_name], |prefixes| prefixes.into());\n            let description = snippet\n                .description\n                .map(|description| description.to_string());\n            let body = snippet.body.to_string();\n            match snippet::Snippet::parse(&body) {\n                Ok(_) => Ok(Arc::new(Snippet {\n                    body,\n                    prefix: prefixes,\n                    description,\n                    name,\n                })),\n                Err(e) => Err(anyhow::anyhow!(\n                    \"Invalid snippet '{name}' in {source:?}: {e:#}\"\n                )),\n            }\n        })\n}\n\n// Snippet with all of the metadata\n#[derive(Debug)]\npub struct Snippet {\n    pub prefix: Vec<String>,\n    pub body: String,\n    pub description: Option<String>,\n    pub name: String,\n}\n\nasync fn process_updates(\n    this: WeakEntity<SnippetProvider>,\n    entries: Vec<PathBuf>,","sourceCodeStart":40,"sourceCodeEnd":76,"githubUrl":"https://github.com/zed-industries/zed/blob/f4178619acd0d47ea1f76a2025c42962c6d6638c/crates/snippet_provider/src/lib.rs#L40-L76","documentation":"A snippet named `name` in the given snippets file failed to parse (bad tabstop/placeholder/variable syntax); the parse error is fully chained, and the invalid snippet is reported while the rest of the file loads.","triggerScenarios":"Thrown at crates/snippet_provider/src/lib.rs:58 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Fix the snippet body syntax reported in the chained error","Remove or correct the offending snippet in the file"],"exampleFix":null,"handlingStrategy":"try-catch","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-14T05:17:10.506Z"}