pub const MAX_PHASE_VALIDATE_FAILURES: u32 = 10;Expand description
Ceiling for crate::state::State::phase_validate_failures — the total
number of Validate failures recorded for one PHASE, accumulated without
regard to forward progress (999.78/WR-01, D-07).
Why it sits meaningfully above MAX_CONSECUTIVE_FAILURES (3). This
is a backstop for the case where the streak keeps resetting, not a
competing primary bound. consecutive_failures is cleared whenever
consecutive_failures_made_progress reports new commits, and the Code
stage’s fix command is a GSD command that routinely commits .planning/
artifacts even when no source changed — so “commits something trivial
every cycle” is the ORDINARY behaviour of the thing in that slot. A phase
in that state never reaches the streak ceiling. Setting this one low
enough to compete would make the coarser signal primary and change when
ordinary, genuinely-converging runs gate; ten leaves the streak ceiling
the first thing a stuck loop meets, and catches only the loops the streak
ceiling structurally cannot.
Exhausting it fires a human gate and the run stays alive (D-07). It must never introduce an abort path: aborting is destructive and irreversible relative to gating, and a phase one cycle from converging would be killed by a bound whose only purpose is to summon a human.