Skill YAML invalid + missing typecheck-hook install on mosaic@0.0.30 #515
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Fresh
mosaic claudesession on@mosaicstack/mosaic@0.0.30surfaces three startup warnings that all originate from the shipped framework — two malformed skill manifests and a hook that the audit requires but the installer never lays down.1. Invalid YAML in shipped SKILL.md frontmatter
Both
description:values are unquoted and contain a:(colon-space) sequence, which YAML 1.2 parses as a nested mapping separator. Claude Code's skill loader uses a strict parser and drops the skill entirely —mosaic-woodpeckerandmosaic-deployare unavailable in every Claude session until this is fixed.framework/skills/mosaic-woodpecker/SKILL.md(line 2, col 245 —CI URL: https://...)framework/skills/mosaic-deploy/SKILL.md(line 2, col 67 —Mosaic Stack projects: push branch ...)Fix
Single-quote both
description:values (no embedded single quotes, so this is safe and minimal). Verified locally withyaml.safe_load:(Optionally replace the arrow characters in the deploy description with
->to keep the frontmatter ASCII-only.)A repo-wide guard would be cheap insurance — e.g. a CI step that runs
yaml.safe_loadon the frontmatter of everyframework/skills/*/SKILL.md. Happy to send a PR with the two edits plus a validator if helpful.2.
typecheck-hook.shaudited but not installedmosaic launch(dist/commands/launch.js:80) declares:and
framework/runtime/claude/settings.jsondefines a PostToolUse entry for~/.config/mosaic/tools/qa/typecheck-hook.sh. But on this install:~/.config/mosaic/tools/qa/typecheck-hook.shdoes not exist (other QA hooks in the same dir do —qa-hook-stdin.sh,qa-hook-handler.sh, etc.)~/.claude/settings.jsonPostToolUse only contains theqa-hook-stdin.shentry; thetypecheck-hook.shentry was never written.So the audit reliably fires on every launch and the suggested remediation (
mosaic doctor) does not appear to repair it (need to confirm — possiblydoctoronly warns, doesn't sync).Manual repair that resolved it locally:
Likely root cause
Either the installer's qa-tools sync step is missing
typecheck-hook.shfrom its file list, or it was added to the audit (launch.js) and runtime template after the install/sync logic was updated, leaving prior installs out of sync.Suggested fix
mosaic doctoractively repair the two settings-audit failures (copy missing scripts fromframework/tools/qa/into~/.config/mosaic/tools/qa/, merge missing hook entries into~/.claude/settings.jsonfrom the framework template) — and exit non-zero if it can't.framework/tools/qa/directory rather than an explicit allowlist.Bonus:
tools/git/issue-create.shshell-injects the body stringDiscovered while filing this issue.
~/.config/mosaic/tools/git/issue-create.shbuilds theteacommand as a string and runs it witheval:Any markdown body containing backticked command names,
$(...)substitutions, parentheses, or special chars (:,→,;, etc.) is re-interpreted by the shell. Filing this very issue failed with ~30 spurious errors (command not found,syntax error near unexpected token '(') before I routed around it via the API. Should passtea's args as a real argv array (noeval), and likewise for the GitHubghpath if it has the same shape.Happy to open a separate issue for this if preferred.
Environment
@mosaicstack/mosaicversion:0.0.30Workaround applied locally
description:fields in~/.config/mosaic/skills/mosaic-*/SKILL.mdtypecheck-hook.shinto~/.config/mosaic/tools/qa/and appended the PostToolUse hook entry to~/.claude/settings.jsonAll three warnings cleared on next launch (pending session restart to confirm in CI/loader output).