{"record":{"id":"c08390995477b67e","repo":"Hmbown/CodeWhale","slug":"skill-md-name-must-be-a-single-path-safe-segment","errorCode":null,"errorMessage":"SKILL.md `name` must be a single path-safe segment (got '{name}')","messagePattern":"SKILL\\.md `name` must be a single path-safe segment \\(got '(.+?)'\\)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/tui/src/skills/install.rs","lineNumber":1625,"sourceCode":"            continue;\n        }\n        if let Some((key, value)) = line.split_once(':') {\n            let key = key.trim().to_ascii_lowercase();\n            let value = value.trim().to_string();\n            match key.as_str() {\n                \"name\" if !value.is_empty() => name = Some(value),\n                \"description\" if !value.is_empty() => has_description = true,\n                _ => {}\n            }\n        }\n    }\n\n    let name = name.ok_or(InstallError::MissingFrontmatterField(\"name\"))?;\n    if !has_description {\n        return Err(InstallError::MissingFrontmatterField(\"description\").into());\n    }\n    if validate_skill_name_segment(&name).is_err() {\n        bail!(\"SKILL.md `name` must be a single path-safe segment (got '{name}')\");\n    }\n    Ok(name)\n}\n\nfn reject_unmarked_update(final_path: &Path, name: &str) -> std::result::Result<(), InstallError> {\n    if final_path.join(INSTALLED_FROM_MARKER).exists() {\n        Ok(())\n    } else {\n        Err(InstallError::NotInstalledHere(name.to_string()))\n    }\n}\n\npub(crate) fn source_spec_string(source: &InstallSource) -> String {\n    match source {\n        InstallSource::GitHubRepo(repo) => format!(\"github:{repo}\"),\n        InstallSource::DirectUrl(url) => url.clone(),\n        InstallSource::Registry(name) => name.clone(),\n    }","sourceCodeStart":1607,"sourceCodeEnd":1643,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/0c42157ee52f9d55af2b506d71b46249910f77d3/crates/tui/src/skills/install.rs#L1607-L1643","documentation":"parse_frontmatter_name extracted a name: value from SKILL.md frontmatter that is not a single path-safe segment (it contains '/', '\\\\', '.' or '..' or spans multiple components). The name is used to build the on-disk package directory name, so a non-segment name would create unsafe or nested paths; the frontmatter name is the input at fault.","triggerScenarios":"Thrown at crates/tui/src/skills/install.rs:1625 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Edit the SKILL.md frontmatter name: to a single path-safe segment (letters, digits, hyphens)","Remove any path separators or '..' from the frontmatter name","Use the directory name or skill slug exactly, without nesting"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0c42157ee52f9d55af2b506d71b46249910f77d3","analyzedAt":"2026-08-20T21:50:45.477Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}