Slice 1 of the check workers (oc-13c6bd6), part a: extend composed to the full policy model (classes, unclassified, cost, runner, mandatory versus default via CUE probing), a Go deriver with the exact path contract read losslessly, a valley-go JSON verb, and differential tests against the Bash deriver; callers unchanged. Part b moves bin/valley, approve and the integrator onto it and deletes the Bash deriver (fixing bd-11e0e4d).
Comments
contributor2026-10-21 01:51 UTC
Critique of the first slice-1 brief (Codex, 2026-10-21); part a (oc-8307a6d) took the composition and deriver items, part b (moving callers, replacing implementation-dependent tests, deleting the Bash deriver) still needs them:
A shared Go deriver would remove the integrator’s dependence on human-readable output and give future workers the same policy decision. Preserving existing behavior while adding explicit regression cases is the right migration strategy.
“Decided today in two places” is inaccurate: integrator/policy.go:142 invokes the Bash deriver; it does not independently derive requirements. Fix the rationale to describe one derivation with a fragile report-parsing boundary.
The locally available oc-13c6bd6 body contains neither the promised design nor “slice 1” or section 1. Attach the actual design or identify its exact revision; otherwise the brief’s scope reference is unusable.
composed/composed.go:172–223 currently decodes only check definitions and the restacker cap, discarding classes, unclassified requirements and costs. Compose takes materialized directories, not a tip. Explicitly require extending that model and preserving callers’ authoritative policy-source resolution.
The proposed result cannot reproduce the existing report or drive approval: mandatory/default status is missing, as are runner details. bin/valley:2976 probes CUE because exported JSON loses the distinction between concrete true and default true; approval consumes runner/attribute/command at line 1442. Specify those outputs and retain CUE-based mandatory probing.
“Tests unchanged” contradicts deleting the deriver. policy-deriver.sh:267 rewrites Bash rendering, valley-request.sh:1073 extracts diff_paths, and integrator/policy_test.go:227 injects a report-producing executable. Preserve behavioral assertions, but explicitly authorize replacing implementation-dependent tests and failure injection.
The path contract is underspecified. bin/valley:3130 reads name-status with rename detection and counts both sides; its glob language also gives ** special semantics. Specify those rules, truncated-input refusal, and lossless JSON encoding for non-UTF-8 paths; ordinary Go JSON strings cannot preserve invalid UTF-8 bytes.
The build wiring is omitted: status/go.mod and nix/packages.nix:137 do not include composed. Require module replacements, Nix source inclusion, and execution of the shared package’s own tests; importing a package does not run its tests.
The check-selection command examines commits, not uncommitted edits (bin/valley:3315). Require committing the candidate and selecting checks over explicit base/head commits, or the agent can validate an empty or stale change.
This is too large for one reliably reviewable run. The single most useful change is to split delivery: first extend composition and build the Go deriver with differential tests; then migrate CLI/approval and integrator consumers, replace obsolete tests, and delete Bash.
contributor2026-10-21 03:09 UTC
rklk v2 (2026-10-21): locale contract is byte-wise C for both derivers (bin/valley pins LC_ALL=C inside its deriver; Go matches bytes); layer discovery enumerates literal directories with Bash rules; the oracle compares every derivation global. Left for part b: integrator/policy.go openProject still decides project-layer existence with filepath.Glob, and composed.readLayer still copies dotfile .cue names out of git (documents() then drops them).