Skip to content

k9-validate over-fires on contractile Nickel library modules (missing K9! / pedigree.name) #434

Description

@hyperpolymath

Problem

k9-validate-action (used estate-wide via dogfood-gate.yml; source k9-svc/actions/validate/validate-k9.sh) requires every .k9/.k9.ncl to (1) start with the K9! magic line and (2) carry a resolvable pedigree.name. But the canonical contractile files are Nickel library modules — e.g. this repo's own .machine_readable/contractiles/must/must.k9.ncl starts with # SPDX…, is let base_k9 = import … in { pedigree = base_k9.pedigree_schema & {…} }, and nests metadata.name via the imported base. So the validator flags the canon's own files.

Evidence (estate-wide, not per-repo)

Confirmed on hermeneia dogfood-gate runs: 24 K9 errors across contractiles/*, arrival-pack/, coaptation/, self-validating/, container/stapeln/deploy.k9.ncl, coordination.k9, session/custom-checks.k9. Two classes:

  • "Missing K9! magic number (first non-empty line must be exactly 'K9!')"
  • "Pedigree block missing 'name'" / "Missing pedigree block"

Because standards' own must.k9.ncl has the same shape, this is upstream validator/scaffolding drift, not a leaf bug — patching individual repos just diverges them from canon.

Fix options (decide at source)

  • (a, recommended) Teach validate-k9.sh to recognize imported library modules (& base_k9, or files that are imported rather than standalone components) as a distinct class, and resolve pedigree.name through the imported schema.
  • (b) Require K9! + a top-level resolvable name on every contractile module across the template.

Also

SHA-pin the k9-validate-action@<sha> # main ref in the dogfood-gate template — it currently tracks a moving main, so behavior drifts under repos without notice.

Targets / acceptance

k9-svc (validator source) + the published hyperpolymath/k9-validate-action; propagate to rsr-template-repo. Acceptance: dogfood-gate "Validate K9 contracts" passes on a clean RSR repo without mangling the contractile modules.


Filed from a Claude Code session working on hermeneia. Add to the master scheduler.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions