name: codd-validate description: | Validate CoDD frontmatter and dependency references before scan, impact, generation, or propagation work continues. Use when the user needs to confirm YAML frontmatter, required metadata, dependency references, and graph inputs are parseable and internally consistent.
CoDD Validate
Validate CoDD frontmatter and dependency references before impact analysis so broken metadata does not poison the graph or downstream change-propagation work.
Usage
Run this skill after codd scan --path ., after editing requirement or design documents, or any time you suspect frontmatter or dependency references may be inconsistent.
Instructions
Preflight:
- Work from the project root.
- Verify
codd/codd.yamlexists. If not, runcodd initfirst. - If the
coddcommand is not available, install the package so the CLI entry point is onPATHbefore continuing.
Run validation:
codd validate --path .
Interpret the result:
- PASS: Treat
OK: validated ...output as a pass. Frontmatter is structurally valid enough to proceed, and dependency references are consistent enough for the next step. After a clean pass,codd impactis safe to run. - ERROR: Stop and fix the reported documents before continuing. Use the categories below to decide the repair.
- BLOCKED or WARNING: Read the message, fix what is actionable, and re-run validation until the remaining output is understood.
- PASS: Treat
ERROR triage by category:
missing_field: Required frontmatter data is missing or malformed. Open the affected design document and add or repair the needed fields, especiallynode_id,title, anddepends_onwhen the design requires declared upstream dependencies. In current validator output, this often appears as missing or invalid frontmatter rather than a literalmissing_fieldcode.invalid_reference: A document references anode_idthat does not exist or is misspelled. Correct the typo or point the reference at the real upstream node. In current validator output, this usually shows up as undefined-reference messages such as danglingdepends_onordepended_by.circular_dependency: Two or more documents depend on each other in a loop. Revisitdepends_on, remove the back-edge, and restore a one-way dependency order.
Fix broken frontmatter step by step:
- Open the document named in the validation error.
- Inspect the YAML frontmatter at the top of the file, bounded by
---. - Confirm the required fields are present and valid:
node_id,title, anddepends_onwhere applicable. - Save the correction.
- Re-run
codd validate --path .and confirm the error is gone.
Recommended
scan -> validateflow:
codd scan --path .
codd validate --path .
# fix reported errors
codd validate --path .
Troubleshooting:
Error: codd/ not found. Run 'codd init' first.: Initialize the project before validating.command not found: codd: Install the package or activate the environment that exposes thecoddconsole script.invalid_frontmatter: Fix YAML syntax first. Common causes are missing:separators, bad indentation, or an unclosed list entry.missing_frontmatterormissing_field: Add the missing CoDD frontmatter block and required fields, then validate again.dangling_depends_onordangling_depended_by: Treat these asinvalid_referenceproblems and repair the referencednode_id.- Repeated
circular_dependencyerrors: Draw the dependency chain on paper, decide which document is the real upstream source of truth, and remove the reverse dependency.
Exit condition:
- Do not move on to
codd impactuntil validation is clean or the remaining warnings are explicitly understood and accepted.
- Do not move on to