Part of #6655, Phase F (automatic failure loop). Stacked on #6671, which adds `specs/verified/reuse.t27`. ## Goal Make the failure loop deterministic: - the base priority level a failure issue is filed at; - what makes a failure issue runnable by the Queen; - what a fix PR must reference; - when the loop may close. ## Where we are - `specs/verified/reuse.t27` (#6671) has the fingerprint, `on_failure` (open or update) and `on_fix_run` (close only on a passing, sealed, non-recurring run). - `specs/queen/priority.t27` has the levels, the critical cap and aging. - Nothing decides a failure's level, requires a fix PR to link back, or requires the same pipeline to be re-run. ## Boundary - New file `specs/verified/failure_loop.t27` plus its seal. It imports `verified::reuse` and mirrors the priority.t27 level values. - No occurrence thresholds, no restated cap or aging, no non-t27 code. ## User Scenarios & Testing - A failure on the default branch: CRITICAL. A fingerprint that recurred after its issue was closed: HIGH. Anything else: NORMAL. - A failure issue missing its Boundary, Success Criteria or fingerprint is not runnable. - A fix PR that does not reference both the failure issue and the original change is not linked. - Unlinked fix or a different pipeline: the issue stays open (KEEP). A recurring fingerprint: UPDATE. Linked + same pipeline + passed + sealed: CLOSE. ## Requirements - `failure_level(on_default_branch, recurred_after_close) -> u8` - `runnable(has_boundary, has_criteria, has_fingerprint) -> bool` - `fix_linked(refs_failure_issue, refs_original_change) -> bool` - `close_action(linked, same_pipeline, passed, seal_verified, recurred) -> u8`, delegating to `reuse.on_fix_run` ## Success Criteria - `t27c gen specs/verified/failure_loop.t27 > x.zig && zig test x.zig`: 10/10. - Every guard has a mutant that the tests kill. - `t27c seal --verify`: `all hashes MATCH`. - gen-verilog and gen-c succeed.
Activity