checkwright 0.21.0 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1013 -50
- package/lib/common/digest.sh +18 -0
- package/lib/common/lock.sh +40 -0
- package/lib/common/profile.sh +33 -0
- package/lib/common/recipe.sh +56 -43
- package/lib/diff.sh +64 -0
- package/lib/doctor.sh +81 -7
- package/lib/init.sh +167 -52
- package/lib/uninstall.sh +212 -0
- package/lib/update.sh +34 -0
- package/package.json +2 -2
- package/payload/artifact/targets.list +30 -0
- package/payload/artifact/x86_64-unknown-linux-gnu/checkwright-gates +0 -0
- package/payload/artifact/x86_64-unknown-linux-gnu/checkwright-gates.sha256 +1 -0
- package/payload/canon-kit/README.md +2 -0
- package/payload/canon-kit/SPEC.md +666 -59
- package/payload/canon-kit/checks/check-amendment-queue.sh +1 -0
- package/payload/canon-kit/checks/check-comment-tier.gate +3 -0
- package/payload/canon-kit/checks/check-deprecation-task.gate +3 -0
- package/payload/canon-kit/checks/check-docs-cmd.gate +3 -0
- package/payload/canon-kit/checks/check-docs-link-convention.sh +12 -4
- package/payload/canon-kit/checks/check-install-claim.gate +3 -0
- package/payload/canon-kit/checks/check-knob-citation.gate +3 -0
- package/payload/canon-kit/checks/check-knob-default-coupling.sh +1 -0
- package/payload/canon-kit/checks/check-manifest-count.gate +3 -0
- package/payload/canon-kit/checks/check-manifest-temporal.gate +3 -0
- package/payload/canon-kit/checks/check-md-refs.gate +3 -0
- package/payload/canon-kit/checks/check-measured-claim.gate +3 -0
- package/payload/canon-kit/checks/check-payload-claim.gate +3 -0
- package/payload/canon-kit/checks/check-prose-enum.gate +3 -0
- package/payload/canon-kit/checks/check-prose-tells.sh +1 -0
- package/payload/canon-kit/checks/check-spec-derivable-section.gate +3 -0
- package/payload/canon-kit/checks/check-spec-dod-singleton.gate +3 -0
- package/payload/canon-kit/checks/check-spec-embedded-source.sh +1 -0
- package/payload/canon-kit/checks/check-spec-fence-balance.gate +3 -0
- package/payload/canon-kit/checks/check-spec-pointer.gate +3 -0
- package/payload/canon-kit/checks/check-surface-duplication.sh +1 -0
- package/payload/canon-kit/checks/check-todo-task-liveness.gate +3 -0
- package/payload/canon-kit/checks/check-tracking-claim.gate +3 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/bad/.workflow/fixture-state.txt +4 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/bad/bad.gate +4 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/bad/bad.rs +5 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/bad/expect.txt +4 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/bad/templates/bad-tmpl.sh +4 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/good/.workflow/fixture-state.txt +3 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/good/expect.txt +1 -1
- package/payload/canon-kit/gate-tests/check-comment-tier/good/good.gate +4 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/good/good.rs +5 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/good/good.sh +3 -0
- package/payload/canon-kit/gate-tests/check-comment-tier/good/templates/good-tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-comment-tier.test.sh +29 -5
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/.workflow/fixture-state.txt +3 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/bad.gate +2 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/bad.rs +4 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/expect.txt +3 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/scripts/canon-config.sh +6 -5
- package/payload/canon-kit/gate-tests/check-deprecation-task/bad/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/.workflow/fixture-state.txt +3 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/expect.txt +1 -1
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/good.gate +2 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/good.rs +4 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/scripts/canon-config.sh +6 -5
- package/payload/canon-kit/gate-tests/check-deprecation-task/good/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-deprecation-task.test.sh +4 -3
- package/payload/canon-kit/gate-tests/check-docs-link-convention/bad/OUTSIDE.md +4 -0
- package/payload/canon-kit/gate-tests/check-docs-link-convention/bad/docs/index.md +3 -0
- package/payload/canon-kit/gate-tests/check-docs-link-convention/good/OUTSIDE.md +4 -0
- package/payload/canon-kit/gate-tests/check-docs-link-convention/good/docs/methodology.md +8 -0
- package/payload/canon-kit/gate-tests/check-docs-link-convention.test.sh +94 -0
- package/payload/canon-kit/gate-tests/check-knob-citation.test.sh +2 -2
- package/payload/canon-kit/gate-tests/check-manifest-count/good/SPEC.md +4 -0
- package/payload/canon-kit/gate-tests/check-manifest-count.test.sh +32 -8
- package/payload/canon-kit/gate-tests/check-md-refs.test.sh +61 -9
- package/payload/canon-kit/gate-tests/check-measured-claim/bad/SPEC.md +12 -0
- package/payload/canon-kit/gate-tests/check-measured-claim/bad/expect.txt +3 -0
- package/payload/canon-kit/gate-tests/check-measured-claim/bad/scripts/canon-config.sh +6 -0
- package/payload/canon-kit/gate-tests/check-measured-claim/good/SPEC.md +23 -0
- package/payload/canon-kit/gate-tests/check-measured-claim/good/expect.txt +1 -0
- package/payload/canon-kit/gate-tests/check-measured-claim/good/scripts/canon-config.sh +6 -0
- package/payload/canon-kit/gate-tests/check-measured-claim.test.sh +90 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/README.md +15 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/expect.txt +2 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/install.md +19 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/posts/note.md +6 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/scripts/canon-config.sh +8 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/bad/scripts/payload-claims.sh +7 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/README.md +15 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/expect.txt +2 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/install.md +20 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/posts/note.md +6 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/scripts/canon-config.sh +8 -0
- package/payload/canon-kit/gate-tests/check-payload-claim/good/scripts/payload-claims.sh +7 -0
- package/payload/canon-kit/gate-tests/check-prose-enum.test.sh +27 -4
- package/payload/canon-kit/gate-tests/check-spec-dod-singleton.test.sh +21 -7
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/.workflow/fixture-state.txt +2 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/bad.gate +2 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/bad.rs +4 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/expect.txt +4 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/bad/widget.sh +1 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/.workflow/fixture-state.txt +2 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/expect.txt +1 -1
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/good.gate +2 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/good.rs +4 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-spec-pointer/good/widget.sh +1 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/bad/.workflow/fixture-state.txt +3 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/bad/bad.gate +2 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/bad/bad.rs +4 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/bad/expect.txt +3 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/bad/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/good/.workflow/fixture-state.txt +3 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/good/expect.txt +1 -1
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/good/good.gate +2 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/good/good.rs +4 -0
- package/payload/canon-kit/gate-tests/check-todo-task-liveness/good/templates/tmpl.sh +5 -0
- package/payload/canon-kit/gate-tests/check-tracking-claim.test.sh +1 -2
- package/payload/canon-kit/lib/spec.sh +109 -70
- package/payload/canon-kit/smoke/install.sh +21 -1
- package/payload/canon-kit/templates/SPEC-amendment.md +9 -2
- package/payload/context-kit/README.md +4 -1
- package/payload/context-kit/SPEC.md +166 -9
- package/payload/context-kit/bin/env-probe.sh +19 -6
- package/payload/context-kit/checks/check-brevity.sh +1 -0
- package/payload/context-kit/checks/check-footprint-fresh.sh +1 -0
- package/payload/context-kit/checks/check-memory-off.sh +1 -0
- package/payload/context-kit/checks/check-settings-paths.sh +94 -0
- package/payload/context-kit/checks/check-settings-pins.sh +1 -0
- package/payload/context-kit/gate-tests/check-settings-paths/bad/args +1 -0
- package/payload/context-kit/gate-tests/check-settings-paths/bad/expect.txt +3 -0
- package/payload/context-kit/gate-tests/check-settings-paths/bad/settings.json +12 -0
- package/payload/context-kit/gate-tests/check-settings-paths/bad/tools/real-tool.sh +4 -0
- package/payload/context-kit/gate-tests/check-settings-paths/good/args +1 -0
- package/payload/context-kit/gate-tests/check-settings-paths/good/expect.txt +1 -0
- package/payload/context-kit/gate-tests/check-settings-paths/good/settings.json +16 -0
- package/payload/context-kit/gate-tests/check-settings-paths/good/tools/real-tool.sh +4 -0
- package/payload/context-kit/index-tests/expected/toolfloor.txt +9 -0
- package/payload/context-kit/index-tests/toolfloor-cases.sh +20 -0
- package/payload/context-kit/lib/toolfloor.sh +15 -4
- package/payload/context-kit/smoke/agents-md.sh +12 -1
- package/payload/context-kit/smoke/install.sh +4 -1
- package/payload/delegation-kit/README.md +3 -3
- package/payload/delegation-kit/SPEC.md +499 -26
- package/payload/delegation-kit/bin/run-dispatch-guard-tests.sh +97 -0
- package/payload/delegation-kit/checks/check-agent-tier-explicit.sh +1 -0
- package/payload/delegation-kit/checks/check-gate-tamper.sh +2 -1
- package/payload/delegation-kit/checks/check-rule-citation.sh +1 -0
- package/payload/delegation-kit/lib/delegation.sh +1 -0
- package/payload/delegation-kit/smoke/install.sh +2 -1
- package/payload/delegation-kit/templates/agent-dispatch-guard.sh +61 -0
- package/payload/delegation-kit/templates/agent-execution.md +127 -12
- package/payload/delegation-kit/templates/delegation-config.sh +4 -0
- package/payload/delegation-kit/templates/dispatch-checklists.md +1 -1
- package/payload/delegation-kit/templates/statusline-usage.sh +23 -1
- package/payload/delegation-kit/usage-tests/dispatch-guard-cases.tsv +30 -0
- package/payload/doctrine-kit/DOCTRINE.md +112 -11
- package/payload/doctrine-kit/README.md +12 -3
- package/payload/doctrine-kit/SPEC.md +163 -11
- package/payload/doctrine-kit/bin/install-doctrine.sh +167 -17
- package/payload/doctrine-kit/checks/check-doctrine-registration.sh +41 -11
- package/payload/doctrine-kit/gate-tests/check-doctrine-registration/bad/DOCTRINE.md +3 -0
- package/payload/doctrine-kit/gate-tests/check-doctrine-registration/good/DOCTRINE.md +3 -0
- package/payload/doctrine-kit/gate-tests/check-doctrine-registration.test.sh +82 -2
- package/payload/doctrine-kit/smoke/install.sh +167 -1
- package/payload/drift-kit/README.md +3 -2
- package/payload/drift-kit/SPEC.md +264 -22
- package/payload/drift-kit/bin/kfric.sh +21 -2
- package/payload/drift-kit/bin/stage-economics.sh +157 -3
- package/payload/drift-kit/kpis/kpi-incident-recurrence.sh +42 -0
- package/payload/drift-kit/smoke/install.sh +183 -1
- package/payload/drift-kit/templates/economics.md +9 -0
- package/payload/drift-kit/templates/kpis.list +6 -1
- package/payload/evidence-kit/README.md +20 -6
- package/payload/evidence-kit/SPEC.md +355 -17
- package/payload/evidence-kit/bin/run-validate.sh +51 -9
- package/payload/evidence-kit/checks/check-battery-roster.sh +87 -0
- package/payload/evidence-kit/checks/check-evidence-baseline.sh +1 -0
- package/payload/evidence-kit/checks/check-evidence-manifest.sh +1 -0
- package/payload/evidence-kit/checks/check-producer-liveness.sh +35 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/bad/args +1 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/bad/expect.txt +1 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/bad/runner.md +14 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/bad/scripts/evidence-config.sh +7 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/good/args +1 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/good/expect.txt +1 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/good/runner.md +14 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster/good/scripts/evidence-config.sh +7 -0
- package/payload/evidence-kit/gate-tests/check-battery-roster.test.sh +68 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/bad/args +1 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/bad/expect.txt +1 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/bad/run-validate.lock +1 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/good/args +1 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/good/expect.txt +2 -0
- package/payload/evidence-kit/gate-tests/check-producer-liveness/good/run-validate.lock +1 -0
- package/payload/evidence-kit/gate-tests/producer-lock.test.sh +109 -0
- package/payload/evidence-kit/lib/evidence.sh +18 -0
- package/payload/evidence-kit/smoke/install.sh +17 -3
- package/payload/gate-sdk/README.md +17 -1
- package/payload/gate-sdk/SPEC.md +4427 -92
- package/payload/gate-sdk/bin/build-native.sh +38 -0
- package/payload/gate-sdk/bin/enforcement-map.sh +2 -1
- package/payload/gate-sdk/bin/gen-pre-commit.sh +32 -2
- package/payload/gate-sdk/bin/port-blockers.sh +445 -0
- package/payload/gate-sdk/bin/run-consumer-smoke.sh +129 -2
- package/payload/gate-sdk/bin/run-gate-tests.sh +61 -9
- package/payload/gate-sdk/bin/run-gates.sh +37 -2
- package/payload/gate-sdk/bin/upgrade-smoke.sh +55 -7
- package/payload/gate-sdk/checks/check-action-gh-repo.gate +3 -0
- package/payload/gate-sdk/checks/check-action-pinning.gate +3 -0
- package/payload/gate-sdk/checks/check-action-run-shell.sh +4 -1
- package/payload/gate-sdk/checks/check-assertion-strength.gate +3 -0
- package/payload/gate-sdk/checks/check-commit-msg.sh +1 -0
- package/payload/gate-sdk/checks/check-commit-subject.sh +1 -0
- package/payload/gate-sdk/checks/check-core-files.sh +28 -4
- package/payload/gate-sdk/checks/check-crate-arms.sh +61 -0
- package/payload/gate-sdk/checks/check-enforcement-fresh.sh +1 -0
- package/payload/gate-sdk/checks/check-exec-bit.sh +21 -1
- package/payload/gate-sdk/checks/check-gate-assertions.sh +31 -6
- package/payload/gate-sdk/checks/check-gate-binary-fresh.sh +107 -0
- package/payload/gate-sdk/checks/check-gate-exemption-tasks.sh +7 -7
- package/payload/gate-sdk/checks/check-gate-fail-closed.sh +1 -0
- package/payload/gate-sdk/checks/check-gate-fixture-coverage.sh +1 -0
- package/payload/gate-sdk/checks/check-gate-output.sh +41 -3
- package/payload/gate-sdk/checks/check-gate-substrate-parity.sh +333 -0
- package/payload/gate-sdk/checks/check-graph.sh +5 -5
- package/payload/gate-sdk/checks/check-hook-exec-bit.sh +1 -0
- package/payload/gate-sdk/checks/check-identity.sh +1 -0
- package/payload/gate-sdk/checks/check-install-disposition.sh +92 -0
- package/payload/gate-sdk/checks/check-kit-enum.sh +1 -0
- package/payload/gate-sdk/checks/check-kit-registration.gate +3 -0
- package/payload/gate-sdk/checks/check-readme-roster.sh +6 -0
- package/payload/gate-sdk/checks/check-reads-couples.sh +71 -21
- package/payload/gate-sdk/checks/check-root-tiering.sh +1 -0
- package/payload/gate-sdk/checks/check-shellcheck.sh +1 -0
- package/payload/gate-sdk/checks/check-smoke-entry-guard.gate +3 -0
- package/payload/gate-sdk/checks/check-template-copy-parity.sh +1 -0
- package/payload/gate-sdk/checks/check-template-registry-parity.gate +3 -0
- package/payload/gate-sdk/checks/check-test-hermetic.gate +3 -0
- package/payload/gate-sdk/checks/check-tree-terms.sh +1 -0
- package/payload/gate-sdk/checks/check-workflow-tiering.sh +2 -1
- package/payload/gate-sdk/gate-tests/check-action-run-shell.test.sh +16 -1
- package/payload/gate-sdk/gate-tests/check-core-files.test.sh +64 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/bad/crate/Cargo.toml +7 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/bad/crate/src/lib.rs +12 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/bad/expect.txt +5 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/bad/scripts/gate-sdk-config.sh +2 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/good/crate/Cargo.toml +7 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/good/crate/src/lib.rs +11 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/good/expect.txt +2 -0
- package/payload/gate-sdk/gate-tests/check-crate-arms/good/scripts/gate-sdk-config.sh +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-assertions/good/expect.txt +1 -1
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/args +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/expect.txt +5 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/kitroot/checks/check-vendored.gate +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/scripts/check-ported.gate +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/scripts/gate-sdk-config.sh +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/scripts/gates.list +4 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/stamp.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/bad/stub-bin +6 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/args +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/expect.txt +5 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/kitroot/checks/check-vendored.gate +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/scripts/check-ported.gate +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/scripts/gate-sdk-config.sh +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/scripts/gates.list +4 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/stamp.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh/good/stub-bin +5 -0
- package/payload/gate-sdk/gate-tests/check-gate-binary-fresh.test.sh +81 -0
- package/payload/gate-sdk/gate-tests/check-gate-exemption-tasks/bad/TASK-QUEUE.md +3 -1
- package/payload/gate-sdk/gate-tests/check-gate-exemption-tasks/bad/expect.txt +3 -1
- package/payload/gate-sdk/gate-tests/check-gate-exemption-tasks/bad/gates/check-sample.sh +3 -1
- package/payload/gate-sdk/gate-tests/check-gate-exemption-tasks/good/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/check-native-sample.gate +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/check-sample.sh +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/expect.txt +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/gates.list +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/native/Cargo.toml +4 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/bad/native/src/gates/native_sample.rs +7 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/check-native-sample.gate +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/check-sample.sh +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/gates.list +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/native/Cargo.toml +4 -0
- package/payload/gate-sdk/gate-tests/check-gate-output/good/native/src/gates/native_sample.rs +11 -0
- package/payload/gate-sdk/gate-tests/check-gate-output.test.sh +111 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/args +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/conservation.md +7 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/expect.txt +12 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/impl/gate.rs +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/kitroot/check-orphan.rs +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/publish.yml +15 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/check-alpha.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/check-dup.gate +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/check-dup.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/check-orphan.gate +1 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/gate-sdk-config.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/scripts/gates.list +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/stub-bin +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/bad/targets.list +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/args +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/conservation.md +8 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/expect.txt +7 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/impl/gate.rs +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/kitroot/check-other.rs +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/publish.yml +15 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/scripts/check-alpha.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/scripts/check-ported.gate +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/scripts/gate-sdk-config.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/scripts/gates.list +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/stub-bin +3 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity/good/targets.list +2 -0
- package/payload/gate-sdk/gate-tests/check-gate-substrate-parity.test.sh +184 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/alpha-kit/checks/check-alpha.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/alpha-kit/checks/check-delta.sh +5 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/alpha-kit/checks/check-epsilon.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/alpha-kit/smoke/install.sh +7 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/args +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/installer/lib/common/recipe.sh +9 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/bad/scripts/gate-sdk-config.sh +5 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/alpha-kit/checks/check-alpha.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/alpha-kit/checks/check-beta.gate +3 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/alpha-kit/checks/check-gamma.sh +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/alpha-kit/smoke/install.sh +8 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/args +6 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/installer/lib/common/recipe.sh +10 -0
- package/payload/gate-sdk/gate-tests/check-install-disposition/good/scripts/gate-sdk-config.sh +5 -0
- package/payload/gate-sdk/gate-tests/check-kit-registration.test.sh +6 -5
- package/payload/gate-sdk/gate-tests/check-reads-couples.test.sh +139 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/alpha-kit/templates/widgets.list +4 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/alpha-kit/widgets/widget-one.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/alpha-kit/widgets/widget-two.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/args +4 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/bad/scripts/gate-sdk-config.sh +5 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/alpha-kit/templates/widgets.list +4 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/alpha-kit/widgets/widget-one.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/alpha-kit/widgets/widget-two.sh +3 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/args +8 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/beta-kit/templates/rules.list +5 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/beta-kit/templates/table.tsv +4 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/expect.txt +1 -0
- package/payload/gate-sdk/gate-tests/check-template-registry-parity/good/scripts/gate-sdk-config.sh +5 -0
- package/payload/gate-sdk/gate-tests/check-test-hermetic-smoke.test.sh +2 -3
- package/payload/gate-sdk/gate-tests/lib-declaration.test.sh +4 -4
- package/payload/gate-sdk/gate-tests/lib-gate.test.sh +151 -1
- package/payload/gate-sdk/gate-tests/run-dispatch-streams.test.sh +73 -0
- package/payload/gate-sdk/gate-tests/run-gate-tests.test.sh +144 -0
- package/payload/gate-sdk/lib/consumer-smoke.sh +41 -4
- package/payload/gate-sdk/lib/gate.sh +208 -9
- package/payload/gate-sdk/lib/inject.sh +46 -1
- package/payload/gate-sdk/lib/test-hermetic.sh +26 -0
- package/payload/gate-sdk/smoke/install.sh +61 -1
- package/payload/guard-kit/README.md +18 -14
- package/payload/guard-kit/SPEC.md +366 -72
- package/payload/guard-kit/bin/compare-settings-allow.sh +40 -7
- package/payload/guard-kit/bin/run-guard-tests.sh +1 -0
- package/payload/guard-kit/gate-tests/compare-settings-allow.test.sh +64 -0
- package/payload/guard-kit/gate-tests/guard-read-path.test.sh +52 -0
- package/payload/guard-kit/guard-tests/cases.tsv +49 -7
- package/payload/guard-kit/lib/guard.sh +277 -54
- package/payload/guard-kit/templates/close-triage.md +38 -10
- package/payload/guard-kit/templates/guard-config.sh +3 -0
- package/payload/guard-kit/templates/settings-hooks.json +7 -1
- package/payload/lifecycle-kit/README.md +12 -1
- package/payload/lifecycle-kit/SPEC.md +991 -41
- package/payload/lifecycle-kit/bin/cite-survey.sh +81 -0
- package/payload/lifecycle-kit/bin/enter-stage.sh +139 -13
- package/payload/lifecycle-kit/bin/file-gap.sh +60 -2
- package/payload/lifecycle-kit/bin/file-survey.sh +69 -0
- package/payload/lifecycle-kit/checks/check-close-surfaces.sh +1 -0
- package/payload/lifecycle-kit/checks/check-gap-inbox-neutrality.gate +3 -0
- package/payload/lifecycle-kit/checks/check-lesson-disposition.gate +3 -0
- package/payload/lifecycle-kit/checks/check-lifecycle-registration.gate +3 -0
- package/payload/lifecycle-kit/checks/check-merge-attrs.gate +3 -0
- package/payload/lifecycle-kit/checks/check-scratch-citation.gate +3 -0
- package/payload/lifecycle-kit/checks/check-shim-restatement.gate +3 -0
- package/payload/lifecycle-kit/checks/check-skill-binding.gate +3 -0
- package/payload/lifecycle-kit/checks/check-stage-entry.sh +1 -0
- package/payload/lifecycle-kit/checks/check-stage-evidence.gate +3 -0
- package/payload/lifecycle-kit/checks/check-stage-skill-coverage.gate +3 -0
- package/payload/lifecycle-kit/checks/check-survey-record.gate +3 -0
- package/payload/lifecycle-kit/gate-tests/check-close-surfaces.test.sh +1 -2
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/bad/args +2 -0
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/bad/expect.txt +3 -0
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/bad/gap-inbox.md +5 -0
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/good/args +2 -0
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/good/expect.txt +1 -0
- package/payload/lifecycle-kit/gate-tests/check-gap-inbox-neutrality/good/gap-inbox.md +4 -0
- package/payload/lifecycle-kit/gate-tests/check-lesson-disposition.test.sh +2 -3
- package/payload/lifecycle-kit/gate-tests/check-lifecycle-registration.test.sh +2 -3
- package/payload/lifecycle-kit/gate-tests/check-merge-attrs/bad/.gitattributes +1 -0
- package/payload/lifecycle-kit/gate-tests/check-merge-attrs/good/.gitattributes +1 -0
- package/payload/lifecycle-kit/gate-tests/check-merge-attrs.test.sh +3 -3
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/bad/expect.txt +1 -0
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/bad/scripts/lifecycle-config.sh +4 -0
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/bad/surfaces/queue.md +13 -0
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/good/expect.txt +1 -0
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/good/scripts/lifecycle-config.sh +4 -0
- package/payload/lifecycle-kit/gate-tests/check-scratch-citation/good/surfaces/queue.md +31 -0
- package/payload/lifecycle-kit/gate-tests/check-shim-restatement.test.sh +2 -3
- package/payload/lifecycle-kit/gate-tests/check-skill-binding.test.sh +2 -3
- package/payload/lifecycle-kit/gate-tests/check-stage-entry.test.sh +2 -3
- package/payload/lifecycle-kit/gate-tests/check-stage-evidence.test.sh +9 -5
- package/payload/lifecycle-kit/gate-tests/check-survey-record/bad/args +2 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record/bad/expect.txt +4 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record/bad/record.md +18 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record/good/args +2 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record/good/expect.txt +1 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record/good/record.md +13 -0
- package/payload/lifecycle-kit/gate-tests/check-survey-record.test.sh +83 -0
- package/payload/lifecycle-kit/gate-tests/file-gap-recurrence.test.sh +122 -0
- package/payload/lifecycle-kit/gate-tests/rename-iteration.test.sh +142 -0
- package/payload/lifecycle-kit/gate-tests/survey-record-entry.test.sh +102 -0
- package/payload/lifecycle-kit/gate-tests/workflow-state-guard.test.sh +100 -0
- package/payload/lifecycle-kit/lib/stages.sh +12 -2
- package/payload/lifecycle-kit/smoke/install.sh +83 -4
- package/payload/lifecycle-kit/templates/consult.md +73 -0
- package/payload/lifecycle-kit/templates/lead.md +139 -7
- package/payload/lifecycle-kit/templates/stages/align.md +12 -0
- package/payload/lifecycle-kit/templates/stages/build.md +8 -0
- package/payload/lifecycle-kit/templates/stages/close.md +45 -5
- package/payload/lifecycle-kit/templates/stages/scope.md +42 -3
- package/payload/lifecycle-kit/templates/stages/spec.md +13 -1
- package/payload/lifecycle-kit/templates/stages/validate.md +8 -0
- package/payload/lifecycle-kit/templates/workflow-state-guard.sh +29 -0
- package/payload/queue-kit/README.md +6 -1
- package/payload/queue-kit/SPEC.md +350 -6
- package/payload/queue-kit/bin/queue-counts.sh +35 -0
- package/payload/queue-kit/bin/queue-edges.sh +78 -0
- package/payload/queue-kit/checks/check-queue-entry-budget.gate +3 -0
- package/payload/queue-kit/checks/check-queue-hygiene.gate +3 -0
- package/payload/queue-kit/checks/check-queue-prose-precondition.sh +1 -0
- package/payload/queue-kit/checks/check-queue-sections.gate +3 -0
- package/payload/queue-kit/checks/check-queue-slug-liveness.gate +3 -0
- package/payload/queue-kit/checks/check-queue-wrap.gate +3 -0
- package/payload/queue-kit/checks/check-roadmap-fresh.sh +1 -0
- package/payload/queue-kit/checks/check-tag-lead-line.gate +3 -0
- package/payload/queue-kit/checks/check-task-conservation.gate +4 -0
- package/payload/queue-kit/checks/check-task-names.gate +3 -0
- package/payload/queue-kit/gate-tests/check-queue-hygiene/good/TASK-QUEUE.md +5 -0
- package/payload/queue-kit/gate-tests/queue-counts.test.sh +116 -0
- package/payload/queue-kit/gate-tests/queue-edges.test.sh +130 -0
- package/payload/queue-kit/gate-tests/queue-lib-parity.test.sh +215 -0
- package/payload/queue-kit/lib/queue.sh +4 -19
- package/payload/queue-kit/smoke/install.sh +4 -1
- package/payload/queue-kit/templates/TASK-QUEUE.md +3 -0
- package/payload/site-kit/SPEC.md +64 -27
- package/payload/site-kit/checks/check-docs-cname-parity.sh +1 -0
- package/payload/site-kit/checks/check-docs-render-fidelity.sh +1 -0
- package/payload/site-kit/smoke/install.sh +9 -1
- package/profiles.list +36 -8
- package/payload/canon-kit/checks/check-comment-tier.sh +0 -211
- package/payload/canon-kit/checks/check-deprecation-task.sh +0 -90
- package/payload/canon-kit/checks/check-docs-cmd.sh +0 -153
- package/payload/canon-kit/checks/check-install-claim.sh +0 -146
- package/payload/canon-kit/checks/check-knob-citation.sh +0 -117
- package/payload/canon-kit/checks/check-manifest-count.sh +0 -46
- package/payload/canon-kit/checks/check-manifest-temporal.sh +0 -83
- package/payload/canon-kit/checks/check-md-refs.sh +0 -128
- package/payload/canon-kit/checks/check-prose-enum.sh +0 -115
- package/payload/canon-kit/checks/check-spec-derivable-section.sh +0 -69
- package/payload/canon-kit/checks/check-spec-dod-singleton.sh +0 -45
- package/payload/canon-kit/checks/check-spec-fence-balance.sh +0 -42
- package/payload/canon-kit/checks/check-spec-pointer.sh +0 -180
- package/payload/canon-kit/checks/check-todo-task-liveness.sh +0 -80
- package/payload/canon-kit/checks/check-tracking-claim.sh +0 -136
- package/payload/gate-sdk/checks/check-action-gh-repo.sh +0 -321
- package/payload/gate-sdk/checks/check-action-pinning.sh +0 -55
- package/payload/gate-sdk/checks/check-assertion-strength.sh +0 -134
- package/payload/gate-sdk/checks/check-kit-registration.sh +0 -68
- package/payload/gate-sdk/checks/check-smoke-entry-guard.sh +0 -53
- package/payload/gate-sdk/checks/check-test-hermetic.sh +0 -119
- package/payload/lifecycle-kit/checks/check-lesson-disposition.sh +0 -98
- package/payload/lifecycle-kit/checks/check-lifecycle-registration.sh +0 -54
- package/payload/lifecycle-kit/checks/check-merge-attrs.sh +0 -69
- package/payload/lifecycle-kit/checks/check-shim-restatement.sh +0 -97
- package/payload/lifecycle-kit/checks/check-skill-binding.sh +0 -59
- package/payload/lifecycle-kit/checks/check-stage-evidence.sh +0 -81
- package/payload/lifecycle-kit/checks/check-stage-skill-coverage.sh +0 -47
- package/payload/queue-kit/checks/check-queue-entry-budget.sh +0 -104
- package/payload/queue-kit/checks/check-queue-hygiene.sh +0 -81
- package/payload/queue-kit/checks/check-queue-sections.sh +0 -44
- package/payload/queue-kit/checks/check-queue-slug-liveness.sh +0 -63
- package/payload/queue-kit/checks/check-queue-wrap.sh +0 -56
- package/payload/queue-kit/checks/check-tag-lead-line.sh +0 -70
- package/payload/queue-kit/checks/check-task-conservation.sh +0 -50
- package/payload/queue-kit/checks/check-task-names.sh +0 -128
|
@@ -156,6 +156,48 @@ nothing the tracked surfaces do not already hold. The lead is a boundary skill,
|
|
|
156
156
|
not a stage — it stamps nothing and joins no stage set, so the coverage gate
|
|
157
157
|
never reads it (the release-sweep precedent, §templates/lead.md).
|
|
158
158
|
|
|
159
|
+
**Honest limit on the lead's dispatch precondition.** A lead dispatches stage
|
|
160
|
+
N+1 on stage N's **agent completion notification**, never on an artifact — not
|
|
161
|
+
its commit, its stamp, a clean tree, a green battery, or a cleared `--simulate`
|
|
162
|
+
(§templates/lead.md). That precondition is **prose-only and human-enforced**, and
|
|
163
|
+
the cause is structural rather than budgetary. The signal's **producer is the
|
|
164
|
+
harness**, emitting it when the dispatched session's turn ends — outside every
|
|
165
|
+
governed tree, which is not a gap to close but the direct reason no gate can read
|
|
166
|
+
it; its enabling configuration is the dispatch itself, since the lead dispatches
|
|
167
|
+
in the background with notification (delegation-kit/SPEC.md §The delegation
|
|
168
|
+
model), so the producer is reachable on the ordinary path. Its **consumer is the
|
|
169
|
+
lead**, at the dispatch transition for stage N+1, by the lead's own in-turn wait
|
|
170
|
+
rather than a read. Its **truthfulness** is not the harness's to guarantee: a
|
|
171
|
+
dispatched session that ends its turn on still-running work emits a notification
|
|
172
|
+
that lies, which is what delegation-kit/SPEC.md §Operative residency exists to
|
|
173
|
+
prevent. The limit is recorded here rather than left to be inferred from the
|
|
174
|
+
absence of a gate, because an unstated version reads as an oversight for a later
|
|
175
|
+
session to fix by building the impossible gate. Naming it is also what routes the
|
|
176
|
+
enforcement duty to where it *can* be discharged: the **negative is** assertable
|
|
177
|
+
from the artifact side. A producer-liveness gate wired into
|
|
178
|
+
`LIFECYCLE_KIT_ENTRY_PREFLIGHT` (evidence-kit/SPEC.md §check-producer-liveness)
|
|
179
|
+
answers *is the producer still running?* independently of the signal, which is
|
|
180
|
+
what covers the case where the signal itself is wrong. Precedent for a
|
|
181
|
+
prose-only rule in the same template: the no-sibling-dispatch clause, prose for
|
|
182
|
+
the same reason.
|
|
183
|
+
|
|
184
|
+
**Honest limit on the lead's post-dispatch check routing.** The rule that the
|
|
185
|
+
lead's verify of the evidence-producing stage is a **read** of the committed
|
|
186
|
+
evidence rather than a re-run of the producer (§templates/lead.md, applying
|
|
187
|
+
delegation-kit/SPEC.md §Verify after every agent commit) is likewise
|
|
188
|
+
**prose-only and human-enforced**, and for the generic reason that section
|
|
189
|
+
states: the subject is a lead's *choice of command*, which leaves no tracked
|
|
190
|
+
artifact any check could read. The nearest artifact-side proxy is
|
|
191
|
+
`check-producer-liveness` on the entry-preflight hook (evidence-kit/SPEC.md
|
|
192
|
+
§check-producer-liveness), and its coverage boundary must be stated precisely or
|
|
193
|
+
this limit reads as closed when it is not: that gate answers *is a producer
|
|
194
|
+
running now*, so it covers the **concurrent** case — a producer still live when
|
|
195
|
+
the next entry is stamped — and not a **sequential** re-run, where a lead
|
|
196
|
+
re-runs the producer after it has cleanly exited, holds no lock, and reds
|
|
197
|
+
nothing. The two limits in this section are the same shape from opposite sides
|
|
198
|
+
of one dispatch: the one above is about waiting for stage N to be *over*, this
|
|
199
|
+
one about which command is safe *once it is*.
|
|
200
|
+
|
|
159
201
|
### Deviation transitions
|
|
160
202
|
|
|
161
203
|
The stages walk `scope → align → build → validate → close` in order by
|
|
@@ -201,11 +243,38 @@ subset re-promotes at a later scope under its own iteration.
|
|
|
201
243
|
**Reopen after close** is barred as an in-place edit. Stamps are append-only
|
|
202
244
|
within an iteration and scope is the only reset, so there is no gate-legal way
|
|
203
245
|
to continue a closed iteration's evidence file — and no history rewrite is
|
|
204
|
-
sanctioned to fake one (doctrine-kit
|
|
246
|
+
sanctioned to fake one (doctrine-kit's *Re-verify volatile state before a git
|
|
247
|
+
history rewrite* territory — cited by name, since a rule number re-arms the
|
|
248
|
+
drift every later insertion causes). The sanctioned shape
|
|
205
249
|
is a successor iteration: a post-close defect files as a debt entry and the
|
|
206
250
|
follow-up iteration proceeds normally; the closed iteration's record stays
|
|
207
251
|
immutable.
|
|
208
252
|
|
|
253
|
+
**The interstitial mitigation** is the shape that fits *between* a close and the
|
|
254
|
+
next scope. A repo-local mitigation for a recurring incident may land directly in
|
|
255
|
+
that window while the incident's queue entry stays open for the kit-shaped form.
|
|
256
|
+
One cap makes it admissible: **it adds no governed name** — canon-kit's
|
|
257
|
+
feature/debt litmus read the other way (canon-kit/SPEC.md §The amendment
|
|
258
|
+
lifecycle, where a task adding any name to a governed surface is a feature and
|
|
259
|
+
needs an amendment). So an interstitial landing is admissible exactly when it is
|
|
260
|
+
debt-shaped; anything feature-shaped waits for scope. The entry stays open either
|
|
261
|
+
way, because the mitigation is repo-local and the entry's deliverable is not. Like
|
|
262
|
+
every shape here it introduces no tooling, state, stamp grammar or tag — the cap
|
|
263
|
+
is an existing litmus and the landing is an ordinary commit. It **widens Reopen
|
|
264
|
+
after close** rather than competing with it: routing a post-close defect to a debt
|
|
265
|
+
entry and a normal follow-up iteration is the right answer for a first occurrence
|
|
266
|
+
and the wrong one for the fourth, and the fourth is now countable
|
|
267
|
+
(queue-kit/SPEC.md §The tag algebra, the `recurrence:` declaration). The commit
|
|
268
|
+
accounting already holds and needs no change — an interstitial commit falls into
|
|
269
|
+
the *next* iteration's range and surfaces when that iteration closes
|
|
270
|
+
(drift-kit/SPEC.md §The published-evidence extractor).
|
|
271
|
+
|
|
272
|
+
**A parallel hotfix track is refused**, recorded here so it is not re-proposed: it
|
|
273
|
+
violates scope-gated intake, it contends on live stage surfaces, and most incident
|
|
274
|
+
fixes are feature-shaped — so a "hotfix" of them is an unreviewed iteration. The
|
|
275
|
+
lane this shape governs already half-existed; what was missing was the signal that
|
|
276
|
+
says when to use it.
|
|
277
|
+
|
|
209
278
|
**The close-merge** is the concurrent-close shape, and like the others it
|
|
210
279
|
composes existing mechanism (the merge-supersede rule of §Multi-operator
|
|
211
280
|
semantics, not new tooling). Iteration boundaries serialize on the integration
|
|
@@ -224,7 +293,8 @@ gates are registered in the consumer's `gates.list` by name and resolve
|
|
|
224
293
|
through gate-sdk's multi-kit path (consumer gates dir first, then each kit's
|
|
225
294
|
`checks/`). The kit's markdown templates are laid out on the stage/boundary axis
|
|
226
295
|
this SPEC classifies them by: `templates/*.md` is exactly the **boundary skills**
|
|
227
|
-
(`lead.md`, `release-sweep.md`, `upgrade.md
|
|
296
|
+
(`lead.md`, `release-sweep.md`, `upgrade.md`, `consult.md`),
|
|
297
|
+
`templates/stages/*.md` exactly
|
|
228
298
|
the stage-class templates. Stage skills adopt `templates/stages/*.md` in one of
|
|
229
299
|
two modes — copied into the consumer's agent-skill directory with each named slot
|
|
230
300
|
overwritten, or a thin binding shim that references the template (the grammar
|
|
@@ -239,13 +309,72 @@ the template carries no second copy. The loader validates the machine
|
|
|
239
309
|
non-integer n-gram width, a malformed preflight entry) and exits 2 on a
|
|
240
310
|
malformed config — a broken machine must not gate anything.
|
|
241
311
|
|
|
242
|
-
Knob-rename compat precedent
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
312
|
+
Knob-rename compat precedent. A rename carries two obligations of different
|
|
313
|
+
natures, and each answers to its own threshold.
|
|
314
|
+
|
|
315
|
+
**Declaration — owed from the first release tag, unconditionally.** A tagged
|
|
316
|
+
release is a distribution, and whoever vendored it reads the note to learn what
|
|
317
|
+
moved. From the first tag onward a rename owes a tightened-gates/release-note
|
|
247
318
|
declaration (the deprecation-lifecycle and upgrade-path rungs).
|
|
248
319
|
|
|
320
|
+
**Compat shim and deprecation window — owed from the project's declared
|
|
321
|
+
general-availability posture onward, never from a tag.** While a project's own
|
|
322
|
+
declared stability posture is pre-general-availability, a knob rename is
|
|
323
|
+
compat-free: no read-the-old-name shim, no deprecation window, no queue-bound
|
|
324
|
+
deprecation marker. The declaration is still owed, so a consumer who vendored
|
|
325
|
+
early is never surprised. They are told; they are simply not carried.
|
|
326
|
+
|
|
327
|
+
The observable is a declared posture rather than an adoption count, because the
|
|
328
|
+
obligation is normative rather than empirical. You owe a migration path because
|
|
329
|
+
you promised stability, not because you counted users. A project that has
|
|
330
|
+
promised nothing owes nothing, and owes it the instant it promises, whether or
|
|
331
|
+
not anyone has installed. "The first observed external install" reads the premise
|
|
332
|
+
most literally and is rejected: it cannot be falsified from the tree, and it
|
|
333
|
+
makes the obligation turn on a fact outside the project's control. A tag was a
|
|
334
|
+
bad proxy for that same reason rather than one that merely aged — it measures
|
|
335
|
+
distribution where the obligation tracks promise, so it would have drifted under
|
|
336
|
+
any release history, fast or slow.
|
|
337
|
+
|
|
338
|
+
**Fail-safe direction.** A project declaring no stability posture at all is
|
|
339
|
+
treated as **past** the threshold: the compat obligation applies. Silence must
|
|
340
|
+
not read as still-pre-GA, because that is the reading under which a project that
|
|
341
|
+
never got round to declaring anything grants itself a permanent exemption. The
|
|
342
|
+
window is opened by an explicit pre-GA declaration and by nothing else.
|
|
343
|
+
|
|
344
|
+
The clause is knob-scoped, and the scoping is substantive rather than accidental:
|
|
345
|
+
|
|
346
|
+
1. **The mechanism it points at is knob-shaped.** The deprecation path it invokes
|
|
347
|
+
is the queue-bound deprecation markers and the release note's `Renamed knobs`
|
|
348
|
+
section, whose `old → new` / `old → ∅` grammar is specific to config names. A
|
|
349
|
+
rule reaching gate names or file conventions would point at a mechanism that
|
|
350
|
+
does not accept them.
|
|
351
|
+
2. **No class is left without a home.** A non-knob rename — a gate name, a file
|
|
352
|
+
or directory convention — is structurally accommodated by the release note's
|
|
353
|
+
`Behavior changes` section, whose bullet lead is defined as the changed
|
|
354
|
+
surface's name (script, knob, template, or file), a definition that already
|
|
355
|
+
admits each of those classes. What the note grammar does not yet carry is a
|
|
356
|
+
sentence explicitly *routing* non-knob renames there, so this is a sound
|
|
357
|
+
structural inference rather than an established convention. The narrow scoping
|
|
358
|
+
leaves no rename without a section shaped for it, which is all this reason
|
|
359
|
+
claims.
|
|
360
|
+
3. **Widening it would restate a neighbour.** A general "any governed name" rule
|
|
361
|
+
is doctrine-tier, and that placement call belongs to doctrine rather than to a
|
|
362
|
+
kit SPEC, which would otherwise settle a doctrine question from the inside and
|
|
363
|
+
duplicate whatever lands there.
|
|
364
|
+
|
|
365
|
+
No gate reads this clause, and that is a ruling rather than an omission. The
|
|
366
|
+
predicate a gate would need is *"this commit renames a knob"*, which is not
|
|
367
|
+
decidable from a diff without a knob-identity model no kit has; an approximation
|
|
368
|
+
would fire on additions and removals alike and be valved into silence. The
|
|
369
|
+
clause's reader is the build-stage session performing the rename, which reads it
|
|
370
|
+
to decide whether it owes a shim and a deprecation marker.
|
|
371
|
+
|
|
372
|
+
A consumer points the general-availability criterion at whatever stability
|
|
373
|
+
declaration it maintains. The kit states the criterion and never the instance:
|
|
374
|
+
naming one project's channel vocabulary here would ship that project's release
|
|
375
|
+
posture as everyone's, and no knob is introduced to read the value either, since
|
|
376
|
+
the clause's reader is a human or agent rather than a gate.
|
|
377
|
+
|
|
249
378
|
- `LIFECYCLE_KIT_STAGES` — the stage roster, in order; default
|
|
250
379
|
`(scope align build validate close)`.
|
|
251
380
|
- `LIFECYCLE_KIT_PREDECESSOR` — associative map stage → the predecessor whose
|
|
@@ -309,6 +438,25 @@ declaration (the deprecation-lifecycle and upgrade-path rungs).
|
|
|
309
438
|
`${GATE_SDK_WORKFLOW_DIR:-.workflow}/gap-inbox.md`, written by `bin/file-gap.sh`,
|
|
310
439
|
its `merge=union` attribute verified by `check-merge-attrs`, drained by the
|
|
311
440
|
close skill and read for emptiness by `bin/enter-stage.sh`'s boundary refusal.
|
|
441
|
+
- `LIFECYCLE_KIT_SURVEY_RECORD_FILE` — the committed per-iteration survey record
|
|
442
|
+
(§The survey record); default
|
|
443
|
+
`${GATE_SDK_WORKFLOW_DIR:-.workflow}/survey-record.md`, written by
|
|
444
|
+
`bin/file-survey.sh`, asserted by `check-survey-record`, its headings printed
|
|
445
|
+
and its body truncated by `bin/enter-stage.sh` (a kit-owned boundary built-in,
|
|
446
|
+
so it does not ride `LIFECYCLE_KIT_BOUNDARY_TRUNCATE`), and its
|
|
447
|
+
`merge=iteration-scoped` attribute verified by `check-merge-attrs`. One knob,
|
|
448
|
+
and no second one for the grammar, the witness commands, or an opt-out — each
|
|
449
|
+
of those is contract rather than layout.
|
|
450
|
+
- `LIFECYCLE_KIT_RECURRENCE_THRESHOLD` — positive integer, default `2`; the
|
|
451
|
+
recorded re-filing count at which a **deferred** entry enters the scope stage's
|
|
452
|
+
proposed unit set regardless of the standing directive's theme (the pre-emption
|
|
453
|
+
rule, §templates/stages/). Two recorded re-filings is a third incidence of the
|
|
454
|
+
same finding. It is a stated policy with a stated purpose rather than a derived
|
|
455
|
+
number, and a knob for that reason — `QUEUE_KIT_ENTRY_LINE_CAP`'s posture. The
|
|
456
|
+
count it is read against is the date count of the entry's `recurrence:`
|
|
457
|
+
declaration (queue-kit/SPEC.md §The tag algebra owns that grammar). That rule is
|
|
458
|
+
its only reader: queue-kit owns the declaration and reads no threshold,
|
|
459
|
+
drift-kit reports the count and applies no verdict.
|
|
312
460
|
- `LIFECYCLE_KIT_CLOSE_SURFACE_GLOBS` — the consumer's `close-surface:`
|
|
313
461
|
declaration surfaces beyond the resolved kit roots (§The close-surface
|
|
314
462
|
roster); default `*/SPEC.md`. It deliberately does **not** default to
|
|
@@ -318,8 +466,17 @@ declaration (the deprecation-lifecycle and upgrade-path rungs).
|
|
|
318
466
|
declaration vocabulary is kit-owned and carries no consumer content; the roster
|
|
319
467
|
is derived, never a kit literal — a kit shipping the *names* of a consumer's
|
|
320
468
|
inbound surfaces would publish that consumer's private workflow.
|
|
469
|
+
- `LIFECYCLE_KIT_PERMANENT_SURFACE_GLOBS` — array of path globs for the surfaces
|
|
470
|
+
held to the no-retrieval-pointer rule (§check-scratch-citation); default the
|
|
471
|
+
queue file alone (`LIFECYCLE_KIT_QUEUE_FILE`). That default is the one permanent
|
|
472
|
+
surface this kit owns and where both attested firings landed, so it is
|
|
473
|
+
non-vacuous in every consumer and over-reaches in none. The roster is consumer
|
|
474
|
+
config and the forbidden targets are derived from the consumer's own truncate
|
|
475
|
+
configuration, so no kit literal names any surface a consumer happens to have.
|
|
321
476
|
- `LIFECYCLE_KIT_BOUNDARY_TRUNCATE` — extra files reset to their header at the
|
|
322
|
-
iteration boundary; default empty.
|
|
477
|
+
iteration boundary; default empty. Adding a member also widens
|
|
478
|
+
`check-scratch-citation`'s forbidden-target set, because both read
|
|
479
|
+
`lifecycle_supersede_set`.
|
|
323
480
|
- `LIFECYCLE_KIT_BOUNDARY_PRESERVE` — keep-list of scratch-dir **basenames** the
|
|
324
481
|
iteration-boundary wipe spares (§bin/enter-stage.sh); default empty, so an
|
|
325
482
|
unset-knob consumer gets a clean wipe of an already-disposable surface.
|
|
@@ -376,8 +533,12 @@ side's content is per-iteration scratch the boundary doctrine already declares
|
|
|
376
533
|
dead (git history is the permanent audit trail). The supersede set is **derived,
|
|
377
534
|
never maintained**: it is exactly what `bin/enter-stage.sh` truncates at the
|
|
378
535
|
iteration boundary — `LIFECYCLE_KIT_STATE_FILE`,
|
|
379
|
-
`LIFECYCLE_KIT_LESSON_EVIDENCE_FILE`, and
|
|
380
|
-
|
|
536
|
+
`LIFECYCLE_KIT_LESSON_EVIDENCE_FILE`, `LIFECYCLE_KIT_SURVEY_RECORD_FILE`, and
|
|
537
|
+
the `LIFECYCLE_KIT_BOUNDARY_TRUNCATE`
|
|
538
|
+
members — rendered by `lifecycle_supersede_set` (§lib/stages.sh). The survey
|
|
539
|
+
record is in the set for a reason worth stating: a carried survey describes a
|
|
540
|
+
tree state the arriving iteration never had, so taking the other side would
|
|
541
|
+
hand a stale finding a fresh-looking home (§The survey record). The queue file
|
|
381
542
|
is deliberately *not* in the set: its body (backlog sections, lessons) is shared
|
|
382
543
|
content that merges like any prose, and only its header line is iteration-scoped
|
|
383
544
|
— resolved by hand to the arriving iteration, with a wrong resolution going red
|
|
@@ -441,16 +602,94 @@ friction, and routes here.
|
|
|
441
602
|
**The surface.** `.workflow/gap-inbox.md` (knob `LIFECYCLE_KIT_GAP_INBOX_FILE`,
|
|
442
603
|
§Layout and configuration) is a committed, append-only capture buffer. Grammar:
|
|
443
604
|
a `# contract:` prose header, then one `- <YYYY-MM-DD> — <gap prose>` bullet per
|
|
444
|
-
gap
|
|
605
|
+
gap — **one shape for every filing**, with no structured slot between the date
|
|
606
|
+
and the prose. A slug named *inside* the prose takes queue-kit's existing
|
|
607
|
+
in-body citation form (queue-kit/SPEC.md §The tag algebra), single-backticked,
|
|
608
|
+
borrowed rather than re-spelled; it is a citation and never a field, which is
|
|
609
|
+
the whole distinction §check-gap-inbox-neutrality holds. Committed, not gitignored — a
|
|
610
|
+
per-clone buffer fragments the backlog across
|
|
445
611
|
operators, the finding that rules the gitignored friction log out as the channel.
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
612
|
+
What *append-only* means on this surface is a merge property, and
|
|
613
|
+
§Multi-operator semantics owns it: this is the kit's one `union`-driver surface.
|
|
614
|
+
|
|
615
|
+
**The affordance.** `bin/file-gap.sh [--] "<gap prose>"` (the `bin/kfric.sh`
|
|
616
|
+
pattern: repo-root cd, config-via-env, exit 2 on an empty argument) appends one
|
|
617
|
+
dated bullet, seeding the contract header when the inbox does not yet exist. Its
|
|
618
|
+
one positional is free text, so it validates that argument's **shape** to
|
|
619
|
+
gate-sdk/SPEC.md §The bin/-tool contract — help on stdout at exit 0, an
|
|
620
|
+
unrecognized leading `-` refused, `--` ending option processing — which is the
|
|
621
|
+
rule this capture affordance's own three attested firings bought. It is
|
|
450
622
|
advisory tooling, not a gate — no fixture pair is owed; the raw append (a bullet
|
|
451
623
|
line into the inbox) stays a legal fallback, the grammar being the surface's
|
|
452
624
|
contract, not the writer.
|
|
453
625
|
|
|
626
|
+
It also **resolves the prose against the live slug set** at capture and, on a
|
|
627
|
+
match, raises a stderr advisory that **asks** the filer: the prose names live
|
|
628
|
+
entry `<slug>` — if this bullet *re-files* that finding, say so in the prose and
|
|
629
|
+
say why; if it merely cites, corrects, or argues against that entry, say it is
|
|
630
|
+
*distinct* and why, because the closing stage's drain judges the recurrence and
|
|
631
|
+
reads what was written. The resolution buys a prompt and nothing else: it writes
|
|
632
|
+
no marker, and the bullet it accompanies is the same one shape every filing gets.
|
|
633
|
+
The
|
|
634
|
+
live set is every column-0 `- **<slug>** —` entry bullet in the queue file
|
|
635
|
+
*outside* the fixed-spelling `## Lessons Learned` section — that is exactly
|
|
636
|
+
active, deferred, and a configured icebox — and it needs **no section knob of its
|
|
637
|
+
own** because both exclusions fall out of grammar the kit already reads. The done
|
|
638
|
+
section is excluded by construction: a done entry is a bare-slug line, outside the
|
|
639
|
+
entry grammar queue-kit/SPEC.md §The queue format defines. Lessons is excluded by
|
|
640
|
+
name, and must be: a lesson lead line is outside that grammar for every *gate*,
|
|
641
|
+
but it may legitimately be *written* in the entry shape (`- **slug** [tag] —
|
|
642
|
+
prose`), so a grammar-only scan would resolve a live lesson as a queue entry and
|
|
643
|
+
ask the filer about something that is not one. The `## Lessons Learned`
|
|
644
|
+
literal is fixed spelling rather than config (queue-kit/SPEC.md §The tag algebra),
|
|
645
|
+
and this kit already carries it — `bin/enter-stage.sh`'s boundary refusal and
|
|
646
|
+
`check-lesson-disposition` both scan it.
|
|
647
|
+
The done exclusion is the substantive half: a finding that recurs *after* its fix
|
|
648
|
+
landed is a new defect, not a recurrence, and files as one. Resolution is
|
|
649
|
+
lifecycle-kit's own awk over the
|
|
650
|
+
queue — the shape `check-stage-entry` assertion B already takes — never
|
|
651
|
+
queue-kit's `queue_live_slugs`, because reaching for it would close a cross-kit
|
|
652
|
+
cycle. queue-kit/SPEC.md §The queue format states that as the general rule (a kit
|
|
653
|
+
that cannot depend on queue-kit re-implements the predicate and both ends cite the
|
|
654
|
+
owner section), and drift-kit's `kpi-deferred-age` records the same accepted
|
|
655
|
+
residual.
|
|
656
|
+
|
|
657
|
+
**Why the matcher prompts rather than decides, and why it survives at all.** A
|
|
658
|
+
recurrence is a claim about *what a finding is*, not about *what a string
|
|
659
|
+
contains*, and no syntactic tell separates "this recurred" from "this is about
|
|
660
|
+
that": a bullet can spell the denial out in words and still match. So the
|
|
661
|
+
predicate is not sharpened, it is **demoted** — its recall was never the defect,
|
|
662
|
+
its authority was. Deleting it would delete the only thing that can produce the
|
|
663
|
+
prompt, and the prompt is what reaches the one party who can answer cheaply: a
|
|
664
|
+
mid-build filer routinely has not read the queue, which is why the matcher
|
|
665
|
+
existed in the first place.
|
|
666
|
+
|
|
667
|
+
**Its honest limit.** A bullet describing a recurrence without spelling the slug
|
|
668
|
+
raises no advisory at all. That leaves no hole in this channel, because the drain
|
|
669
|
+
reads **every** bullet regardless of whether the matcher spoke — which is the
|
|
670
|
+
difference between a prompt and a gate, and the reason the judgment had to move
|
|
671
|
+
rather than the predicate get sharper.
|
|
672
|
+
|
|
673
|
+
**Three alternatives are refused, recorded so they are not re-drafted.** A
|
|
674
|
+
*required* recurrence-or-new argument on the affordance turns capture into an
|
|
675
|
+
interrogation, and refusing capture does not dissolve a finding — it pushes it
|
|
676
|
+
back into session context, the deferred-capture antipattern this inbox exists to
|
|
677
|
+
prevent; it is also asked of a party who has not read the queue. An *optional*
|
|
678
|
+
`--recurrence <slug>` flag invites the drain to trust a structured claim,
|
|
679
|
+
reinstating the same defect one layer up with a better provenance story. And
|
|
680
|
+
*narrowing the matcher* — anchoring the slug, exempting a bullet containing a
|
|
681
|
+
negation — institutionalizes the evasion: an affordance that must be phrased
|
|
682
|
+
around to stay accurate is miscalibrated, and the next filer does not know to
|
|
683
|
+
phrase around it. What all three trade against is prose, which the channel
|
|
684
|
+
already carries and a judge already reads.
|
|
685
|
+
|
|
686
|
+
**The tool writes no queue file, and that is the load-bearing constraint on the
|
|
687
|
+
whole channel.** This inbox exists precisely because a gap surfaced mid-stage has
|
|
688
|
+
no committed place to land except the queue file a stage session is already
|
|
689
|
+
contending on. A `file-gap.sh` that stamped a `recurrence:` declaration onto a
|
|
690
|
+
queue entry would do the one thing the inbox was built to prevent. The queue write
|
|
691
|
+
therefore belongs to the closing stage's drain, which writes the queue anyway.
|
|
692
|
+
|
|
454
693
|
It also **warns at the point of capture**, reading the cursor
|
|
455
694
|
(`lifecycle_current_stage`) to say which consequence the filer is buying: an
|
|
456
695
|
ordinary filing is told the bullet blocks the next first-stage entry until the
|
|
@@ -461,6 +700,28 @@ warning and not a refusal deliberately: refusing capture does not dissolve a
|
|
|
461
700
|
real finding, it pushes it back into session context — the deferred-capture
|
|
462
701
|
antipattern this inbox exists to prevent.
|
|
463
702
|
|
|
703
|
+
**The drain re-verifies; capture does not.** A bullet's prose is a claim made at
|
|
704
|
+
capture speed, and this channel is built to keep capture cheap, so nothing
|
|
705
|
+
upstream established it — a bullet can assert a mechanism its filer inferred
|
|
706
|
+
rather than ran, and a false premise is paid by whoever drains it. The drain
|
|
707
|
+
therefore names, per bullet, the claim its disposition turns on and the command
|
|
708
|
+
that establishes it, runs that command, and records in the same commit which
|
|
709
|
+
bullets were re-verified and what fell (§templates/stages/ carries the step). The
|
|
710
|
+
grounds are attested rather than argued: of the bullets re-verified at one
|
|
711
|
+
boundary, two were false at their central claim and each fell to a single
|
|
712
|
+
command, and a later bullet carried two false premises at once — one caught by
|
|
713
|
+
the filer re-reading the source before the drain, the other only by the draining
|
|
714
|
+
session's own probes. The step that reliably ran was the drain.
|
|
715
|
+
|
|
716
|
+
**Two capture-time shapes are refused, recorded so they are not re-drafted.** A
|
|
717
|
+
filing-time prompt for the establishing command, and a grammar separating
|
|
718
|
+
observed fact from inferred mechanism, both add friction at the moment this inbox
|
|
719
|
+
exists to keep cheap, and both bill it to the party least able to pay — the
|
|
720
|
+
mid-stage filer whose finding otherwise stays in session context. That is the
|
|
721
|
+
deferred-capture antipattern the channel was built against, and it is not traded
|
|
722
|
+
away to fix a different failure mode. The affordance gains no prompt and no
|
|
723
|
+
grammar; §check-gap-inbox-neutrality keeps the bullet's fields at two.
|
|
724
|
+
|
|
464
725
|
**Merge semantics.** The inbox carries `merge=union` (git-native, so no per-clone
|
|
465
726
|
driver registration), not the keep-ours `merge=iteration-scoped` the
|
|
466
727
|
boundary-truncated surfaces carry: an iteration-scoped surface is per-iteration
|
|
@@ -497,9 +758,285 @@ kit is vendored. Consumers: the close skill's drain step (§templates/stages/)
|
|
|
497
758
|
dispositions every bullet — promoted to a deferred `[design-pending]` entry,
|
|
498
759
|
fixed inline that session, or discarded with cause in the close commit message —
|
|
499
760
|
then truncates the inbox to its header; the boundary refusal reads emptiness at
|
|
500
|
-
the next scope entry as the backstop.
|
|
501
|
-
|
|
502
|
-
|
|
761
|
+
the next scope entry as the backstop.
|
|
762
|
+
|
|
763
|
+
**A `recurrence:` date records a session's judgment that a finding re-occurred,
|
|
764
|
+
made by reading the bullet's prose. A slug appearing in a bullet is an input to
|
|
765
|
+
that judgment and never a verdict; no mechanism produces the declaration.**
|
|
766
|
+
|
|
767
|
+
That drain step is the declaration's only **mechanized** producer
|
|
768
|
+
(queue-kit/SPEC.md §The tag algebra), and it is the stage that must not skip the
|
|
769
|
+
judgment: on a bullet it judges a recurrence it stamps the date onto that entry's
|
|
770
|
+
declaration — creating the line when absent, appending the date when present —
|
|
771
|
+
**in addition to** its ordinary disposition, never instead of it. It is reachable
|
|
772
|
+
at every close with no enabling config, since the drain is already mandatory and
|
|
773
|
+
the boundary refusal already forces it. It is *not* the only producer in fact: a
|
|
774
|
+
session that observes a recurrence outside the capture channel can stamp one
|
|
775
|
+
directly, and whether that path should be sanctioned, forbidden, or mechanized is
|
|
776
|
+
open. Stamping is **idempotent per (slug, date)** — two filings of one slug on
|
|
777
|
+
one day record one date, the day being the only resolution the bullet's own
|
|
778
|
+
grammar has, and inventing a finer one would claim precision this channel does not
|
|
779
|
+
carry.
|
|
780
|
+
|
|
781
|
+
**What the judgment rule costs, and what pays for it.** The property the rule
|
|
782
|
+
declines to offer is **re-derivability**: a date is *not* reproducible by
|
|
783
|
+
re-running any predicate over the queue, so a reader cannot audit the count
|
|
784
|
+
without trusting the session that stamped it, and claiming otherwise would be the
|
|
785
|
+
dishonest half of the trade. What
|
|
786
|
+
pays for it is **auditability by inspection** — the drain stamps the declaration
|
|
787
|
+
in the *same commit* that truncates the inbox, so the judgment and the prose it
|
|
788
|
+
was made from sit in one diff and a reader auditing a date reads that commit and
|
|
789
|
+
sees the bullet the judge read. That same-commit rule is therefore **load-bearing
|
|
790
|
+
rather than incidental**: it is the audit artifact. Re-running a matcher is
|
|
791
|
+
replaced by reading the grounds, which is the correct trade when the thing
|
|
792
|
+
recorded is a judgment.
|
|
793
|
+
|
|
794
|
+
**A provenance gate was drafted here and is refused, recorded so it is not
|
|
795
|
+
re-drafted.** Requiring every commit that adds a `recurrence:` date to co-stage
|
|
796
|
+
the inbox looks like the enforced replacement for re-derivability. It is not: a
|
|
797
|
+
back-test over this project's own history redded roughly one in three of the
|
|
798
|
+
commits that had ever stamped one, and it would foreclose the direct-stamp path
|
|
799
|
+
above by gating exactly the route that open question may want opened. A gate that
|
|
800
|
+
reds a third of the precedent it was derived from is measuring the rule, not the
|
|
801
|
+
tree.
|
|
802
|
+
|
|
803
|
+
Each bullet's two fields have named readers: the date feeds close's staleness
|
|
804
|
+
judgment and becomes the stamped recurrence date, and the prose is the
|
|
805
|
+
disposition body, the grounds the drain judges the recurrence from, the claim the
|
|
806
|
+
drain re-verifies, and — via the capture-time advisory on stderr — the field the
|
|
807
|
+
filer is asked to write the claim into. There is no third field, which is the point:
|
|
808
|
+
§check-gap-inbox-neutrality keeps it that way.
|
|
809
|
+
|
|
810
|
+
## The survey record
|
|
811
|
+
|
|
812
|
+
A stage that dispatches a survey — a census, a cohort sweep, a roster built by
|
|
813
|
+
applying a criterion set to a corpus — buys a finding that lives in the
|
|
814
|
+
dispatching session's context and dies with it. The next stage needing the same
|
|
815
|
+
roster has no artifact to read, so it dispatches the same survey again. Neither
|
|
816
|
+
session is undisciplined: each is correct in isolation, and the cost is
|
|
817
|
+
structural. This surface is where the expensive half of a survey is carried
|
|
818
|
+
across the stage boundary.
|
|
819
|
+
|
|
820
|
+
**The decomposition that makes carrying safe.** A carried finding has a
|
|
821
|
+
staleness problem a re-derivation does not: a census written at scope and read
|
|
822
|
+
at build is correct only while the tree it censused holds still, and the stages
|
|
823
|
+
between them are exactly when that tree moves. Sizing that window per *kind* of
|
|
824
|
+
survey is not makeable — it depends on what the next stage does, which the
|
|
825
|
+
author cannot know. So it is answered mechanically per record instead. A survey
|
|
826
|
+
worth carrying ran an **oracle** (the oracle-first doctrine demands it), and
|
|
827
|
+
that splits it in two: a **cheap, re-runnable half** — the oracle's verdict —
|
|
828
|
+
and an **expensive, judgment half** — the reading laid over that verdict against
|
|
829
|
+
a criterion set. The re-derivation re-buys both; this surface carries the
|
|
830
|
+
expensive half and re-runs the cheap one.
|
|
831
|
+
|
|
832
|
+
> **A carried survey is a citation with a falsifiable staleness witness, never a
|
|
833
|
+
> substitute for the oracle. The consuming stage re-runs the oracle and diffs the
|
|
834
|
+
> surveyed corpus since the recorded revision; if both hold, the recorded
|
|
835
|
+
> judgment stands and is cited rather than re-bought. If either moved, the stage
|
|
836
|
+
> dispatches only the delta.**
|
|
837
|
+
|
|
838
|
+
A survey therefore stays true exactly as long as its witness holds, and the
|
|
839
|
+
witness is checkable in two commands.
|
|
840
|
+
|
|
841
|
+
**The surface.** `.workflow/survey-record.md` (knob
|
|
842
|
+
`LIFECYCLE_KIT_SURVEY_RECORD_FILE`, §Layout and configuration) is a committed
|
|
843
|
+
per-iteration record, append-only within the iteration. Grammar: a `# contract:`
|
|
844
|
+
prose header, then one block per survey:
|
|
845
|
+
|
|
846
|
+
```
|
|
847
|
+
## <YYYY-MM-DD> <stage> — <the one-line question this survey answered>
|
|
848
|
+
- corpus: <git pathspec the survey covered>
|
|
849
|
+
- oracle: <the command whose verdict grounds it, or the literal `none`>
|
|
850
|
+
- rev: <full commit sha the survey was taken at>
|
|
851
|
+
- finding: <the judgment, in prose>
|
|
852
|
+
```
|
|
853
|
+
|
|
854
|
+
Four fields, and each earns its place by being read at a named transition —
|
|
855
|
+
`corpus` and `rev` by the diff, `oracle` by the re-run, `finding` by the
|
|
856
|
+
consuming session. The heading is the discovery key and it states the
|
|
857
|
+
*question*, because a later stage searches by the question it is about to ask,
|
|
858
|
+
not by the corpus it has not yet chosen.
|
|
859
|
+
|
|
860
|
+
**No field for "how long this stays true."** Deliberately absent: an author
|
|
861
|
+
cannot know it, and a field carrying a guess would be read as a warrant.
|
|
862
|
+
`corpus` + `rev` + `oracle` let the *reader* compute it, which is the whole
|
|
863
|
+
ruling above.
|
|
864
|
+
|
|
865
|
+
**Append-only within the iteration, never edited in place.** A survey that
|
|
866
|
+
turned out wrong is superseded by a later block answering the same question, not
|
|
867
|
+
by a correction to the old one — the record is evidence of what was believed
|
|
868
|
+
when, and rewriting it destroys the only thing that makes a stale finding
|
|
869
|
+
diagnosable after the fact.
|
|
870
|
+
|
|
871
|
+
**The witness — the re-use protocol.** A session about to buy a survey reads the
|
|
872
|
+
record first and, for any block whose heading answers its question, runs the
|
|
873
|
+
witness:
|
|
874
|
+
|
|
875
|
+
1. **Corpus still?** `git diff --quiet <rev>..HEAD -- <corpus>` — clean means no
|
|
876
|
+
commit since the survey touched anything it covered.
|
|
877
|
+
2. **Oracle still?** Re-run `<oracle>` and compare its verdict to the one the
|
|
878
|
+
finding was written against.
|
|
879
|
+
|
|
880
|
+
**The witness is four strings, and that is what makes a finding portable.** It is
|
|
881
|
+
not a property of the record file: the protocol's whole input is `corpus`,
|
|
882
|
+
`oracle`, `rev` and `finding`, each a short string, and both commands run from
|
|
883
|
+
HEAD. Copied onto another surface the witness is *more* durable than it is here,
|
|
884
|
+
because the copy is not truncated.
|
|
885
|
+
|
|
886
|
+
Both hold → **cite the record; do not re-buy the survey.** Either moved →
|
|
887
|
+
**dispatch only the delta**, the dispatch prompt naming the record block and the
|
|
888
|
+
diff, so the child re-surveys what changed rather than the corpus. The
|
|
889
|
+
asymmetry is what makes this safe to ship: a false *stale* costs one
|
|
890
|
+
re-derivation — exactly today's cost, so the mechanism's worst case is the
|
|
891
|
+
status quo — while a false *fresh* would need a change touching neither the
|
|
892
|
+
corpus nor the oracle's verdict, in which case the finding is in fact still
|
|
893
|
+
true. The mechanism can only degrade *toward* the behavior it replaces.
|
|
894
|
+
|
|
895
|
+
**The honest limit.** A survey whose grounds are *not* an oracle — a judgment
|
|
896
|
+
over prose, a reading of history — records `oracle: none`, and that block is a
|
|
897
|
+
**note, not a re-usable survey**: readable for orientation, re-derived before it
|
|
898
|
+
is relied on. Stating that costs one line per record and is the difference
|
|
899
|
+
between a mechanism and a false-assurance surface. An *empty* oracle is the
|
|
900
|
+
silent form of the same thing and is refused (§check-survey-record).
|
|
901
|
+
|
|
902
|
+
*Ruled out: a timestamp freshness window.* "Trust a survey under N hours old" is
|
|
903
|
+
the per-kind taxonomy in disguise — wrong in both directions (a one-minute-old
|
|
904
|
+
survey is stale if the tree moved; a week-old one is fine if it did not) and it
|
|
905
|
+
buys nothing the two-command witness does not. *Ruled out: auto-invalidating
|
|
906
|
+
every block on any commit* — too coarse to leave the mechanism any use; the
|
|
907
|
+
`corpus` pathspec exists precisely to make invalidation proportionate.
|
|
908
|
+
|
|
909
|
+
**The affordance.** `bin/file-survey.sh [--] "<question>" "<corpus>" "<oracle>"
|
|
910
|
+
"<finding>"` appends one block, seeding the contract header when the record does
|
|
911
|
+
not yet exist. It follows `bin/file-gap.sh` exactly: repo-root cd,
|
|
912
|
+
config-via-env, exit 2 on a missing or empty argument, and the free-text
|
|
913
|
+
argument-shape contract of gate-sdk/SPEC.md §The bin/-tool contract — whose
|
|
914
|
+
refusal here scans **every** positional, since four slots make arity no
|
|
915
|
+
protection at all. Advisory tooling, not a
|
|
916
|
+
gate — the raw append stays a legal fallback, the grammar being the surface's
|
|
917
|
+
contract rather than the writer.
|
|
918
|
+
|
|
919
|
+
It **stamps `rev` and the date itself and derives `<stage>` from the cursor**
|
|
920
|
+
(`lifecycle_current_stage`), which is the load-bearing decision in the tool:
|
|
921
|
+
`rev` is the field the entire re-use protocol turns on and exactly the field an
|
|
922
|
+
author would get wrong — a short sha, the rev they *started* at, or none.
|
|
923
|
+
Machine-stamping it is how the mechanism avoids failing silently when someone
|
|
924
|
+
forgets, which is the failure shape that rules out author-supplied conventions
|
|
925
|
+
elsewhere in this kit. A tree with no `HEAD` commit cannot ground a witness, so
|
|
926
|
+
that is a refusal (exit 2) rather than a blank field; a tree with no cursor yet
|
|
927
|
+
stamps the never-named `—` the queue header already uses.
|
|
928
|
+
|
|
929
|
+
It **deliberately does not** inherit `file-gap.sh`'s slug resolution. A survey's
|
|
930
|
+
prose routinely names queue slugs as its subject, and that resolver scans whole
|
|
931
|
+
prose, so it would stamp a recurrence declaration onto the survey's subject.
|
|
932
|
+
Adding no resolver here is a decision, not an omission.
|
|
933
|
+
|
|
934
|
+
**A permanent surface carries the finding, never a pointer into here.** A surface
|
|
935
|
+
outside the boundary-truncated set — a queue entry, a SPEC section — must not
|
|
936
|
+
promise a reader retrievable content in this record: the boundary reset below
|
|
937
|
+
empties it, so the pointer resolves to nothing one iteration after it is written,
|
|
938
|
+
and the finding survives only in the evicting commit. It inlines the finding
|
|
939
|
+
together with the block's four witness fields instead, which is what keeps the
|
|
940
|
+
finding *re-usable* rather than merely readable. Naming this record as a
|
|
941
|
+
**subject** is unaffected — "the survey record is per-iteration scratch" promises
|
|
942
|
+
nobody a retrieval — and that distinction is exactly what
|
|
943
|
+
§check-scratch-citation's red condition is calibrated against.
|
|
944
|
+
|
|
945
|
+
**Commit-pinning the citation is wrong by construction, not merely awkward**, and
|
|
946
|
+
it is the close a reader reaches for first. `bin/file-survey.sh` stamps `rev` as
|
|
947
|
+
HEAD *at filing time*, which precedes the commit that lands the block — so
|
|
948
|
+
`git show <rev>:<record>` reads a blob that does not contain the block being
|
|
949
|
+
cited, and it fails silently by printing a record without it. The sha a pin would
|
|
950
|
+
need is the *landing* commit, which no field carries and which is precisely the
|
|
951
|
+
class of value this section already rules an author gets wrong.
|
|
952
|
+
|
|
953
|
+
**The affordance that makes inlining one command.** `bin/cite-survey.sh [--]
|
|
954
|
+
"<heading-substring>"` selects the one block whose `## ` heading contains the
|
|
955
|
+
substring and writes it to stdout as an inline-ready snippet — the heading and all
|
|
956
|
+
four fields. It refuses (exit 2) on no match, on an ambiguous match, and on a
|
|
957
|
+
record with no blocks, rather than guessing: the author asked for one finding, and
|
|
958
|
+
a silently-chosen sibling would be pasted onto a permanent surface as if it were
|
|
959
|
+
the one they read. It follows `bin/file-survey.sh` exactly — repo-root cd,
|
|
960
|
+
config-via-env, exit 2 on a missing or empty argument, and — per
|
|
961
|
+
gate-sdk/SPEC.md §The bin/-tool contract — the shape contract for its one
|
|
962
|
+
free-text positional. It is advisory tooling,
|
|
963
|
+
not a gate, the same disposition its sibling carries. It is a census find rather
|
|
964
|
+
than a firing on that last point: it carries `file-gap.sh`'s exact single-argument
|
|
965
|
+
shape and has simply not been run with a flag yet, and while it writes nothing,
|
|
966
|
+
its help behavior was the same misleading error.
|
|
967
|
+
|
|
968
|
+
It deliberately does **not** rewrite the citing surface. The author chooses where
|
|
969
|
+
the finding belongs and how much of the `finding` prose to carry; a tool that
|
|
970
|
+
spliced would need a marker block, which would make a hand-written citation a
|
|
971
|
+
second-class form of the very thing this rule is trying to make ordinary.
|
|
972
|
+
|
|
973
|
+
**How this differs from the gap inbox, which it sits beside.** The two are
|
|
974
|
+
sibling committed per-iteration surfaces with deliberately *opposite* semantics
|
|
975
|
+
on both axes, and a reader who meets them apart will assume symmetry and get
|
|
976
|
+
both wrong:
|
|
977
|
+
|
|
978
|
+
- **Merge.** The gap inbox is `merge=union` — a gap filed on either side of a
|
|
979
|
+
concurrent merge must survive. The survey record is `merge=iteration-scoped`
|
|
980
|
+
(keep-ours): a survey from the other side describes a tree state this clone
|
|
981
|
+
never had, so surviving the merge is the hazard, not the save.
|
|
982
|
+
- **Boundary.** The gap inbox *refuses* the iteration boundary while it holds
|
|
983
|
+
bullets, because every gap owes a disposition. The survey record is
|
|
984
|
+
boundary-**truncated and never refuses**: a survey owes nobody a disposition,
|
|
985
|
+
being scratch whose whole lifetime was the iteration that just ended
|
|
986
|
+
(§bin/enter-stage.sh).
|
|
987
|
+
|
|
988
|
+
That per-iteration lifetime is delivered by the boundary reset rather than by a
|
|
989
|
+
judgment — which is precisely the window the design needed sized. The record
|
|
990
|
+
resets as a **kit built-in member**, not through the consumer's
|
|
991
|
+
`LIFECYCLE_KIT_BOUNDARY_TRUNCATE` array, by the same rule
|
|
992
|
+
`LIFECYCLE_KIT_LESSON_EVIDENCE_FILE` follows: a defaulted bash array is
|
|
993
|
+
*replaced* when a consumer assigns it, so shipping the record as a default
|
|
994
|
+
member would silently lose the reset in every consumer that sets the knob for
|
|
995
|
+
its own reasons.
|
|
996
|
+
|
|
997
|
+
Two homes were ruled out, each on grounds that decide it alone. **The resume
|
|
998
|
+
journal** (delegation-kit/SPEC.md §Resume journal — agent writes, scratch reset
|
|
999
|
+
sweeps) is crash recovery for the
|
|
1000
|
+
*writing* session, discoverable by its per-session name — a hand-off surface
|
|
1001
|
+
must be discoverable by content, by a session that never knew the writer's name
|
|
1002
|
+
— and it lives in untracked scratch with a second reclaimer, context-kit's
|
|
1003
|
+
session-context hook, whose age guard is shorter than an iteration
|
|
1004
|
+
(context-kit/SPEC.md §The session-context hook); a scope-stage journal can be
|
|
1005
|
+
swept before the stage that would read it ever runs, silently and
|
|
1006
|
+
time-dependently. **The gap inbox** has the right tier and the wrong semantics
|
|
1007
|
+
on both axes above: routing surveys there would make the boundary refuse on
|
|
1008
|
+
residue nobody owes a disposition for.
|
|
1009
|
+
|
|
1010
|
+
**Producers and consumers.** Producer: any session that bought a survey, via
|
|
1011
|
+
`bin/file-survey.sh` (the raw append the sanctioned fallback); the knob default
|
|
1012
|
+
makes the channel live everywhere the kit is vendored, so the deployed
|
|
1013
|
+
configuration that must be set is none. Consumer: the next stage session, at its
|
|
1014
|
+
`bin/enter-stage.sh` entry — which prints the record's headings, the questions
|
|
1015
|
+
and never the findings — and at the moment it is about to dispatch a survey,
|
|
1016
|
+
where the witness applies. Each field's reader at its transition: `corpus` and
|
|
1017
|
+
`rev` by the consuming session's `git diff` at the pre-dispatch check, `oracle`
|
|
1018
|
+
by the same session at the same transition to re-run, `finding` by that session
|
|
1019
|
+
only *after* the witness holds (which is why the entry report prints headings and
|
|
1020
|
+
not findings), the `## ` heading by `bin/enter-stage.sh` at every stage entry and
|
|
1021
|
+
by `check-survey-record` at commit time as the block delimiter. Third reader, at
|
|
1022
|
+
the iteration boundary: the first-stage truncate, which reads the surface as a
|
|
1023
|
+
whole and discards it.
|
|
1024
|
+
|
|
1025
|
+
**Nothing is produced on the delegation side.** No journal contract moves, no
|
|
1026
|
+
dispatch shape changes, no obligation lands on a dispatched child. The producer
|
|
1027
|
+
is the *parent*, which is where delegation-kit's durable-before-you-act rule
|
|
1028
|
+
already puts the write; this surface gives that existing obligation a home for
|
|
1029
|
+
one shape of finding rather than adding an obligation. It is also **not** the
|
|
1030
|
+
durable escalation artifact delegation-kit/SPEC.md §The delegation model
|
|
1031
|
+
prescribes as a child's upward route: that one is mid-run, dispatcher-minted,
|
|
1032
|
+
per-dispatch and written by the child, where this is a hand-off, single-path,
|
|
1033
|
+
per-iteration and written by the parent after the child returns. Different
|
|
1034
|
+
writer, reader, lifetime and discovery key — they must not be collapsed.
|
|
1035
|
+
|
|
1036
|
+
**Open, and shared with the gap inbox:** who commits an append filed by a
|
|
1037
|
+
session that is not the stage session. This surface inherits that question and
|
|
1038
|
+
does not answer it; the exposure is smaller, since a survey lost to an
|
|
1039
|
+
uncommitted append costs a re-derivation, which is today's cost.
|
|
503
1040
|
|
|
504
1041
|
## The close-surface roster
|
|
505
1042
|
|
|
@@ -589,6 +1126,32 @@ triage attention and were ranked against each other by nothing — and the roste
|
|
|
589
1126
|
answers it directly: both appear on one derived roster, with modes, which is what
|
|
590
1127
|
"ranked against each other" needs. Merging the files was the proxy, not the thing.
|
|
591
1128
|
|
|
1129
|
+
## Testing
|
|
1130
|
+
|
|
1131
|
+
Every gate ships the ordinary `good/`+`bad/` fixture pair, and the scenarios one
|
|
1132
|
+
pair cannot hold live in `gate-tests/*.test.sh` scenario runners. What departs
|
|
1133
|
+
from the plain fixture-pair default, and what no single gate's subsection below
|
|
1134
|
+
can own, is how those runners **reach** their gate.
|
|
1135
|
+
|
|
1136
|
+
A runner that drives a gate names that gate, never a substrate: it resolves through
|
|
1137
|
+
`gate_run <name> <checks-dir> <args>` (gate-sdk/SPEC.md §run-gate-tests), which
|
|
1138
|
+
dispatches through `gate_command` exactly as the fixture harness does. A member
|
|
1139
|
+
that ports to a compiled subcommand therefore leaves its scenario coverage
|
|
1140
|
+
running unchanged — the property a path-named runner does not have, since the
|
|
1141
|
+
`checks/<name>.sh` it holds stops existing in the motion that lands the
|
|
1142
|
+
descriptor. For a case that differs by a knob rather than by argv, `gate_env
|
|
1143
|
+
NAME=VALUE` sets that one case's environment in the caller's subshell;
|
|
1144
|
+
`check-stage-evidence`'s session-boundary posture cases are the worked instance.
|
|
1145
|
+
|
|
1146
|
+
Every gate-driving runner in this kit, including `check-close-surfaces` and
|
|
1147
|
+
`check-stage-entry` — whose gates themselves remain shell (`check-close-surfaces`
|
|
1148
|
+
unsized by any cohort, `check-stage-entry` held on shell — gate-sdk/SPEC.md
|
|
1149
|
+
§The first cohort, and the rule that selects the next) — now resolves through
|
|
1150
|
+
`gate_run` rather than a held `checks/<name>.sh` path.
|
|
1151
|
+
|
|
1152
|
+
The rest exercise `bin/` tools, which are advisory tooling with no gate to
|
|
1153
|
+
dispatch and so have nothing to say about reach.
|
|
1154
|
+
|
|
592
1155
|
## Per-component contracts
|
|
593
1156
|
|
|
594
1157
|
### lib/stages.sh
|
|
@@ -619,14 +1182,19 @@ which renders the resident registration block (§bin/install-lifecycle.sh) from
|
|
|
619
1182
|
live config so `bin/install-lifecycle.sh` and `check-lifecycle-registration`
|
|
620
1183
|
derive one text and cannot drift. Three more renderers follow the same
|
|
621
1184
|
writer/asserter shape for the merge-attribute surface: `lifecycle_supersede_set`
|
|
622
|
-
prints the derived iteration-scoped supersede set (the state file, the
|
|
623
|
-
lesson-evidence file
|
|
1185
|
+
prints the derived iteration-scoped supersede set (the state file, the two
|
|
1186
|
+
kit-owned built-ins — the lesson-evidence file and the survey record — and each
|
|
1187
|
+
`LIFECYCLE_KIT_BOUNDARY_TRUNCATE` member: exactly
|
|
624
1188
|
what `bin/enter-stage.sh` truncates at the boundary); `lifecycle_union_set`
|
|
625
1189
|
prints the derived union-merge set (the gap inbox — §The committed gap inbox);
|
|
626
1190
|
and `lifecycle_merge_attrs_block` renders the supersede set as
|
|
627
1191
|
`<path> merge=iteration-scoped` lines and the union set as `<path> merge=union`
|
|
628
1192
|
lines, so `bin/install-lifecycle.sh` (writer) and `check-merge-attrs` (asserter)
|
|
629
|
-
read one set (§Multi-operator semantics).
|
|
1193
|
+
read one set (§Multi-operator semantics). `lifecycle_supersede_set` has a **third
|
|
1194
|
+
reader**, `check-scratch-citation`, which forbids a permanent surface pointing a
|
|
1195
|
+
retriever at any of its members — so a consumer adding a
|
|
1196
|
+
`LIFECYCLE_KIT_BOUNDARY_TRUNCATE` member gets citation enforcement over it with no
|
|
1197
|
+
second roster to keep in step. Values and adapters only, never
|
|
630
1198
|
gate structure (gate-sdk's `lib/gate.sh` rule).
|
|
631
1199
|
|
|
632
1200
|
### bin/session-id.sh
|
|
@@ -689,6 +1257,13 @@ The deterministic writer for a stage transition: `enter-stage.sh <stage>`
|
|
|
689
1257
|
appends the invocation stamp, reading `session-id.sh` for
|
|
690
1258
|
the id — never an argument, so the no-hand-picking rule rides into the tool.
|
|
691
1259
|
`<stage>` must be a configured stage; anything else is a usage error (exit 2).
|
|
1260
|
+
Its positionals are membership-validated rather than free text, so it owes no
|
|
1261
|
+
leading-`-` refusal (gate-sdk/SPEC.md §The bin/-tool contract) — but it owes the
|
|
1262
|
+
help half, and `-h`/`--help` as the first argument prints usage on stdout and
|
|
1263
|
+
exits 0. The measured cost of not owing it is in this tool's own history: a
|
|
1264
|
+
session hunting for the rename mode below ran `--help`, got
|
|
1265
|
+
`'--help' is not a lifecycle stage`, and worked around a contract for three
|
|
1266
|
+
sessions that the usage text would have settled in one command.
|
|
692
1267
|
An ordinary stage **writes the evidence file only** — the appended stamp *is*
|
|
693
1268
|
the transition, since the last stamp is the cursor, so the queue file is not
|
|
694
1269
|
touched and need not be committed. The first stage
|
|
@@ -701,10 +1276,23 @@ that vendored the cursor extraction mid-iteration heals at its next boundary
|
|
|
701
1276
|
without a migration step. `LIFECYCLE_KIT_BOUNDARY_TRUNCATE`
|
|
702
1277
|
is a generic per-iteration reset knob — no consumer surface is named in
|
|
703
1278
|
the kit; a downstream kit whose per-iteration file must start each cycle from
|
|
704
|
-
its contract header adds itself here, as evidence-kit's manifest does. The
|
|
705
|
-
kit-owned `LIFECYCLE_KIT_LESSON_EVIDENCE_FILE`
|
|
706
|
-
|
|
707
|
-
|
|
1279
|
+
its contract header adds itself here, as evidence-kit's manifest does. The two
|
|
1280
|
+
kit-owned surfaces — `LIFECYCLE_KIT_LESSON_EVIDENCE_FILE` and
|
|
1281
|
+
`LIFECYCLE_KIT_SURVEY_RECORD_FILE` (§The survey record) — reset by the same rule
|
|
1282
|
+
as **built-in members**: the kit owns those surfaces, so they do not ride the
|
|
1283
|
+
consumer knob (git history keeps the retired stamps and the retired surveys).
|
|
1284
|
+
|
|
1285
|
+
**What counts as the header, for the truncate.** The retained run is the
|
|
1286
|
+
member's leading blank and `#` **comment** lines, stopping at the first data
|
|
1287
|
+
line *or* at a markdown `## ` section heading, whichever comes first. The second
|
|
1288
|
+
half of that predicate is load-bearing rather than defensive: on a markdown
|
|
1289
|
+
surface whose blocks *are* `## ` headings — the survey record — a bare
|
|
1290
|
+
"keep every leading `#` line" rule reads the first block's heading as part of
|
|
1291
|
+
the header and carries one stale survey across the boundary, with the record's
|
|
1292
|
+
own read trigger then advertising it. The failure is silent, survives a green
|
|
1293
|
+
battery, and is invisible to any fixture that does not run a real boundary
|
|
1294
|
+
entry, which is why the boundary behavior is exercised end-to-end in
|
|
1295
|
+
`gate-tests/` rather than reasoned about.
|
|
708
1296
|
|
|
709
1297
|
The boundary reset additionally **wipes the scratch dir** (`GATE_SDK_TMP_DIR`),
|
|
710
1298
|
deleting every member whose basename is neither `.gitkeep` nor a
|
|
@@ -759,7 +1347,20 @@ iteration, so no `[attend]` injection (queue-kit §bin/queue-index.sh) can
|
|
|
759
1347
|
outlive the iteration that filed it. It **likewise refuses while the gap inbox
|
|
760
1348
|
(`LIFECYCLE_KIT_GAP_INBOX_FILE`) holds bullets** — the same refusal contract, so
|
|
761
1349
|
a mid-iteration gap the close skill did not drain (§The committed gap inbox)
|
|
762
|
-
cannot cross the boundary untriaged; an absent inbox has no bullets and passes.
|
|
1350
|
+
cannot cross the boundary untriaged; an absent inbox has no bullets and passes.
|
|
1351
|
+
**The survey record, its neighbour in the boundary reset, deliberately does
|
|
1352
|
+
not refuse** (§The survey record): it is truncated like any built-in member, and
|
|
1353
|
+
a non-empty one is never a blocker, because a survey owes nobody a disposition —
|
|
1354
|
+
it is scratch whose whole lifetime was the iteration just ending. The two
|
|
1355
|
+
surfaces sit one line apart in this tool with opposite semantics, so the
|
|
1356
|
+
asymmetry is stated rather than left to be inferred. The entry additionally
|
|
1357
|
+
carries the record's **read trigger**: when the record is non-empty the report
|
|
1358
|
+
prints its `## ` headings — the questions the iteration's prior surveys answered,
|
|
1359
|
+
never their findings, since printing a possibly-stale judgment ahead of its
|
|
1360
|
+
witness is the failure the witness exists to prevent. It rides the tool every
|
|
1361
|
+
stage already invokes as its first step, so it adds no invocation point and no
|
|
1362
|
+
schedule, and it lands at the one moment a stage session is guaranteed to be
|
|
1363
|
+
looking. The boundary entry additionally **refuses
|
|
763
1364
|
when a `LIFECYCLE_KIT_BOUNDARY_REQUIRE` member lacks a disposition line for the
|
|
764
1365
|
closing iteration** (exit 1, nothing written, the same refusal contract): each
|
|
765
1366
|
member must carry a data line whose first token is the closing iteration's name,
|
|
@@ -801,15 +1402,92 @@ a stamp. Exit 0 = the real entry would proceed (or no-op); exit 1 = it would
|
|
|
801
1402
|
refuse, with the refusing check's output relayed line-by-line; exit 2 =
|
|
802
1403
|
usage/config error, as a real entry. Not a gate — exercised in `smoke/`
|
|
803
1404
|
beside the existing enter-stage coverage (would-pass, would-refuse,
|
|
804
|
-
would-no-op, nothing written).
|
|
1405
|
+
would-no-op, nothing written).
|
|
1406
|
+
|
|
1407
|
+
**`--rename <name>` — the mechanized iteration rename.** Naming an iteration is
|
|
1408
|
+
a **two-surface** write — the queue header's placeholder and column 1 of the
|
|
1409
|
+
first stage's stamp — which `check-stage-evidence` requires to agree, so it rides
|
|
1410
|
+
this writer rather than a second tool. `[--simulate] --rename <name>` sets the
|
|
1411
|
+
header to `## Iteration: <name>` and rewrites column 1 of **every** data line in
|
|
1412
|
+
the state file. Every line rather than only the last is correct by the boundary
|
|
1413
|
+
invariant, not by convenience: the first-stage entry truncates the state file, so
|
|
1414
|
+
every line below the separator belongs to the current iteration by construction —
|
|
1415
|
+
which is exactly what `check-stage-evidence` asserts — and the whole-file rewrite
|
|
1416
|
+
therefore also heals a half-landed hand-rename. **It is not stage motion**: no
|
|
1417
|
+
stamp is appended and no stage token is written, so the cursor is untouched and
|
|
1418
|
+
"stage motion never writes the queue" is unweakened. The precedent for this tool
|
|
1419
|
+
writing the queue header at all is the boundary reset, which already does.
|
|
1420
|
+
|
|
1421
|
+
Before writing, the mode asserts its **columns-2-4 witness** — fields 2 through
|
|
1422
|
+
4 of every data line (stage, session id, date) identical before and after. This
|
|
1423
|
+
is the content predicate applied by the **writer**, where it is cheap and exact,
|
|
1424
|
+
rather than by the `Write`/`Edit` guard: a `PreToolUse` hook sees only *proposed*
|
|
1425
|
+
content, so proving "no stage token moved" there means reconstructing the
|
|
1426
|
+
pre-edit file and diffing field-wise inside a hook — the same computation with
|
|
1427
|
+
less information and no way to refuse cleanly. **Pre-flight, the same contract as
|
|
1428
|
+
the stamp path:** the candidate header and candidate state file are built as
|
|
1429
|
+
temporaries, `check-stage-evidence` runs against them, and a non-zero exit
|
|
1430
|
+
refuses with the gate's output relayed and nothing written. That gate is
|
|
1431
|
+
resolved through gate-sdk's `gate_command` rather than named by script path, so
|
|
1432
|
+
the arm names a gate and never a substrate: the resolved argv is prefix-shaped,
|
|
1433
|
+
so the two positionals ride it unchanged, and an argv the bridge refused to build
|
|
1434
|
+
is exit 2 — the dispatcher's own verdict — never a rename pre-flighted by a check
|
|
1435
|
+
that did not run. The built-in `check-stage-entry` pre-flight above keeps its
|
|
1436
|
+
script path because that member is held on shell (gate-sdk/SPEC.md §The first
|
|
1437
|
+
cohort, and the rule that selects the next), so the two arms of this tool
|
|
1438
|
+
resolve differently and the difference is the member's substrate, not a
|
|
1439
|
+
convention gap. **Refusals** (exit 2,
|
|
1440
|
+
nothing written): `<name>` empty; `<name>` equal to the unnamed placeholder,
|
|
1441
|
+
which only the boundary reset may write — checked ahead of the grammar that would
|
|
1442
|
+
also reject it, so the message names the owning writer instead of reporting a
|
|
1443
|
+
malformed name; and `<name>` outside the queue slug grammar `[a-z0-9][a-z0-9-]*`,
|
|
1444
|
+
where whitespace is the corrupting case, since column 1 is whitespace-delimited
|
|
1445
|
+
and a two-word name silently shifts every field of every stamp.
|
|
1446
|
+
**Idempotent** in the stamp path's sense: a header and every column 1 already
|
|
1447
|
+
reading `<name>` reports and exits 0 without writing. `--simulate --rename`
|
|
1448
|
+
relays what would change, prefixed `enter-stage (simulate):`, and writes nothing.
|
|
1449
|
+
The report names both written files and says to commit them together, which makes
|
|
1450
|
+
the one-commit coupling a property of the writer instead of a line of prose in
|
|
1451
|
+
the calling stage template.
|
|
1452
|
+
|
|
1453
|
+
One reader is **invalidated** by a rename rather than served by it, and it is the
|
|
1454
|
+
reason the placeholder refusal exists: `LIFECYCLE_KIT_BOUNDARY_REQUIRE`'s check
|
|
1455
|
+
matches the closing iteration's name against the first token of a disposition
|
|
1456
|
+
line and reds on finding *none*, so a rename landing after the close stage has
|
|
1457
|
+
stamped its disposition reds the next boundary. Renaming an iteration that has
|
|
1458
|
+
already been dispositioned is a rename to redo at the disposition surface too;
|
|
1459
|
+
un-naming one is refused outright.
|
|
1460
|
+
|
|
1461
|
+
**Ruled out: a separate `rename-iteration.sh` tool.** It would add a second
|
|
1462
|
+
sanctioned writer of the state file, and one-writer is the property the
|
|
1463
|
+
`Write`/`Edit` guard's own block message asserts and the whole reason that guard
|
|
1464
|
+
exists. Advisory tooling like `--simulate`, so no fixture pair is owed; the
|
|
1465
|
+
hermetic cases — both surfaces rewritten, fields 2-4 proved unchanged, the
|
|
1466
|
+
half-landed heal, each refusal, the idempotent no-op, and `--simulate --rename`
|
|
1467
|
+
writing nothing — live in `gate-tests/`, because a rename cannot be exercised
|
|
1468
|
+
against a live checkout's own queue the way `smoke/` exercises the stamp path.
|
|
1469
|
+
|
|
1470
|
+
**Idempotent:** if the
|
|
805
1471
|
state file already ends with a stamp for the same `<iteration> <stage> <id>`,
|
|
806
1472
|
it reports and exits 0 without appending, so a crashed-and-resumed session
|
|
807
1473
|
re-runs its entry step safely. It reads the `lib/stages.sh` knobs
|
|
808
1474
|
(`LIFECYCLE_KIT_QUEUE_FILE`, `LIFECYCLE_KIT_STATE_FILE`, `LIFECYCLE_KIT_STAGES`,
|
|
809
1475
|
`LIFECYCLE_KIT_FIRST_STAGE`, `LIFECYCLE_KIT_BOUNDARY_TRUNCATE`,
|
|
810
1476
|
`LIFECYCLE_KIT_BOUNDARY_PRESERVE`,
|
|
811
|
-
`LIFECYCLE_KIT_BOUNDARY_REQUIRE`, `LIFECYCLE_KIT_LESSON_EVIDENCE_FILE`,
|
|
812
|
-
`
|
|
1477
|
+
`LIFECYCLE_KIT_BOUNDARY_REQUIRE`, `LIFECYCLE_KIT_LESSON_EVIDENCE_FILE`,
|
|
1478
|
+
`LIFECYCLE_KIT_SURVEY_RECORD_FILE`, and
|
|
1479
|
+
`LIFECYCLE_KIT_ENTRY_PREFLIGHT`).
|
|
1480
|
+
|
|
1481
|
+
**This tool depends on `gate-sdk/lib/gate.sh`, and the dependency is stated
|
|
1482
|
+
rather than absorbed.** It is sourced at load — from `GATE_SDK_ROOT`, defaulting
|
|
1483
|
+
to the sibling `../gate-sdk` — not inside the one arm that dispatches a gate,
|
|
1484
|
+
because a missing library that surfaces halfway through a rename is worse than
|
|
1485
|
+
one that surfaces before the tool does anything. The dependency is precedented
|
|
1486
|
+
inside the kit, where every `checks/` member sources exactly that library, but it
|
|
1487
|
+
is new in `bin/`: a tree that vendored lifecycle-kit without gate-sdk cannot run
|
|
1488
|
+
the stamp writer at all. The alternative — a second
|
|
1489
|
+
dispatch resolver written into `bin/` — is the duplicate the shared substrate
|
|
1490
|
+
exists to remove, so the dependency is taken. Advisory tooling,
|
|
813
1491
|
not a gate: no fixture pair is owed; it is exercised end-to-end in
|
|
814
1492
|
`smoke/install.sh` — including the boundary require-check scenarios (a member
|
|
815
1493
|
naming the closing iteration passes; a member missing the line, a member absent
|
|
@@ -887,9 +1565,10 @@ declaration names a reclaim command**.
|
|
|
887
1565
|
Assertion B is shape-only, and resolution is somebody else's job already:
|
|
888
1566
|
`check-spec-pointer`'s prose pass resolves a `forced=` citation on any manifest
|
|
889
1567
|
surface (§The close-surface roster). Taking the presence-and-shape half here is
|
|
890
|
-
not a preference —
|
|
891
|
-
|
|
892
|
-
|
|
1568
|
+
not a preference — canon-kit's heading resolver is defined *inside its own gate*
|
|
1569
|
+
rather than exported from a library, and the port to the binary substrate did not
|
|
1570
|
+
change that: it is a private function of the compiled member, so there is still
|
|
1571
|
+
no resolver a second gate could call. Reaching it would mean either copying
|
|
893
1572
|
the resolver, which canon-kit's own tiering rule bans, or making lifecycle-kit
|
|
894
1573
|
depend on canon-kit — the same ownership-cycle argument that rules out the log
|
|
895
1574
|
merge. The honest arrangement is a pair of gates independently reading one
|
|
@@ -933,7 +1612,10 @@ owed (the enforcement-first weighing). The freshness posture is
|
|
|
933
1612
|
|
|
934
1613
|
A missing block is a finding with the install remedy; a block present but out
|
|
935
1614
|
of lockstep is a finding printing the diff and the regenerate remedy (both
|
|
936
|
-
exit 1).
|
|
1615
|
+
exit 1). The stale-block report prints **every** hunk: the format and the
|
|
1616
|
+
uncapped contract are the crate renderer's, whose home is
|
|
1617
|
+
gate-sdk/SPEC.md §The diff renderer since it stopped being this gate's private
|
|
1618
|
+
mechanism, and this gate is its one live consumer. Resolution fails closed: a missing agent file, a begin marker without
|
|
937
1619
|
its end, or an errored awk capture is exit 2 — a half-written or unreadable
|
|
938
1620
|
target must not pass as clean. The gate satisfies the four gate-sdk contracts
|
|
939
1621
|
(gate-sdk/SPEC.md §The gate model): the single `LIFECYCLE-REGISTRATION: clean`
|
|
@@ -1011,6 +1693,37 @@ evidence manifest (a suite verdict per line) and, via the optional
|
|
|
1011
1693
|
`LIFECYCLE_KIT_BOUNDARY_TRUNCATE` integration, couples a close entry to
|
|
1012
1694
|
the full green block.
|
|
1013
1695
|
|
|
1696
|
+
**The uncommitted window, and what closes it.** This gate — and every other one
|
|
1697
|
+
that would catch a hand-written stamp — fires at *commit*. The cursor, though, is
|
|
1698
|
+
the working tree's last stamp, and every reader reads the working tree. So a
|
|
1699
|
+
session that hand-edits the state file and simply never commits moves the stage
|
|
1700
|
+
cursor for its entire life and is caught by nothing. Content-based detection
|
|
1701
|
+
cannot help: a hand-written stamp is byte-identical to `bin/enter-stage.sh`'s by
|
|
1702
|
+
design.
|
|
1703
|
+
|
|
1704
|
+
`templates/workflow-state-guard.sh` closes the part of that window an agent
|
|
1705
|
+
tooling actually passes through. It is a `PreToolUse(Write|Edit)` hook (register
|
|
1706
|
+
it on the alternation matcher; guard-kit's wiring template carries the block) that
|
|
1707
|
+
refuses a write whose target **resolves** to the state file, naming
|
|
1708
|
+
`bin/enter-stage.sh` as the sanctioned writer. Resolved, not textual: an absolute
|
|
1709
|
+
path, a `./` prefix and a route through a symlinked directory are one file, and a
|
|
1710
|
+
textual comparison catches only the spelling it was written against. It reads the
|
|
1711
|
+
path through guard-kit's `guard_read_path` and rides `lib/guard.sh` on the
|
|
1712
|
+
`GUARD_KIT_LIB` indirection, so lifecycle-kit ships the rule and guard-kit ships
|
|
1713
|
+
the mechanism (guard-kit/SPEC.md §The guard framework). The
|
|
1714
|
+
`GATE_SDK_WORKFLOW_DIR` indirection is honored, so a consumer who relocated the
|
|
1715
|
+
workflow directory gets a guard that follows it. No knob is added: there is no
|
|
1716
|
+
value to configure.
|
|
1717
|
+
|
|
1718
|
+
The residual is stated because an unstated residual reads as a closed hole. The
|
|
1719
|
+
guard reaches agent `Write`/`Edit` tool calls and nothing else — not a `Bash`
|
|
1720
|
+
redirect, not `--no-verify` at the commit that would have caught the result, not a
|
|
1721
|
+
human editing the file outside the agent tooling, and not any future writer that
|
|
1722
|
+
is not one of those tool calls. It narrows the window to the writers the harness
|
|
1723
|
+
routes through a hook; it does not close it. And it is inert until wired: shipping
|
|
1724
|
+
the template without the settings block yields a file that enforces nothing while
|
|
1725
|
+
looking like it does.
|
|
1726
|
+
|
|
1014
1727
|
### check-stage-entry
|
|
1015
1728
|
|
|
1016
1729
|
Invariant: the stage being *entered* re-verifies its prior stage's static
|
|
@@ -1126,8 +1839,8 @@ tokens; a shim's bindings are the `**slot-name** —` lead lines under
|
|
|
1126
1839
|
`## Bindings`; the directive's template path resolves relative to the current
|
|
1127
1840
|
directory (the tree root at pre-commit). A skills dir that does not exist is
|
|
1128
1841
|
fail-closed (exit 2). The `# graph:` couples the skills dir, the stage-template
|
|
1129
|
-
dir, each boundary skill (`lead.md`, `release-sweep.md`, `upgrade.md
|
|
1130
|
-
out-of-tree bound template (e.g. `delegation-kit/templates/agent-execution.md`)
|
|
1842
|
+
dir, each boundary skill (`lead.md`, `release-sweep.md`, `upgrade.md`,
|
|
1843
|
+
`consult.md`), and each out-of-tree bound template (e.g. `delegation-kit/templates/agent-execution.md`)
|
|
1131
1844
|
at `tier=precommit`, so a slot added to a template or a binding changed in a shim
|
|
1132
1845
|
fires the gate. The boundary skills are coupled **by name** because this couple
|
|
1133
1846
|
carries no kit-wide `templates/*.md` glob: a bindable template left off it is one
|
|
@@ -1225,7 +1938,8 @@ a git-native driver a consumer's own tracked append log legitimately carries
|
|
|
1225
1938
|
(§Multi-operator semantics), so there is no smuggling to catch. A missing
|
|
1226
1939
|
`.gitattributes` reports every derived surface as unmechanized (exit 1, the
|
|
1227
1940
|
install remedy); an unreadable one, an empty supersede set (a lifecycle always
|
|
1228
|
-
owns at least its state
|
|
1941
|
+
owns at least its state file and its two kit-owned built-ins, the
|
|
1942
|
+
lesson-evidence file and the survey record), or an empty union set (it
|
|
1229
1943
|
always owns at least its gap inbox), is fail-closed (exit 2).
|
|
1230
1944
|
|
|
1231
1945
|
The gate satisfies the four gate-sdk contracts (gate-sdk/SPEC.md §The gate model):
|
|
@@ -1246,6 +1960,164 @@ a reshaped `LIFECYCLE_KIT_BOUNDARY_TRUNCATE` in the consumer config is backstopp
|
|
|
1246
1960
|
by the whole-tree `run-gates.sh` battery (the `check-stage-skill-coverage`
|
|
1247
1961
|
precedent).
|
|
1248
1962
|
|
|
1963
|
+
### check-survey-record
|
|
1964
|
+
|
|
1965
|
+
Invariant: every block in the survey record (§The survey record) carries a whole
|
|
1966
|
+
witness. Over each `## ` block: all four keys present, in order, one per line
|
|
1967
|
+
(and no fifth key, no stray line); `corpus` non-empty; `oracle` non-empty, where
|
|
1968
|
+
the literal `none` is legal and is the honest form and an *empty* value is the
|
|
1969
|
+
silent form and is refused; and `rev` a full 40-hex sha naming a commit that
|
|
1970
|
+
exists — the assertion that catches the short-sha and wrong-rev cases, and the
|
|
1971
|
+
reason the field is machine-stamped rather than author-supplied.
|
|
1972
|
+
|
|
1973
|
+
An absent record, and a record truncated to its header, are **clean and counted
|
|
1974
|
+
inert**: the surface is optional, and a consumer that never files a survey must
|
|
1975
|
+
not carry a red gate.
|
|
1976
|
+
|
|
1977
|
+
Enforcement-first is why the gate ships in the same unit as the surface rather
|
|
1978
|
+
than as follow-up debt: a block missing its witness is *silently unusable*,
|
|
1979
|
+
which is the exact failure class the surface exists to close.
|
|
1980
|
+
|
|
1981
|
+
**Bare drives the configured record with the full assertion set; an explicit
|
|
1982
|
+
file argument drives it hermetically — grammar only, with no rev-existence
|
|
1983
|
+
probe.** That split is forced by portability rather than convenience: a fixture's
|
|
1984
|
+
`rev` names no commit in the tree the fixture is copied into, so a pair asserting
|
|
1985
|
+
existence would go red in every consumer that vendored the kit. Bare also
|
|
1986
|
+
degrades to grammar-only outside a git repository, where there is nothing to
|
|
1987
|
+
resolve a sha against. The clean line names which mode ran, so a grammar-only
|
|
1988
|
+
pass can never be read as a verified one.
|
|
1989
|
+
|
|
1990
|
+
The gate satisfies the four gate-sdk contracts (gate-sdk/SPEC.md §The gate
|
|
1991
|
+
model): the single `SURVEY-RECORD: clean` line and a `help:` remedy naming the
|
|
1992
|
+
grammar and `bin/file-survey.sh` on the finding path (output); exit 2 on an
|
|
1993
|
+
unreadable or explicitly-named-but-missing record and on a failed parse
|
|
1994
|
+
(fail-closed); a `good/`+`bad/` fixture pair under `gate-tests/` driven through
|
|
1995
|
+
the hermetic argument — the good case a two-block record including an
|
|
1996
|
+
`oracle: none` note, the bad case a short sha, an empty oracle and a block with
|
|
1997
|
+
its `oracle` line missing — plus `gate-tests/check-survey-record.test.sh` for the
|
|
1998
|
+
half the pair cannot hold: both arms of the rev-existence probe in a sandbox
|
|
1999
|
+
repo (a rev naming a real commit, and a well-formed 40-hex rev naming nothing)
|
|
2000
|
+
and the two inert shapes (fixture-pair); and registration in this repo's
|
|
2001
|
+
`gates.list`, where its scan target is this repo's own record (self-lint). Its
|
|
2002
|
+
`# graph:` couples the record at `tier=precommit`.
|
|
2003
|
+
|
|
2004
|
+
*Not gated, and stated so the gate is not mistaken for more than it is:* whether
|
|
2005
|
+
a `finding` is **true**, and whether a session holding a fresh record actually
|
|
2006
|
+
read it. The first is unmechanizable; the second leaves no tracked artifact —
|
|
2007
|
+
the class delegation-kit/SPEC.md §Operative residency rules no gate is owed for.
|
|
2008
|
+
The entry report's read trigger (§bin/enter-stage.sh) is the affordance in place
|
|
2009
|
+
of an oracle there, and it is weaker than one by construction.
|
|
2010
|
+
|
|
2011
|
+
### check-scratch-citation
|
|
2012
|
+
|
|
2013
|
+
Invariant: no surface in `LIFECYCLE_KIT_PERMANENT_SURFACE_GLOBS` carries a
|
|
2014
|
+
**retrieval pointer** to a path in the derived boundary-truncated set. The rule
|
|
2015
|
+
and why inlining is the right close are §The survey record's; this section owns
|
|
2016
|
+
the red condition.
|
|
2017
|
+
|
|
2018
|
+
**The forbidden-target set is derived, never maintained** — it is
|
|
2019
|
+
`lifecycle_supersede_set` (§lib/stages.sh), already the single derivation behind
|
|
2020
|
+
the installer's `.gitattributes` block and `check-merge-attrs`'s parity check.
|
|
2021
|
+
This gate is its third reader, which is why a consumer widening its truncate
|
|
2022
|
+
configuration gets citation enforcement for free.
|
|
2023
|
+
|
|
2024
|
+
**Retrieval-pointer position, stated as the red condition.** A supersede-set path
|
|
2025
|
+
that is either **(a)** in markdown link-target position — the parenthesized half
|
|
2026
|
+
of a `[text]`-plus-parentheses pair — or **(b)** preceded
|
|
2027
|
+
by a colon and whitespace and followed by nothing but a closing quote, comma,
|
|
2028
|
+
period, bracket or end of paragraph — the attested form, *"Full finding and its
|
|
2029
|
+
two-command witness"* followed by the path. A bare path elsewhere in prose is a
|
|
2030
|
+
**mention** and is clean; that is the whole calibration, and it is why this is
|
|
2031
|
+
specified as a position rather than as a pattern.
|
|
2032
|
+
|
|
2033
|
+
**The scan joins a paragraph's wrapped continuation lines before testing (b), or
|
|
2034
|
+
it is blind on its own worked example.** A queue file wraps prose to a budget, so
|
|
2035
|
+
a colon and the path it introduces routinely land on different physical lines —
|
|
2036
|
+
which is exactly what the attested instance did. The join is
|
|
2037
|
+
`check-spec-pointer`'s prose-extraction shape (canon-kit/SPEC.md
|
|
2038
|
+
§check-spec-pointer), adopted rather
|
|
2039
|
+
than re-decided: concatenate a blank-line-delimited paragraph, match over the
|
|
2040
|
+
join, and map a hit back to its physical line through per-line start offsets. A
|
|
2041
|
+
scanner that is right on an unwrapped fixture and silently blind on the wrapped
|
|
2042
|
+
case it was written for is the failure this forecloses, which is why the `bad/`
|
|
2043
|
+
case carries a wrapped instance beside the single-line and markdown-link forms.
|
|
2044
|
+
|
|
2045
|
+
**Per-line escape hatch:** a `scratch-citation-exempt:` tag on the line above the
|
|
2046
|
+
hit, this repo's established opt-out shape, for a surface that must quote a dead
|
|
2047
|
+
citation verbatim in order to describe it. Its reader is this gate's scanner, at
|
|
2048
|
+
the transition where it has matched a pointer and is deciding whether to record a
|
|
2049
|
+
finding. *Stated so it is not mistaken for more than it is:* the class is real and
|
|
2050
|
+
permanent — any entry documenting a citation defect must quote one — but the tree
|
|
2051
|
+
carries no live user today, because the entry that motivated the tag completed and
|
|
2052
|
+
its prose left the queue with it. The `bad/`+`good/` fixture pair is where the
|
|
2053
|
+
hatch is exercised.
|
|
2054
|
+
|
|
2055
|
+
The gate satisfies the four gate-sdk contracts: the single
|
|
2056
|
+
`SCRATCH-CITATION: clean` line naming how many surfaces were scanned, and a
|
|
2057
|
+
`help:` remedy naming `bin/cite-survey.sh` and the exempt tag on the finding path
|
|
2058
|
+
(output); exit 2 on an empty derived target set and on a failed parse
|
|
2059
|
+
(fail-closed); a `good/`+`bad/` pair whose good case copies the mention forms live
|
|
2060
|
+
entries actually use — a path opening a wrapped line after a full stop, a
|
|
2061
|
+
prepositional mention, a colon-introduced pointer at a **non**-member path, and a
|
|
2062
|
+
tagged dead citation — because a rule that reds any of those is wrong and the
|
|
2063
|
+
fixture is what says so (fixture-pair); and registration in this repo's
|
|
2064
|
+
`gates.list`, where its surfaces are this repo's own queue and spec set
|
|
2065
|
+
(self-lint).
|
|
2066
|
+
|
|
2067
|
+
*Not gated:* whether an inlined finding is faithful to the block it came from.
|
|
2068
|
+
Nothing tracked relates the two once the record is truncated, and inventing a
|
|
2069
|
+
provenance field would re-open the per-iteration lifetime the record's design
|
|
2070
|
+
turns on.
|
|
2071
|
+
|
|
2072
|
+
### check-gap-inbox-neutrality
|
|
2073
|
+
|
|
2074
|
+
Invariant: the gap inbox (§The committed gap inbox) records observations, not
|
|
2075
|
+
conclusions. Two assertions over every non-blank line below the `# contract:`
|
|
2076
|
+
header:
|
|
2077
|
+
|
|
2078
|
+
- **A — grammar.** Every line is `- <YYYY-MM-DD> — <prose>` with non-empty
|
|
2079
|
+
prose. Nothing gated this before, even though the raw append is an explicitly
|
|
2080
|
+
legal fallback, so a malformed bullet was found by the drain reading it an
|
|
2081
|
+
iteration later.
|
|
2082
|
+
- **B — no interposed verdict.** No bullet's prose opens with the retired
|
|
2083
|
+
``recurrence of `<slug>`:`` form. This is the class assertion, and its value is
|
|
2084
|
+
that it catches a conclusion reaching the capture surface **by any producer** —
|
|
2085
|
+
a stale vendored affordance, a hand append copying an older bullet's shape —
|
|
2086
|
+
rather than only the affordance this kit ships. The `help:` line teaches the
|
|
2087
|
+
rule rather than the regex: say *why* you believe the bullet re-files an entry,
|
|
2088
|
+
in the prose, and let the drain judge.
|
|
2089
|
+
|
|
2090
|
+
An absent inbox is **clean, not fail-closed** — never having filed a gap is a
|
|
2091
|
+
legal state for a fresh consumer, unlike §check-lifecycle-registration's missing
|
|
2092
|
+
agent file, which is an install that did not finish. Fail-closed applies to the
|
|
2093
|
+
scanner's own exit status, per gate-sdk's contract.
|
|
2094
|
+
|
|
2095
|
+
**Bare drives the configured inbox; an explicit file argument drives it
|
|
2096
|
+
hermetically**, the §check-survey-record precedent, which is what lets the
|
|
2097
|
+
fixture pair run against a copied inbox.
|
|
2098
|
+
|
|
2099
|
+
**Why the tool-side contract is pinned separately.** This gate reads the surface
|
|
2100
|
+
and cannot see which producer wrote a line, so it cannot hold the affordance to
|
|
2101
|
+
its own contract. `gate-tests/file-gap-recurrence.test.sh` is what does that. The
|
|
2102
|
+
two together are the enforcement: the fixture-runner catches the producer
|
|
2103
|
+
regressing, the gate catches a verdict arriving by any other route.
|
|
2104
|
+
|
|
2105
|
+
The gate satisfies the four gate-sdk contracts (gate-sdk/SPEC.md §The gate
|
|
2106
|
+
model): the single `GAP-INBOX-NEUTRALITY: clean` line and a `help:` remedy on the
|
|
2107
|
+
finding path (output); exit 2 on an unreadable or explicitly-named-but-missing
|
|
2108
|
+
inbox and on a failed parse (fail-closed); a `good/`+`bad/` fixture pair under
|
|
2109
|
+
`gate-tests/` driven through the hermetic argument — the good case a record whose
|
|
2110
|
+
prose both re-files and disclaims an entry in words, the bad case a retired
|
|
2111
|
+
marker beside two broken bullets (fixture-pair); and registration in this repo's
|
|
2112
|
+
`gates.list`, where its scan target is this repo's own inbox (self-lint). Its
|
|
2113
|
+
`# graph:` couples the inbox at `tier=precommit`.
|
|
2114
|
+
|
|
2115
|
+
*Not gated, and stated so the gate is not mistaken for more than it is:* whether
|
|
2116
|
+
a bullet's prose states the recurrence claim **at all**, and whether the claim is
|
|
2117
|
+
**right**. Assertion B removes the one shape that pre-empts the judge; it cannot
|
|
2118
|
+
compel a filer to answer the advisory, and the judgment itself is the drain's
|
|
2119
|
+
(§templates/stages/), which is where the amendment deliberately put it.
|
|
2120
|
+
|
|
1249
2121
|
### templates/stages/
|
|
1250
2122
|
|
|
1251
2123
|
The stage-skill templates (`scope`/`align`/`build`/`validate`/`close`) carry
|
|
@@ -1457,13 +2329,23 @@ dispatch policy in the ruling-config slot), the lead model (dispatch a
|
|
|
1457
2329
|
stage session as a background agent whose prompt is that stage's ordinary skill
|
|
1458
2330
|
invocation, with the inline-run posture sentence reading
|
|
1459
2331
|
`LIFECYCLE_KIT_SESSION_BOUNDARY` — inline stage runs banned under `stage`,
|
|
1460
|
-
the sanctioned blocked-dispatch fallback under `iteration
|
|
2332
|
+
the sanctioned blocked-dispatch fallback under `iteration`; and the
|
|
2333
|
+
completion-notification dispatch precondition, with the prompt-answered-signal
|
|
2334
|
+
trap and the gating-versus-liveness boundary that keeps it from reading as a
|
|
2335
|
+
reversal of the hand-derivation corollary below — its honest limit is recorded
|
|
2336
|
+
in §The state machine and it is standing lead policy under the
|
|
2337
|
+
policy-is-config rule), the
|
|
1461
2338
|
opening-an-iteration contract (the lead never selects the unit set — it relays
|
|
1462
2339
|
the operator's standing directive, a theme bounding scope's survey and never a
|
|
1463
2340
|
slug list, verbatim in the scope dispatch, and routes scope's proposed set back
|
|
1464
2341
|
as an ordinary escalation; selection is scope's contract, and a lead-authored
|
|
1465
2342
|
menu pre-empts the premise re-verification), the four-header
|
|
1466
|
-
escalation block (Question / Options / Recommendation / Evidence)
|
|
2343
|
+
escalation block (Question / Options / Recommendation / Evidence) together with
|
|
2344
|
+
the one class the lead never rules under either posture — reversing, demoting or
|
|
2345
|
+
re-scoping a recorded operator ruling or a stated objective is operator-class and
|
|
2346
|
+
is relayed, carved out of the derivable-from-the-governed-surfaces routing rule
|
|
2347
|
+
because a session holding contrary evidence reads the surface carrying the ruling
|
|
2348
|
+
as stale rather than as closed, the split-channel design (routine narration to the
|
|
1467
2349
|
resume journal, escalations to the message channel), the compact economics —
|
|
1468
2350
|
the split-where-the-tail-dominates rule, the unified posture's handoff compact,
|
|
1469
2351
|
and operator-suggested compacts at the acceptance
|
|
@@ -1473,7 +2355,7 @@ iteration promoted rather than from the amendment set, then batch units
|
|
|
1473
2355
|
sharing a kit or SPEC surface, split on a model-tier change or a
|
|
1474
2356
|
delegation-kit split trigger) and
|
|
1475
2357
|
the lead-owns-batching clause (an intra-stage batch split is N sibling stage
|
|
1476
|
-
sessions the lead dispatches and
|
|
2358
|
+
sessions the lead dispatches and verifies — each a same-stage re-entry,
|
|
1477
2359
|
§The state machine — and a stage session never dispatches a sibling stage
|
|
1478
2360
|
session), and
|
|
1479
2361
|
the stamps-authoritative invariant carried from §The state machine as the
|
|
@@ -1494,9 +2376,77 @@ The template also carries the lead's first step —
|
|
|
1494
2376
|
writing the session-role marker context-kit's hook reads
|
|
1495
2377
|
(context-kit/SPEC.md §The session-context hook). Dispatch safety is not re-owned — it inherits
|
|
1496
2378
|
delegation-kit's protocol by citation (delegation-kit/SPEC.md §The delegation
|
|
1497
|
-
model: background dispatch, the per-dispatch budget guard,
|
|
1498
|
-
agent commit)
|
|
2379
|
+
model: background dispatch, the per-dispatch budget guard, verify after any
|
|
2380
|
+
agent commit) — with one lifecycle **instance** the generic rule cannot state
|
|
2381
|
+
because it would have to name a stage: when the dispatched stage is the
|
|
2382
|
+
evidence-producing one, the lead's verify is a read of the committed evidence
|
|
2383
|
+
manifest rather than a re-run of its producer, the harm splitting between an
|
|
2384
|
+
inert battery re-run and a destructive producer re-run (delegation-kit/SPEC.md
|
|
2385
|
+
§Verify after every agent commit owns the generic rule and the split; its honest
|
|
2386
|
+
limit here is recorded in §The state machine). Consumer residue stays in named slots — the tracked
|
|
1499
2387
|
agent-definition carrying the standing dispatch policy the dispatch names (the
|
|
1500
2388
|
ruling-class roster and everything else true of every dispatch, not improvised
|
|
1501
2389
|
per prompt), and whether the consumer wires the optional escalation-shape guard
|
|
1502
2390
|
(guard-kit/SPEC.md §wakeup-guard) or leaves it inert.
|
|
2391
|
+
|
|
2392
|
+
### templates/consult.md
|
|
2393
|
+
|
|
2394
|
+
The **operator strategy session** template, and a **boundary skill** of the class
|
|
2395
|
+
§Layout and configuration enumerates: like `lead.md` it invokes no
|
|
2396
|
+
`enter-stage.sh`, stamps nothing, and joins no stage set, so
|
|
2397
|
+
`check-stage-skill-coverage` never reads it. The classification is what makes it
|
|
2398
|
+
cost no new mechanism. A consultation may run before an iteration opens, between
|
|
2399
|
+
stages, or across an iteration boundary, and a template with no cursor is at odds
|
|
2400
|
+
with none of those. It carries named slots, so it adopts the
|
|
2401
|
+
binding-shim grammar (§templates/stages/) and `check-skill-binding` holds the
|
|
2402
|
+
slot pairing.
|
|
2403
|
+
|
|
2404
|
+
*A seventh stage was ruled out.* It would need a predecessor entry in
|
|
2405
|
+
`LIFECYCLE_KIT_STAGES`, a fixed position in the walk, and a stamp — none of which
|
|
2406
|
+
a session that may precede or span an iteration has — and it would make
|
|
2407
|
+
`check-stage-entry` assertion A demand a consult stamp on every iteration that
|
|
2408
|
+
legitimately holds no consultation.
|
|
2409
|
+
|
|
2410
|
+
**What the template owns** is a landing contract: the session's exit condition is
|
|
2411
|
+
that every ruling the operator closed has reached a governed surface, every
|
|
2412
|
+
refused alternative is recorded with its grounds, and every always-loaded surface
|
|
2413
|
+
those rulings stale is corrected, flagged, or filed. Two mechanisms are what make
|
|
2414
|
+
that reachable rather than aspirational, and both are stated in the ritual. A
|
|
2415
|
+
ruling lands **at the moment it closes**, not at exit, so an interrupted session
|
|
2416
|
+
loses at most the ruling in flight rather than the session's whole output. And
|
|
2417
|
+
the session journals while it cannot commit, on the durability rule at its owning
|
|
2418
|
+
tier (delegation-kit/SPEC.md §Resume journal — agent writes, scratch reset
|
|
2419
|
+
sweeps), which is what converts a shared index held by a live stage session from
|
|
2420
|
+
data loss into latency. The journal's reclaim is the existing boundary wipe of
|
|
2421
|
+
the scratch dir (§bin/enter-stage.sh) and no `LIFECYCLE_KIT_BOUNDARY_PRESERVE`
|
|
2422
|
+
entry is added — a preserved journal would outlive the session that can interpret
|
|
2423
|
+
it, its content having been discharged into a commit at exit.
|
|
2424
|
+
|
|
2425
|
+
**Write authority is not this template's to grant.** Who may record a ruling on a
|
|
2426
|
+
consumer's ruling record is stated by that record, at the widest tier true for
|
|
2427
|
+
every reader of it — every session that closes a ruling with the operator faces
|
|
2428
|
+
the question, not only a consult session. What the skill adds on top is
|
|
2429
|
+
obligation: elsewhere recording a closed ruling is permitted, here a consultation
|
|
2430
|
+
that did not record one has not exited.
|
|
2431
|
+
|
|
2432
|
+
Dispatch safety is inherited by citation rather than re-owned
|
|
2433
|
+
(delegation-kit/templates/agent-execution.md), on the same rule
|
|
2434
|
+
§templates/lead.md follows — a copied protocol is a second content tier that
|
|
2435
|
+
drifts. The template does state **tier selection** in its own right, because the
|
|
2436
|
+
hazard is sharper here than for a stage session: an unselected dispatch inherits
|
|
2437
|
+
the dispatcher's tier, and a consultation runs at the judgment tier while most of
|
|
2438
|
+
what it dispatches is read-only research, so an unselected fan-out buys the most
|
|
2439
|
+
expensive tier for the cheapest work.
|
|
2440
|
+
|
|
2441
|
+
Consumer residue stays in exactly **two named slots**, and the split is the
|
|
2442
|
+
provenance seam rather than a convenience — `entry-reading` (the surfaces a
|
|
2443
|
+
consultation reads on entry) and `landing-surfaces` (the surfaces a closed ruling
|
|
2444
|
+
may land on, by ruling class). A consumer's entry set reaches its private
|
|
2445
|
+
context, and a kit literal naming it would publish a private surface; its landing
|
|
2446
|
+
set names that consumer's own governance layout, and a kit shipping those names
|
|
2447
|
+
would ship one project's layout as everyone's. What stays kit mechanism is the
|
|
2448
|
+
shape: a consultation has an entry read-set and an exit landing-set, and every
|
|
2449
|
+
closed ruling reaches the landing set before the session ends. Each slot has a
|
|
2450
|
+
named reader — the entry step and the exit check respectively — and
|
|
2451
|
+
`check-skill-binding` requires the shim to bind exactly that set, so an unbound
|
|
2452
|
+
slot or an orphan binding is caught mechanically rather than by review.
|