Repository navigation
feat: emit the config: plan-step verb (substitute + stage + egress-validate) - #237
Conversation
…lidate)
config: <dest> renders a config file from the candy's declared values:
SubstituteContent resolves ${NAME} against var: + auto-exports at generate
time (unresolved is a hard error); the rendered bytes ride the write:
content-addressed COPY path (no shell); validate: gates them through the
ValidateEgress seam (verb:egress, bytes mode) before staging. Spec pin
bumped to v0.2026250.922 (the config-verb contract).
Review — BLOCKHead SHA: Change class: sdk emitter feature (Go code + tests + dependency bump). Blocks
Notes (non-blocking)
Verdict: BLOCK ollama/deepseek-v4-flash — pi-review-action. |
Review — PASSHead SHA: Security screen: PASS — no secrets/exfiltration/network, no weakened guardrails, spec pin is a merged tag ( Checklist: All applicable rules PASS or NA. Prior BLOCK findings re-derived against CURRENT state:
Placement CORRECT (config: verb added to the deploykit emitter mechanism alongside write:/link:/download: — generic render mechanism, not a capability). R3/R4 honored (reuses TaskVarRefPattern/TaskUnresolvedRefs/StageInlineContent/EmitWrite/ValidateEgress; no shell heredoc). 6 new tests match body count and exercise the new code paths. SDD clean (consumes spec.Op fields, no hand-written wire types, no Verdict: PASS ollama/deepseek-v4-flash — pi-review-action. |
Summary
Implements the
config:plan-step verb emitter indeploykit(the schema contract landed in opencharly/spec#117; this PR consumes it).tasks_emit.go: newSubstituteContent(content, vars, img)— resolves ${NAME} refs in a config body against the candy's declaredvar:plus the image auto-exports (USER/UID/GID/HOME) at GENERATE time; unresolved refs are a hard error. Reuses the existingTaskVarRefPattern/TaskUnresolvedRefsmachinery (R3).tasks_render.go:config:case — parent-dir auto-insertion (like write:), content substituted + staged content-addressed viaStageInlineContent, delivered by COPY (no shell); optionalvalidate: <kind>gates the rendered bytes through the existingGenerator.ValidateEgressseam (wired to the compiled-inverb:egressprovider) BEFORE staging.v0.2026250.922and, after merging origin/main (CC-3 stage walk, feat(cutover-c3): stage-grouped + concurrent bed-member walk (kit) + all-or-nothing load validation #236),go mod tidyresolved the require tov0.2026250.929(MVS against the merged main's module graph — newer than .922; it contains the SAME config-verb contract plus the spec#118 lint fix). The committed pin is.929; this body tracks the diff.How tested
The full deploykit package passes (incl. the 6 new config-verb tests, emitters, staging idempotence, and the existing write/link/download/user suites).
Rulebook compliance
Change classification
go test ./deploykit/full package green. Attribution: fully tested and validated.Assisted-by: pi openrouter/deepseek/deepseek-v4-flash-0731 (fully tested and validated)