Problem
k9iser's code generator emits .k9 contracts that fail the canonical hyperpolymath/k9-validate-action:
::error::Missing K9! magic number. First non-empty line must be exactly 'K9!'
::error::Missing pedigree block. K9 files must contain a 'pedigree = { ... }' section
Example emitted file (idaptik/generated/k9iser/deno-workspace.k9):
# Auto-generated K9 contract for deno-workspace
# Safety tier: yard
[must]
[trust]
signed-by = "ci-pipeline"
...
No K9! first line; no pedigree = { ... } block.
Root cause
The codegen path (src/codegen/contract.rs) emits a TOML-section shape ([must]/[trust]/[dust]/[intend]) that diverges from the canonical K9 templates. The templates themselves are correct — .machine_readable/svc/k9/template-{yard,hunt,kennel}.k9.ncl all start with K9! and a full pedigree = { ... } block. The generator does not honour that shape.
Impact (estate-wide)
Every repo that runs k9iser and gates on Dogfood Gate's K9 step is red on the generated artifacts: idaptik, verisimiser, neurophone, vscode-a2ml, vscode-k9, aerie, accessibility-everywhere, nextgen-language-evangeliser, … (any repo with k9iser.toml).
Surfaced while triaging idaptik#77 (Dogfood Gate triage). idaptik's A2ML side is fully resolved; the K9 side is blocked solely on this generator defect.
Fix direction
src/codegen/contract.rs should emit, for each generated .k9:
K9! as the first non-empty line.
- A
pedigree = { ... } block (schema_version, component_type, security{leash,…}, metadata{name,version,…}) consistent with template-<tier>.k9.ncl.
Then regenerate across consumers.
🤖 Generated with Claude Code
Problem
k9iser's code generator emits.k9contracts that fail the canonicalhyperpolymath/k9-validate-action:Example emitted file (
idaptik/generated/k9iser/deno-workspace.k9):No
K9!first line; nopedigree = { ... }block.Root cause
The codegen path (
src/codegen/contract.rs) emits a TOML-section shape ([must]/[trust]/[dust]/[intend]) that diverges from the canonical K9 templates. The templates themselves are correct —.machine_readable/svc/k9/template-{yard,hunt,kennel}.k9.nclall start withK9!and a fullpedigree = { ... }block. The generator does not honour that shape.Impact (estate-wide)
Every repo that runs
k9iserand gates on Dogfood Gate's K9 step is red on the generated artifacts: idaptik, verisimiser, neurophone, vscode-a2ml, vscode-k9, aerie, accessibility-everywhere, nextgen-language-evangeliser, … (any repo withk9iser.toml).Surfaced while triaging idaptik#77 (Dogfood Gate triage). idaptik's A2ML side is fully resolved; the K9 side is blocked solely on this generator defect.
Fix direction
src/codegen/contract.rsshould emit, for each generated.k9:K9!as the first non-empty line.pedigree = { ... }block (schema_version, component_type, security{leash,…}, metadata{name,version,…}) consistent withtemplate-<tier>.k9.ncl.Then regenerate across consumers.
🤖 Generated with Claude Code