<?xml version="1.0" encoding="utf-8"?>
<entry xmlns="http://www.w3.org/2005/Atom" xml:base="https://docs.spec-kitty.ai/adr/3.x/2026-09-19-1-terminus-safety-invariant/">
  <id>https://docs.spec-kitty.ai/adr/3.x/2026-09-19-1-terminus-safety-invariant/</id>
  <title>ADR: Terminus-Safety Invariant — gate-then-mutate-with-rollback across merge, accept, and mission close</title>
  <updated>2026-11-06T00:00:00.000Z</updated>
  <author><name>Spec Kitty</name></author>
  <link rel="alternate" type="text/html" href="https://docs.spec-kitty.ai/adr/3.x/2026-09-19-1-terminus-safety-invariant/"/>
  <summary>Terminus-safety invariant: completion commands gate-then-mutate with rollback on failure, enforced by one shared terminal-readiness authority.</summary>
  <content type="html">&lt;h2 id=&quot;context-and-problem-statement&quot;&gt;Context and Problem Statement&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Operator-ratified (agentic-framework-core-team, Stijn Dejongh, 2026-09-19)&lt;/strong&gt; for the
milestone-#11 Slice C mission &lt;code dir=&quot;auto&quot;&gt;terminus-safety-invariant&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;01M2XFT756GZDJR08HS1QZ1XJY&lt;/code&gt;),
parented under epic &lt;a href=&quot;https://github.com/spec-kitty/spec-kitty/issues/3897&quot;&gt;#3897&lt;/a&gt;.
Decisions D1–D3 were made by the operator via a scope-fork question before the spec;
D4–D5 are consequent design decisions made under that mandate and flagged for veto.
Mechanism claims carry &lt;code dir=&quot;auto&quot;&gt;file:line&lt;/code&gt; verified at HEAD &lt;code dir=&quot;auto&quot;&gt;207bbc1307&lt;/code&gt; (v4.0.0rc4); the
implementing WPs re-verify exact lines as &lt;code dir=&quot;auto&quot;&gt;main&lt;/code&gt; advances.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Spec Kitty’s completion commands — &lt;code dir=&quot;auto&quot;&gt;spec-kitty merge&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;spec-kitty accept&lt;/code&gt;, and
&lt;code dir=&quot;auto&quot;&gt;spec-kitty mission close&lt;/code&gt; — share a latent &lt;strong&gt;defect class&lt;/strong&gt;, not four independent bugs:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;A completion/terminus command mutates (or destroys) durable mission state &lt;strong&gt;past a
precondition it never hard-enforced&lt;/strong&gt;, and when a later step fails there is &lt;strong&gt;no
rollback&lt;/strong&gt; — leaving the mission wedged, split-brain, or falsely completed.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Four issues are the same shape:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;#4764 (anchor)&lt;/strong&gt; — with the default &lt;code dir=&quot;auto&quot;&gt;policy.merge_gates.mode: warn&lt;/code&gt;, a missing-approval
gate is emitted as a &lt;em&gt;non-blocking warning&lt;/em&gt; (&lt;code dir=&quot;auto&quot;&gt;policy/merge_gates.py:121&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;is_blocking = mode==&quot;block&quot;&lt;/code&gt;; &lt;code dir=&quot;auto&quot;&gt;overall_pass&lt;/code&gt; at &lt;code dir=&quot;auto&quot;&gt;:53-54&lt;/code&gt;), so the stop at &lt;code dir=&quot;auto&quot;&gt;merge/executor.py:380-382&lt;/code&gt;
never fires. Merge then consolidates the lane (&lt;code dir=&quot;auto&quot;&gt;_phase_merge_lanes&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;executor.py:1816&lt;/code&gt;
→ &lt;code dir=&quot;auto&quot;&gt;consolidate_lane_into_mission&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;:443&lt;/code&gt;) and bakes &lt;code dir=&quot;auto&quot;&gt;mission_number&lt;/code&gt; into the coordination
&lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;_bake_mission_number_into_mission_branch&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;:506&lt;/code&gt; → &lt;code dir=&quot;auto&quot;&gt;ordering.py:463/485&lt;/code&gt;)
&lt;strong&gt;before&lt;/strong&gt; the post-merge backstop discovers no approval and exits 1
(&lt;code dir=&quot;auto&quot;&gt;done_bookkeeping.py:392&lt;/code&gt;→&lt;code dir=&quot;auto&quot;&gt;:497-503&lt;/code&gt;) with no rollback. The lane is left with 0 commits
beyond coordination, so the &lt;code dir=&quot;auto&quot;&gt;for_review&lt;/code&gt; gate rejects it forever; coordination vs primary
&lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; split-brain on &lt;code dir=&quot;auto&quot;&gt;mission_number&lt;/code&gt;; unreviewed code is now on the mission branch
a later squash carries to the mainline.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;#4765 (anchor)&lt;/strong&gt; — &lt;code dir=&quot;auto&quot;&gt;mission close&lt;/code&gt; (non-discard, &lt;code dir=&quot;auto&quot;&gt;mission_type.py:639-645&lt;/code&gt;) tears down
the coordination worktree and commits a &lt;code dir=&quot;auto&quot;&gt;runtime_post_completion&lt;/code&gt; retrospective to the
mainline with &lt;strong&gt;no&lt;/strong&gt; merged/terminal precondition, contradicting its own &lt;code dir=&quot;auto&quot;&gt;--help&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;:514&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;#4474 (fold)&lt;/strong&gt; — the &lt;code dir=&quot;auto&quot;&gt;mission_number&lt;/code&gt; bake fail-opens on the coordination path (the exact
bake step #4764 also mutates).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;#2745 (fold)&lt;/strong&gt; — the general statement of terminus half-termination across merge + accept
&lt;ul&gt;
&lt;li&gt;mission-close, including the direct-on-target fallback path.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;A point fix on any one reopens the others, and each command today computes “is this mission
terminally ready” a &lt;em&gt;different&lt;/em&gt; way (an evidence-gate loop, an acceptance matrix, a
reopen-style completion reader, and ~9 hand-inlined &lt;code dir=&quot;auto&quot;&gt;is_acceptable_ending&lt;/code&gt; loops). So this is
one ADR, one invariant, one shared authority — not four patches.&lt;/p&gt;
&lt;h2 id=&quot;decision&quot;&gt;Decision&lt;/h2&gt;
&lt;h3 id=&quot;d1--scope-one-cross-cutting-invariant-operator&quot;&gt;D1 — Scope: one cross-cutting invariant (operator)&lt;/h3&gt;
&lt;p&gt;Establish a single &lt;strong&gt;terminus-safety invariant&lt;/strong&gt;: every completion command must
&lt;strong&gt;gate-then-mutate-with-rollback&lt;/strong&gt;. Fold #4764 + #4765 + #4474 + #2745 into one mission
rather than shipping isolated point-fixes. Sibling clusters (merge cleanup/abort
#4753/#4754/#4762; finalize-tasks #4075/#4758/#3874; &lt;code dir=&quot;auto&quot;&gt;next&lt;/code&gt; FSM #4161; view-consistency
#3967) stay separate.&lt;/p&gt;
&lt;h3 id=&quot;d2--warn-softens-evidence-quality-only-operator&quot;&gt;D2 — &lt;code dir=&quot;auto&quot;&gt;warn&lt;/code&gt; softens evidence-quality only (operator)&lt;/h3&gt;
&lt;p&gt;&lt;code dir=&quot;auto&quot;&gt;policy.merge_gates.mode: warn&lt;/code&gt; softens &lt;strong&gt;evidence-quality&lt;/strong&gt; gates only (review verdict,
risk, hollow-review). The &lt;strong&gt;terminal-lane invariant&lt;/strong&gt; — “every non-cancelled work package is
at an acceptable ending (approved/done)” — is enforced &lt;strong&gt;HARD regardless of mode&lt;/strong&gt;.
Consequence: merge gets an &lt;strong&gt;unconditional merge-ready precondition&lt;/strong&gt; placed &lt;em&gt;before&lt;/em&gt; lane
consolidation, hoisted out of the mode-softened evidence gate — &lt;strong&gt;not&lt;/strong&gt; a rollback-only fix
that would keep the fail-open and merely make it recoverable.&lt;/p&gt;
&lt;h3 id=&quot;d3--parent-under-epic-3897-operator&quot;&gt;D3 — Parent under epic #3897 (operator)&lt;/h3&gt;
&lt;p&gt;Parent the mission under epic #3897 (Mission-lifecycle robustness — preflight +
abandon/clean-partial), whose charter already owns “preflight before mutating” and “failed
attempts left mission in debris”. (#2745 keeps its existing epic #1795 lane-mechanics parent;
it is folded for the fix, not reparented.)&lt;/p&gt;
&lt;h3 id=&quot;d4--per-command-predicates-through-one-shared-authority-agent-flagged-for-veto&quot;&gt;D4 — Per-command predicates through one shared authority (agent; flagged for veto)&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;Reject&lt;/strong&gt; reusing a single &lt;code dir=&quot;auto&quot;&gt;is_mission_completed&lt;/code&gt; predicate across all three commands. It is
semantically wrong in opposite directions: it returns &lt;strong&gt;False&lt;/strong&gt; for a normal merge-ready
mission (merge is what bakes &lt;code dir=&quot;auto&quot;&gt;approved&lt;/code&gt;→&lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt;; pre-merge WPs are &lt;code dir=&quot;auto&quot;&gt;approved&lt;/code&gt;, not &lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt;) so
it would &lt;em&gt;false-block every ordinary merge&lt;/em&gt;, and it short-circuits &lt;strong&gt;True&lt;/strong&gt; on &lt;code dir=&quot;auto&quot;&gt;merged_at&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;status/lifecycle.py:344&lt;/code&gt;) so on &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; (baseline stamped mid-flight,
&lt;code dir=&quot;auto&quot;&gt;executor.py:960&lt;/code&gt;→&lt;code dir=&quot;auto&quot;&gt;baseline.py:199&lt;/code&gt;) it would &lt;em&gt;pass vacuously&lt;/em&gt;. Instead:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;merge&lt;/strong&gt; → a &lt;strong&gt;merge-ready&lt;/strong&gt; predicate = every non-excluded WP ∈ {approved, done} ∪
acceptably-cancelled, evaluated &lt;strong&gt;unconditionally&lt;/strong&gt; (never routed through the mode-softened
gate).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;mission close&lt;/strong&gt; (non-discard) → &lt;strong&gt;&lt;code dir=&quot;auto&quot;&gt;is_mission_merged&lt;/code&gt;&lt;/strong&gt; (merged baseline present,
reopen-aware) — &lt;em&gt;not&lt;/em&gt; &lt;code dir=&quot;auto&quot;&gt;is_mission_completed&lt;/code&gt;. An all-terminal-but-&lt;strong&gt;unmerged&lt;/strong&gt; mission (e.g.
all-cancelled) must be abandoned via &lt;code dir=&quot;auto&quot;&gt;--discard&lt;/code&gt;, not torn down as a completion; this
matches the command’s &lt;code dir=&quot;auto&quot;&gt;--help&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;accept&lt;/strong&gt; → already gate-then-mutate (&lt;code dir=&quot;auto&quot;&gt;accept.py:991&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;if not summary.ok: raise Exit(1)&lt;/code&gt;,
all mutating writes strictly after) — the &lt;strong&gt;canonical precedent&lt;/strong&gt; the other two are brought
up to.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;All three route their terminal-readiness check through &lt;strong&gt;one shared authority&lt;/strong&gt; built on the
already-canonical per-lane reader &lt;code dir=&quot;auto&quot;&gt;status_lanes.is_acceptable_ending&lt;/code&gt; (+ &lt;code dir=&quot;auto&quot;&gt;has_operator_provenance&lt;/code&gt;)
and &lt;code dir=&quot;auto&quot;&gt;status_lanes.TERMINAL_LANES&lt;/code&gt;. The missing piece is a single aggregate
(“is every non-cancelled WP at an acceptable ending?”), added in the orchestration-free
&lt;code dir=&quot;auto&quot;&gt;status_lanes&lt;/code&gt; module — &lt;strong&gt;not&lt;/strong&gt; a 6th divergent definition. Adoption is scoped to
&lt;code dir=&quot;auto&quot;&gt;specify_cli&lt;/code&gt; in this mission; the runtime-side inline loops are &lt;strong&gt;not&lt;/strong&gt; rewired here.&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Placement caveat (post-review correction).&lt;/em&gt; &lt;code dir=&quot;auto&quot;&gt;status_lanes&lt;/code&gt; is a pure, I/O-free vocabulary
(stdlib-only imports) that today lives in the top &lt;code dir=&quot;auto&quot;&gt;specify_cli&lt;/code&gt; layer, so &lt;code dir=&quot;auto&quot;&gt;runtime&lt;/code&gt; already
reaches it &lt;strong&gt;upward&lt;/strong&gt; (&lt;code dir=&quot;auto&quot;&gt;runtime/next/committed_authority.py&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;runtime_bridge.py&lt;/code&gt;) through the
shrink-only &lt;code dir=&quot;auto&quot;&gt;runtime → specify_cli&lt;/code&gt; ledger. That top-layer placement is the &lt;em&gt;cause&lt;/em&gt; of the
ledger entry, not a reason to leave it alone: relocating this leaf vocabulary to a lower shared
layer (&lt;code dir=&quot;auto&quot;&gt;kernel&lt;/code&gt;/&lt;code dir=&quot;auto&quot;&gt;mission_runtime&lt;/code&gt;) is the direction that lets both &lt;code dir=&quot;auto&quot;&gt;runtime&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;specify_cli&lt;/code&gt;
depend on it &lt;strong&gt;downward&lt;/strong&gt; and would &lt;em&gt;shrink&lt;/em&gt; the ledger. The relocation is deliberately out of
scope for this safety mission (it touches the &lt;code dir=&quot;auto&quot;&gt;runtime&lt;/code&gt; layer) and is named as future-architecture
debt rather than justified away by an inverted ledger argument.&lt;/p&gt;
&lt;h3 id=&quot;d5--direct-on-target-rollback-scoping-agent-flagged-for-veto&quot;&gt;D5 — Direct-on-target rollback scoping (agent; flagged for veto)&lt;/h3&gt;
&lt;p&gt;The invariant has two halves. The &lt;strong&gt;abort-before-mutation precondition&lt;/strong&gt; (D2/D4) closes
#4764, #4765, #4474 and the entry points of #2745, and is fully in scope. The
&lt;strong&gt;rollback-after-target-advance on the direct-on-target path&lt;/strong&gt; (SINGLE_BRANCH / LANES-without-coord;
done is marked &lt;em&gt;after&lt;/em&gt; the target ref advanced, &lt;code dir=&quot;auto&quot;&gt;executor.py:971-985&lt;/code&gt;) is a &lt;strong&gt;distinct, harder
seam with no existing machinery&lt;/strong&gt; — the rollback scope must include the target ref
(&lt;code dir=&quot;auto&quot;&gt;ordering.py:485&lt;/code&gt;), not just the coordination ref. It is planned as its own work package with
a red-first test; if it proves mission-sized, only that sub-part is deferred as a tracked
#3897 follow-up, with the direct-on-target path still made safe by a &lt;em&gt;refuse-before-advance&lt;/em&gt;
guard. Because the terminal precondition runs before the target ref advances, the &lt;strong&gt;unsafe&lt;/strong&gt;
interim — unreviewed code promoted to target, or a mission falsely recorded complete — is
unreachable. A &lt;em&gt;benign&lt;/em&gt; under-marked state (an approved mission whose target advanced but whose
&lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt;/bake bookkeeping did not finish) remains reachable but is resume-recoverable; full
target-ref rollback on this path is exactly the deferred #3897 seam. “Unreachable” is scoped to
the unsafe class, not to all half-completion.&lt;/p&gt;
&lt;h3 id=&quot;d6--fold-2745s-completion-affordances-operator-post-spec&quot;&gt;D6 — Fold #2745’s completion affordances (operator, post-spec)&lt;/h3&gt;
&lt;p&gt;The post-spec squad found #2745 is a 3-facet bundle: (1) direct-on-target half-termination
(safety); (1-affordance) no way to &lt;em&gt;complete&lt;/em&gt; a direct-on-target mission with no lane branch;
(2) &lt;code dir=&quot;auto&quot;&gt;accept&lt;/code&gt; guidance (appears already fixed — the protected-primary hard-reject was removed,
&lt;code dir=&quot;auto&quot;&gt;accept.py&lt;/code&gt;); (3) &lt;code dir=&quot;auto&quot;&gt;mission close&lt;/code&gt; chokes on an orphaned &lt;code dir=&quot;auto&quot;&gt;coordination_branch&lt;/code&gt; (doubled slug, no
&lt;code dir=&quot;auto&quot;&gt;--json&lt;/code&gt;). The operator ruled to fold the &lt;strong&gt;completion affordances&lt;/strong&gt; too, not just the safety
facet: add &lt;code dir=&quot;auto&quot;&gt;merge --skip-lanes&lt;/code&gt;/&lt;code dir=&quot;auto&quot;&gt;--no-lanes&lt;/code&gt; (a transactional completion path for direct-on-target
missions that still enforces the terminal precondition — no bypass), and fix mission-close orphan
tolerance / doubled-slug / &lt;code dir=&quot;auto&quot;&gt;--json&lt;/code&gt;. This mission therefore &lt;strong&gt;fully closes #2745&lt;/strong&gt;; facet-2 is a
liveness confirmation.&lt;/p&gt;
&lt;h3 id=&quot;d7--4474-gets-a-delivering-requirement-agent-post-spec-repair&quot;&gt;D7 — #4474 gets a delivering requirement (agent, post-spec repair)&lt;/h3&gt;
&lt;p&gt;#4474 was initially folded in name only: the merge-ready precondition (D2/D4) prevents baking a
&lt;em&gt;not&lt;/em&gt;-merge-ready mission, but #4474’s defect is a &lt;em&gt;merge-ready&lt;/em&gt; coord mission whose &lt;code dir=&quot;auto&quot;&gt;mission_number&lt;/code&gt;
bake reads meta.json from the mission-branch tree (&lt;code dir=&quot;auto&quot;&gt;merge/ordering.py:398-414&lt;/code&gt;) and &lt;strong&gt;fail-opens&lt;/strong&gt;
(&lt;code dir=&quot;auto&quot;&gt;return False&lt;/code&gt;, number lost, &lt;code dir=&quot;auto&quot;&gt;doctor&lt;/code&gt; stuck at &lt;code dir=&quot;auto&quot;&gt;pending&lt;/code&gt;) when it is absent there. That is the
opposite failure mode from #4764 (which bakes too early → split-brain). A distinct delivering
requirement (topology-aware write-back, or operator-visible surfacing of the unbaked field) closes
#4474’s real defect so its red-first test is genuinely green-after.&lt;/p&gt;
&lt;h3 id=&quot;transactional-rollback-unify-dont-fork&quot;&gt;Transactional rollback: unify, don’t fork&lt;/h3&gt;
&lt;p&gt;The coordination-path rollback &lt;strong&gt;unifies&lt;/strong&gt; the existing fragmentary machinery
(&lt;code dir=&quot;auto&quot;&gt;_capture_pre_target_coord_ref_sha&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;:553&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;_restore_and_guard_coord_coherence&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;:788&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;_revert_coord_done_commit&lt;/code&gt; &lt;code dir=&quot;auto&quot;&gt;:644&lt;/code&gt;) into one coord-transaction primitive with &lt;strong&gt;named
checkpoints&lt;/strong&gt; (a new &lt;em&gt;pre-mutation&lt;/em&gt; checkpoint captured before consolidation, plus the
existing &lt;em&gt;pre-done&lt;/em&gt; checkpoint), rather than adding a second capture/restore authority. The
rollback must run before worktree teardown and must keep committed coordination &lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt;
markers and worktree bytes mutually coherent so &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; reads a consistent state.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Guarantee framing (post-review correction).&lt;/strong&gt; The &lt;strong&gt;precondition&lt;/strong&gt; (D2/D4), not the rollback,
is the load-bearing guarantee that closes #4764: it runs before the first mutation regardless of
gate mode, so an unapproved mission never consolidates. The rollback is &lt;strong&gt;best-effort
defense-in-depth&lt;/strong&gt;, and its strength varies by path — atomic for a single-lane (or first-lane)
consolidation failure and for the mission→target step (coordination ref, target ref, and any
orphan &lt;code dir=&quot;auto&quot;&gt;mission_number&lt;/code&gt; bake all reset), but it &lt;strong&gt;degrades&lt;/strong&gt; to abort-and-mark-for-reconcile-heal
on a multi-lane &lt;em&gt;partial&lt;/em&gt; consolidation (a landed lane-merge commit cannot be &lt;code dir=&quot;auto&quot;&gt;git revert&lt;/code&gt;-ed
across a range without an explicit &lt;code dir=&quot;auto&quot;&gt;-m&lt;/code&gt;), and a consolidation-&lt;em&gt;success&lt;/em&gt;-then-later-failure leans
on &lt;code dir=&quot;auto&quot;&gt;_phase_merge_lanes&lt;/code&gt; resume-idempotency rather than a rewind. None of these degradations reopen
#4764 — the precondition does the closing — but the rollback should not be read as a peer atomic
transaction across the whole merge.&lt;/p&gt;
&lt;h3 id=&quot;amendment-2026-09-29--one-pre-mutation-snapshot-one-cas-rollback-authority-slice-10&quot;&gt;Amendment 2026-09-29 — one pre-mutation snapshot, one CAS rollback authority (slice 10)&lt;/h3&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Operator-ratified&lt;/strong&gt; in mission &lt;code dir=&quot;auto&quot;&gt;consolidation-claim-rollback-integrity-01M3PD1T&lt;/code&gt;
(Decision Moments &lt;code dir=&quot;auto&quot;&gt;01M3PD3NAECRSVPYZ6J5KWDTDW&lt;/code&gt; scope, &lt;code dir=&quot;auto&quot;&gt;01M3PD3VP1YTQ4D17HT96JA0T2&lt;/code&gt;
CAS ref restore, &lt;code dir=&quot;auto&quot;&gt;01M3PJWGGKTRT9W03MJHFV44Q2&lt;/code&gt; planning self-heal). Issues #5338, #5318,
#5332, #5296 under epic #5001.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The “unify, don’t fork” rule above is kept and extended; on the rollback path it is
&lt;strong&gt;superseded&lt;/strong&gt; in one respect — rollback is a compare-and-swap ref restore, not a forward
&lt;code dir=&quot;auto&quot;&gt;git revert&lt;/code&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;A1 — Refuse before the first mutation.&lt;/strong&gt; A claim that fails its integrity check
(explicit claim refusal, unresolved coordination surface, empty claim against a non-empty
manifest) exits non-zero in &lt;code dir=&quot;auto&quot;&gt;_capture_reconciliation_claim&lt;/code&gt;, inside the pre-mutation
fresh-record guard, using the same predicate the gate uses
(&lt;code dir=&quot;auto&quot;&gt;reconciliation.claim_integrity_refusal&lt;/code&gt;). A resume whose reconciliation already passed for
the current target tip is exempt (#5021).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A2 — One snapshot.&lt;/strong&gt; Before the first mutation the run persists
&lt;code dir=&quot;auto&quot;&gt;ConsolidationState.pre_mutation_refs&lt;/code&gt; (target, mission branch, coordination branch when
present, every lane branch). &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; never recaptures it; a snapshot first captured when an
older record (no snapshot) was resumed lists its live-captured entries in
&lt;code dir=&quot;auto&quot;&gt;resume_seeded_refs&lt;/code&gt;, and the report calls them “snapshot taken when this record was resumed”,
not pre-consolidation. &lt;strong&gt;Lane branches are report-only&lt;/strong&gt; (&lt;code dir=&quot;auto&quot;&gt;snapshot_lane_branches&lt;/code&gt;):
consolidation never moves them, so they are snapshotted for the report but never recorded and
never restored. After every mutating phase the run records &lt;code dir=&quot;auto&quot;&gt;post_mutation_refs&lt;/code&gt; — the
compare-and-swap expected value — &lt;strong&gt;only for the target/mission/coordination branches whose tip
changed during that phase&lt;/strong&gt; (entry tips captured before the phase), except when the phase
failed on a compare-and-swap refusal (&lt;code dir=&quot;auto&quot;&gt;RefAdvanceError&lt;/code&gt;/&lt;code dir=&quot;auto&quot;&gt;RefRestoreError&lt;/code&gt;: that tip belongs to
another actor). A &lt;code dir=&quot;auto&quot;&gt;RefResyncError&lt;/code&gt; (the CAS write succeeded, only a checkout resync failed) IS
recorded: the ref holds this run’s tip. Per attempt, &lt;code dir=&quot;auto&quot;&gt;restore_targets&lt;/code&gt; keeps an operator’s own
change made between attempts.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A3 — One rollback authority.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;consolidation/rollback.py::rollback_to_snapshot&lt;/code&gt; restores
each snapshotted branch only while it is still at this run’s recorded post tip, resyncs every
checkout of it (dirty-checked first, via the shared &lt;code dir=&quot;auto&quot;&gt;ref_advance._resync_checkouts&lt;/code&gt;), reports
per branch (restored / already at snapshot / lane kept / lane missing / NOT restored with
observed vs expected), and clears the bake/completed/passed bookkeeping only after a full
restore. A run-movable branch that moved with &lt;strong&gt;no&lt;/strong&gt; recorded post tip (a kill inside a phase
before its recorder ran) is NOT restored — never reported untouched — so &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; keeps the
record and exits 1. A &lt;strong&gt;missing&lt;/strong&gt; snapshotted branch never blocks the rest: a missing lane
branch is reported with a &lt;code dir=&quot;auto&quot;&gt;git branch &amp;#x3C;b&gt; &amp;#x3C;sha&gt;&lt;/code&gt; recreate hint; a missing target/mission/
coordination branch is NOT restored with the same hint. It is called by the gate/projection
wrapper in the driver and by &lt;code dir=&quot;auto&quot;&gt;consolidate --abort&lt;/code&gt; (before the record is cleared, under the
consolidation lock); an AST pin keeps the caller set closed. A landing verified by an earlier
attempt (anchor == live target tip) is never rolled back.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A4 — Truthful text.&lt;/strong&gt; Refusal and failure output is followed by the rollback report; no
message in these paths claims that nothing was mutated when a branch moved.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;A5 — No dependency self-heal onto the target checkout.&lt;/strong&gt; A planning-lane claim whose
repository root checkout is on the target branch waives code-lane ancestry instead of merging
code lanes there; the code reaches the target only through consolidation’s attribution window.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Remaining authorities (deprecated, retirement condition: routed through A3).&lt;/strong&gt;
&lt;code dir=&quot;auto&quot;&gt;_reset_coord_to_checkpoint&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;_revert_orphan_target_bake_commit&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;_rollback_target_after_failed_reconciliation&lt;/code&gt; (now a redundant backstop that the authority
reports as already-at-snapshot) and &lt;code dir=&quot;auto&quot;&gt;coordination/coherence.py::repair_coord_strand&lt;/code&gt;, plus the
other in-phase exits between the first mutation and the gate — tracked as #5385. Resume-side
residuals #5371 and #5372 are out of scope.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Residuals of A2/A3 (pre-PR squad, not closed here).&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;em&gt;Same-phase foreign commit.&lt;/em&gt; Recording compares tips at phase entry and exit, so a foreign
commit that lands on a run-movable branch inside the same phase, after this run’s own CAS
advance of that branch and before the phase’s recorder runs, is recorded as this run’s and a
later rollback restores over it. The window is one phase long.&lt;/li&gt;
&lt;li&gt;&lt;em&gt;Same-mission &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; racing a live run (F7).&lt;/em&gt; &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; takes the global consolidation lock
owner-gated by the mission id, which a live run of the SAME mission also holds; an abort issued
while that run is still mutating is not excluded by the lock. This is the pre-existing
owner-token scheme, unchanged by this amendment.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;follow-up-2026-09-30--every-post-mutation-exit-goes-through-a3-5385&quot;&gt;Follow-up 2026-09-30 — every post-mutation exit goes through A3 (#5385)&lt;/h3&gt;
&lt;p&gt;Mission &lt;code dir=&quot;auto&quot;&gt;single-rollback-authority-01M3RCP4&lt;/code&gt;, issue #5385. The A3 “remaining authorities” list
above is superseded by this follow-up.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;One door.&lt;/strong&gt; One &lt;code dir=&quot;auto&quot;&gt;try&lt;/code&gt; in &lt;code dir=&quot;auto&quot;&gt;_run_lane_based_consolidation_locked&lt;/code&gt; covers every phase from
&lt;code dir=&quot;auto&quot;&gt;_phase_merge_lanes&lt;/code&gt; through &lt;code dir=&quot;auto&quot;&gt;_phase_reconcile_before_teardown&lt;/code&gt;. A non-zero &lt;code dir=&quot;auto&quot;&gt;typer.Exit&lt;/code&gt;, any
exception, or an interrupt (&lt;code dir=&quot;auto&quot;&gt;BaseException&lt;/code&gt;) calls &lt;code dir=&quot;auto&quot;&gt;_report_rollback&lt;/code&gt; →
&lt;code dir=&quot;auto&quot;&gt;rollback_to_snapshot&lt;/code&gt;, then re-raises the original error. &lt;code dir=&quot;auto&quot;&gt;typer.Exit(0)&lt;/code&gt; passes through. If
the rollback itself fails, or is interrupted by a second Ctrl-C, it prints “Rollback could
not complete” and the original error still propagates. After a full rollback the merge record
claims no completed WPs and no bake.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Retired.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;_reset_coord_to_checkpoint&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;_revert_coord_done_commit&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;_rollback_to_pre_mutation_checkpoint&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;_revert_orphan_target_bake_commit&lt;/code&gt; and
&lt;code dir=&quot;auto&quot;&gt;_capture_pre_mutation_coord_checkpoint&lt;/code&gt; are deleted. &lt;code dir=&quot;auto&quot;&gt;_heal_pending_coord_reconcile&lt;/code&gt; runs
only at resume start. Remaining second restore paths: &lt;code dir=&quot;auto&quot;&gt;_rollback_target_after_failed_reconciliation&lt;/code&gt;
(the gate FAIL/REFUSE target CAS restore) and &lt;code dir=&quot;auto&quot;&gt;coordination/coherence.py::repair_coord_strand&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Pin.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;tests/consolidation/test_single_rollback_authority.py&lt;/code&gt; requires all 11 span phase
calls inside the door (whose reporting handlers end in a bare &lt;code dir=&quot;auto&quot;&gt;raise&lt;/code&gt;, and whose &lt;code dir=&quot;auto&quot;&gt;typer.Exit&lt;/code&gt;
handler reports only under an &lt;code dir=&quot;auto&quot;&gt;exit_code&lt;/code&gt; guard), forbids a &lt;code dir=&quot;auto&quot;&gt;revert&lt;/code&gt; argv in &lt;code dir=&quot;auto&quot;&gt;executor.py&lt;/code&gt;, and
forbids the retired names in &lt;code dir=&quot;auto&quot;&gt;src/&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Protected-target preflight.&lt;/strong&gt; Before any branch moves (pre-lock), consolidate refuses a
mission whose pending done bookkeeping the workflow mutation policy would refuse (for example
a LANES mission recorded for protected &lt;code dir=&quot;auto&quot;&gt;main&lt;/code&gt;), with the policy’s own code
&lt;code dir=&quot;auto&quot;&gt;PROTECTED_BRANCH_REFUSED&lt;/code&gt;, message and remedy. It reads the recorded meta target, not
&lt;code dir=&quot;auto&quot;&gt;--target&lt;/code&gt; (the retarget itself is judged separately since 2026-10-31, below); it applies only
while some WP still needs its done write (an all-done resume is not refused); it honours &lt;code dir=&quot;auto&quot;&gt;SPEC_KITTY_ALLOW_PROTECTED_BRANCH_COMMITS&lt;/code&gt;; &lt;code dir=&quot;auto&quot;&gt;--dry-run&lt;/code&gt; reports the same
code. It reuses the transaction’s own gate (&lt;code dir=&quot;auto&quot;&gt;BookkeepingTransaction.preflight_refusal&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;status_write_refusal&lt;/code&gt;), so there is no second protected-branch list. A
&lt;code dir=&quot;auto&quot;&gt;BookkeepingPolicyRefused&lt;/code&gt; that reaches the command layer is printed readably, exit 1. When
a merge record for the mission already exists (a &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt;, or a re-run after a crash), the
refusal does not claim that no branch moved; it names &lt;code dir=&quot;auto&quot;&gt;spec-kitty consolidate --abort&lt;/code&gt; to
restore what an earlier attempt moved. A mission the probe cannot resolve (unresolvable
context, unreadable &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt;) is an &lt;code dir=&quot;auto&quot;&gt;Error:&lt;/code&gt; line and exit 1, not a traceback.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;orchestrator-api.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt; has its own lane consolidation
path (&lt;code dir=&quot;auto&quot;&gt;_execute_lane_merge&lt;/code&gt;). It runs the same preflight before any gate or merge, on both its
code-lane path and its planning-artifact-only closeout, and puts the policy’s code, message
and next step in its failure envelope.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residuals (named, not closed).&lt;/strong&gt;
&lt;ul&gt;
&lt;li&gt;A &lt;code dir=&quot;auto&quot;&gt;BookkeepingPolicyRefused&lt;/code&gt; can still escape unrendered from &lt;code dir=&quot;auto&quot;&gt;_record_operator_attestations&lt;/code&gt;
(inside the lock, before the snapshot, with &lt;code dir=&quot;auto&quot;&gt;--attest-*&lt;/code&gt;) and from post-gate phases.&lt;/li&gt;
&lt;li&gt;The orchestrator-api path has no rollback door: a failure the preflight does not foresee
(for example a legacy mission, which is not probed) still leaves its target advanced.&lt;/li&gt;
&lt;li&gt;Legacy missions are not probed by the preflight.&lt;/li&gt;
&lt;li&gt;A coord mission with a missing coord branch still fails closed after squashing (the door
rolls it back).&lt;/li&gt;
&lt;li&gt;A stale lane auto-rebased during lane consolidation keeps its merge commit after a rollback
(lanes are report-only).&lt;/li&gt;
&lt;li&gt;The resume-start heal is a forward revert that runs before the attempt; a later rollback
treats it as the restore floor.&lt;/li&gt;
&lt;li&gt;A checkout whose resync failed after its branch moved looks dirty and is reported NOT
restored.&lt;/li&gt;
&lt;li&gt;On a protected &lt;code dir=&quot;auto&quot;&gt;single_branch&lt;/code&gt; landing, the write checkout switched to the target stays there
after a rollback.&lt;/li&gt;
&lt;li&gt;Out of scope: #3536, #5371, #5372.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;follow-up-2026-10-04--presence-axis-status-write-guard-wider-lag-recovery-5613&quot;&gt;Follow-up 2026-10-04 — presence axis, status-write guard, wider lag recovery (#5613)&lt;/h3&gt;
&lt;p&gt;Issue #5613, a hardening follow-up to #5569, #5570, #5571 and #5572. The rollback authority
is unchanged; this follow-up adds two refusals in front of it, widens the resume recovery and
names one teardown refusal.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Presence axis.&lt;/strong&gt; The reconciliation gate FAILs with &lt;code dir=&quot;auto&quot;&gt;APPROVED_CONTENT_MISSING&lt;/code&gt; and rolls
back through &lt;code dir=&quot;auto&quot;&gt;rollback_to_snapshot&lt;/code&gt; when an approved code lane’s own net change to a path is
not on the target, the target left that path alone since the lane was cut, and no later
approved lane built atop it superseded the path
(&lt;code dir=&quot;auto&quot;&gt;MergeOutcomeVerifier._approved_content_divergence&lt;/code&gt;). It is strategy-independent. The
typical cause is an operator who committed the staged deletions of a lagging checkout and
then resumed. A lane built atop another is judged against what it started from, so a target
that holds only the dependency’s state still reports the dependent lane’s change as dropped.
It does not judge a path the target also changed.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Status-write guard.&lt;/strong&gt; A coordination status write refuses before it writes
(&lt;code dir=&quot;auto&quot;&gt;coordination/status_surface_guard.py&lt;/code&gt;, called by &lt;code dir=&quot;auto&quot;&gt;BookkeepingTransaction&lt;/code&gt;):
&lt;code dir=&quot;auto&quot;&gt;COORD_STATUS_SURFACE_DIVERGED&lt;/code&gt; when the worktree’s &lt;code dir=&quot;auto&quot;&gt;status.events.jsonl&lt;/code&gt; lost events its
HEAD has committed, &lt;code dir=&quot;auto&quot;&gt;COORD_STATUS_SURFACE_UNREADABLE&lt;/code&gt; when the committed log is malformed,
repeats an event id or cannot be read. Extra uncommitted lines are tolerated.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Lag recovery.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;consolidate --resume&lt;/code&gt; recovers in place a coordination worktree, a mission
worktree and a lane worktree that provably only lags its own HEAD, as it already did for the
repository root checkout. Each is proven against its own entry in &lt;code dir=&quot;auto&quot;&gt;pre_mutation_refs&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;pre_mutation_coord_sha&lt;/code&gt; for the coordination worktree, &lt;code dir=&quot;auto&quot;&gt;pre_mutation_target_sha&lt;/code&gt; for the
root). A resume-only preflight leg refuses a dirty worktree on the mission branch only when a
lane remains to be consolidated or the worktree actually lags. A lag plus an operator edit in
a non-root worktree is never reset; it gets patch-based advice.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code dir=&quot;auto&quot;&gt;COORD_MOVED_AFTER_LANDING&lt;/code&gt;, exit 75.&lt;/strong&gt; When the coordination branch (or the mission branch
of a mission without coordination topology) moved after the landing was verified and the
compare-and-swap delete kept it, &lt;code dir=&quot;auto&quot;&gt;consolidate&lt;/code&gt; renders the code as a message suffix and exits
75. The landing is not rolled back. &lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt; reports the code in
&lt;code dir=&quot;auto&quot;&gt;data[&quot;teardown_error_code&quot;]&lt;/code&gt; under its unchanged &lt;code dir=&quot;auto&quot;&gt;PREFLIGHT_FAILED&lt;/code&gt; envelope.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Remaining second restore paths.&lt;/strong&gt; The list of the 2026-09-30 follow-up gains one entry:
resume recovery still performs a raw &lt;code dir=&quot;auto&quot;&gt;git reset --hard HEAD&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;_recover_behind_head_primary_on_resume&lt;/code&gt;), now on four checkout roles: repository root
checkout, coordination worktree, mission worktree and lane worktree.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residuals (named, not closed).&lt;/strong&gt;
&lt;ul&gt;
&lt;li&gt;&lt;del&gt;The rollback’s byte-restore leaves the coordination worktree’s status files dirty; the
status-write guard refuses on them, the rollback does not clean them.&lt;/del&gt; Closed by #5638:
&lt;code dir=&quot;auto&quot;&gt;rollback_to_snapshot&lt;/code&gt; brings the checkout of a coordination branch it leaves in place
back to that branch’s tip (&lt;code dir=&quot;auto&quot;&gt;ref_advance.resync_checkouts_to_tip&lt;/code&gt;, toolchain residue only);
the guard stays as the backstop. A non-residue edit in that checkout refuses the resync;
the report then names the change and the remedy (commit or stash it, re-run &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; or
&lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt;). Residue is &lt;code dir=&quot;auto&quot;&gt;is_toolchain_generated_churn&lt;/code&gt;, which counts
&lt;code dir=&quot;auto&quot;&gt;kitty-specs/*/status.events.jsonl&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;status.json&lt;/code&gt;: an uncommitted status-log line there
(for example from an interrupted write) is reset by the resync. Those bytes were already
overwritten by the rollback’s own byte-restore, so no operator-authored work is lost, but
the reset is silent. The predicate is unchanged.&lt;/li&gt;
&lt;li&gt;Lane-branch deletes still use &lt;code dir=&quot;auto&quot;&gt;git branch -D&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A corrupt &lt;code dir=&quot;auto&quot;&gt;state.json&lt;/code&gt; falls back to the generic dirty-checkout advice.&lt;/li&gt;
&lt;li&gt;The repository root checkout with a lag plus an operator edit keeps the stock “Commit,
stash, or revert” remedy.&lt;/li&gt;
&lt;li&gt;The presence axis does not judge (i) a path the target also changed since the lane was cut
(by design: that is a merge resolution, which the blob axes judge); (ii) two independent
lanes that changed the same path when the target holds one lane’s state; or (iii) a path an
independent sibling lane changed and then reverted, when the target holds that reverted
state. A whole lane that was dropped is still caught when at least one of its paths is
exclusive to it.&lt;/li&gt;
&lt;li&gt;Resume lag recovery does not recognise a pure lag when the interruption happens on the
second or later lane of a multi-lane merge. It refuses safely, but its patch advice is
wrong (#5643).&lt;/li&gt;
&lt;li&gt;Out of scope: legacy and foreign strand-marker refusal codes; unwrapped remediation
printing.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;follow-up-2026-10-05--the-record-is-the-only-rollback-anchor-5686--5666&quot;&gt;Follow-up 2026-10-05 — the record is the only rollback anchor (#5686 / #5666)&lt;/h3&gt;
&lt;p&gt;Mission &lt;code dir=&quot;auto&quot;&gt;rollback-anchor-authority-01M45VSA&lt;/code&gt;, issues #5686 and #5666, with the deadlock part of
#5687. Operator decision (2026-10-05): adopt a move when this run provably made it, refuse
otherwise, and let the operator release a branch explicitly. A3 is narrowed: every restore
target and every compare-and-swap expectation now comes from the persisted record, never from a
live tip the record cannot explain.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;One door for the gate (#5666).&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;_rollback_target_after_failed_reconciliation&lt;/code&gt; is deleted.
A reconciliation FAIL or REFUSE moves no ref itself; its &lt;code dir=&quot;auto&quot;&gt;typer.Exit(1)&lt;/code&gt; lands in the A3 door,
whose &lt;code dir=&quot;auto&quot;&gt;rollback_to_snapshot&lt;/code&gt; compare-and-swaps against the post tip this run recorded. A
commit another actor landed on top of the landing is kept and reported &lt;code dir=&quot;auto&quot;&gt;NOT restored ... moved by another actor&lt;/code&gt;, never discarded. The AST pin
(&lt;code dir=&quot;auto&quot;&gt;tests/consolidation/test_single_rollback_authority.py&lt;/code&gt;) now lists the helper among the
retired names and forbids any &lt;code dir=&quot;auto&quot;&gt;restore_branch_ref&lt;/code&gt; call in the consolidation executor family
outside &lt;code dir=&quot;auto&quot;&gt;consolidation/rollback.py&lt;/code&gt;, not only the resyncing ones.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Unsettled branches.&lt;/strong&gt; The record persists &lt;code dir=&quot;auto&quot;&gt;unsettled_refs&lt;/code&gt;. &lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; marks every
run-movable branch unsettled when it opens an attempt. A rollback outcome of restored, already
at snapshot or kept by operator settles a branch; a reconciliation PASS (after the squash
projection proof) settles the target. A &lt;code dir=&quot;auto&quot;&gt;NOT restored&lt;/code&gt; outcome leaves it unsettled, and so
does any exit without a rollback: an orderly exit does not settle a branch. This supersedes
the A2 rule “per attempt, &lt;code dir=&quot;auto&quot;&gt;restore_targets&lt;/code&gt; keeps an operator’s own change made between
attempts”: that rule now applies only to a settled branch. On an unsettled branch, a tip that
is neither its restore target nor this run’s effective post tip is &lt;em&gt;unexplained&lt;/em&gt;.
&lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; then returns it and changes nothing in the record. A restore target fixed by
an earlier attempt stays in force across later attempts.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Advance intents.&lt;/strong&gt; Inside the door’s span, &lt;code dir=&quot;auto&quot;&gt;advance_branch_ref&lt;/code&gt; and
&lt;code dir=&quot;auto&quot;&gt;advance_branch_ref_for_commit&lt;/code&gt; report &lt;code dir=&quot;auto&quot;&gt;(branch, old, new)&lt;/code&gt; to a sink installed with
&lt;code dir=&quot;auto&quot;&gt;git/ref_advance.py::reporting_advance_intents&lt;/code&gt;, after their precondition checks and before
the compare-and-swap write. The executor’s sink persists the pair in &lt;code dir=&quot;auto&quot;&gt;advance_intents&lt;/code&gt; as a
per-branch chain &lt;code dir=&quot;auto&quot;&gt;[base, new1, new2, ...]&lt;/code&gt;; a failed save fails the advance closed.
&lt;code dir=&quot;auto&quot;&gt;ref_advance&lt;/code&gt; stays plumbing and never imports consolidation state. A live tip in the chain
counts as this run’s post tip (it is &lt;em&gt;adopted&lt;/em&gt;) only when the chain’s base equals the tip the
record expected for that branch: the recorded post tip, else the restore target. The report
marks such a restore &lt;code dir=&quot;auto&quot;&gt;adopted interrupted advance&lt;/code&gt;. A phase recorder clears a moved branch’s
chain, whether it recorded the branch or rejected it; &lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; and a full restore clear
all chains.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Recorder taint (FR-011).&lt;/strong&gt; A phase recorder captures, per branch, the entry tip and the tip
the record expected at phase entry. It records a post tip only when the branch moved during
the phase and its entry tip was the expected tip (&lt;code dir=&quot;auto&quot;&gt;rollback.phase_records_branch&lt;/code&gt;). A foreign
commit that lands between two phases is therefore never recorded as this run’s, even when the
next phase commits on top of it. A nested recorder keeps its own entry expectations.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt;.&lt;/strong&gt; A re-run or &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; refuses with this code (exit 1) when a
branch is unexplained. A read-only pre-check in the executor runs before the operator
attestations and the coord-strand heal; &lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; in the claim refuses with the same
text for a branch this process moved after the pre-check without explaining it. The message
names each branch with its restore target and live SHA, says nothing was changed and the
record is kept, and offers only non-destructive remedies, in order: inspect
&lt;code dir=&quot;auto&quot;&gt;git log &amp;#x3C;target&gt;..&amp;#x3C;live&gt;&lt;/code&gt;; if the commits should not stay, move the branch by hand; to keep
them, &lt;code dir=&quot;auto&quot;&gt;consolidate --abort --release-branch&lt;/code&gt;, with a warning that a release keeps every listed
commit. A repeat refuses identically. This process’s own pre-claim moves (the operator
attestations, the coord-strand heal) are measured across those steps, on the one branch each
step writes (the status-surface branch for the attestations, the marker’s &lt;code dir=&quot;auto&quot;&gt;coord_ref&lt;/code&gt; for the
heal): that branch counts as moved by the step only when its tip changed across it, and the
claim accepts that only while the branch is still where the step left it. A commit another
actor lands after the pre-check on any other branch, or on the step’s branch after the step,
is judged like any other move. Exemptions: while the live target equals the anchor of an earlier
reconciliation PASS, neither check refuses the target or the coordination branch (FR-011
already forbids a rollback then, and a late coordination commit is landed by
&lt;code dir=&quot;auto&quot;&gt;_land_late_coordination_commits&lt;/code&gt; and compare-and-swap guarded by the teardown, so the #5570
&lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; finishes the teardown). The mission branch is not exempt: the teardown deletes a
mission branch without a coordination topology against its live tip, so an unexplained move
there still refuses. A heal that clears its &lt;code dir=&quot;auto&quot;&gt;pending_coord_reconcile&lt;/code&gt; marker settles the
coordination branch it names, and the pre-check leaves that branch to the heal.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The PASS anchor is the verified tip.&lt;/strong&gt; The gate reads the target tip before &lt;code dir=&quot;auto&quot;&gt;verify()&lt;/code&gt;. A
PASS over a target that moved during verification, or during the squash projection proof
(re-checked right before the anchor is written), refuses (exit 1) into the door, which keeps
the new commit (reported &lt;code dir=&quot;auto&quot;&gt;NOT restored&lt;/code&gt;). Otherwise the anchor is exactly that verified SHA,
persisted only after the squash projection proof passed. A rollback that restores the target
clears the anchor, even when another branch stays &lt;code dir=&quot;auto&quot;&gt;NOT restored&lt;/code&gt;. When a restore went to a
record restore target other than the snapshot, the report header and the &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; line say
“restored to the record’s restore targets”, not “pre-consolidation”.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code dir=&quot;auto&quot;&gt;--abort --release-branch &amp;#x3C;b&gt; --release-reason &quot;&amp;#x3C;why&gt;&quot;&lt;/code&gt;.&lt;/strong&gt; Repeatable. It binds a release to
the branch’s live tip, read under the abort’s lock, and saves it before the rollback runs. A
branch that would be &lt;code dir=&quot;auto&quot;&gt;NOT restored&lt;/code&gt; and still sits at the bound SHA is left untouched and
reported &lt;code dir=&quot;auto&quot;&gt;kept ... (released by operator: &amp;#x3C;reason&gt;; at &amp;#x3C;sha&gt;; may contain this consolidation&apos;s unverified changes)&lt;/code&gt;. Every other branch is restored as usual, and the record
clears only when every other branch is restored. A release never keeps a branch the authority
can restore, and it lapses when the branch moves. The success line names every kept branch
and says “restored” only when a branch was restored. &lt;code dir=&quot;auto&quot;&gt;RELEASE_BRANCH_INVALID&lt;/code&gt; (exit 2, nothing
changed) refuses &lt;code dir=&quot;auto&quot;&gt;--release-branch&lt;/code&gt; without &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; or without &lt;code dir=&quot;auto&quot;&gt;--release-reason&lt;/code&gt;, a branch
that is not one of the record’s run-movable branches (a lane branch, an unknown name), and a
branch that does not resolve to a commit.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Restore over a lagging checkout (FR-012).&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;restore_branch_ref&lt;/code&gt; accepts a checkout whose
index and tracked working tree already equal the restore target, which is what a kill between
&lt;code dir=&quot;auto&quot;&gt;update-ref&lt;/code&gt; and the checkout resync leaves; it does not reset that checkout, so a live
&lt;code dir=&quot;auto&quot;&gt;index.lock&lt;/code&gt; there cannot fail the restore. Untracked obstructions still refuse.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Atomic record.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;save_state&lt;/code&gt; writes &lt;code dir=&quot;auto&quot;&gt;state.json&lt;/code&gt; through &lt;code dir=&quot;auto&quot;&gt;kernel.atomic.atomic_write&lt;/code&gt;. A
record written before this follow-up loads with nothing unsettled, no intents and no
releases; a malformed &lt;code dir=&quot;auto&quot;&gt;unsettled_refs&lt;/code&gt; loads as every branch unsettled, a malformed intent map
as no proof.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Remaining second restore paths.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;coordination/coherence.py::repair_coord_strand&lt;/code&gt;, plus the
raw &lt;code dir=&quot;auto&quot;&gt;git reset --hard HEAD&lt;/code&gt; of resume recovery on four checkout roles (2026-10-04 follow-up).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residuals (named, not closed).&lt;/strong&gt;
&lt;ul&gt;
&lt;li&gt;The same-phase foreign commit of the A2/A3 residuals is unchanged.&lt;/li&gt;
&lt;li&gt;In-span moves that report no intent: a plain &lt;code dir=&quot;auto&quot;&gt;safe_commit&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;git/commit_helpers.py::_run_commit_capture_sha&lt;/code&gt;, for example the LANES done bookkeeping
commit on the target) and the primary-tree &lt;code dir=&quot;auto&quot;&gt;git commit&lt;/code&gt; in
&lt;code dir=&quot;auto&quot;&gt;consolidation/mission_number/bake.py&lt;/code&gt;. A kill right after one leaves an unprovable move,
which refuses with &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;No tool-mediated undo of an unprovable landing: the operator keeps it with a release or
moves the branch by hand (follow-up #5784).&lt;/li&gt;
&lt;li&gt;Resume recovery (&lt;code dir=&quot;auto&quot;&gt;_recover_behind_head_primary_on_resume&lt;/code&gt;) may reset a provably
behind-HEAD checkout to its HEAD before the &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt; refusal. That is a
checkout resync, not a ref move.&lt;/li&gt;
&lt;li&gt;Decided residual: the heal settle stays unguarded. A heal that clears its marker settles
the coordination branch it names, which preserves the #2786 resume recovery. That settle
can move this run’s own coordination or mission-branch content from before the strand’s
&lt;code dir=&quot;auto&quot;&gt;captured_sha&lt;/code&gt; into that branch’s restore target. That content reaches the target only
through the reconciliation-gated squash, so no unverified content ships. A guard that
settles only when &lt;code dir=&quot;auto&quot;&gt;captured_sha&lt;/code&gt; equals the restore target was evaluated and rejected: it
makes the #2786 resume refuse and breaks that recovery.&lt;/li&gt;
&lt;li&gt;When the only unexplained branch is the coordination branch a &lt;code dir=&quot;auto&quot;&gt;pending_coord_reconcile&lt;/code&gt;
marker names, the pre-check skips it, so a requested &lt;code dir=&quot;auto&quot;&gt;--attest-canceled-superseded&lt;/code&gt; status
commit can land before the claim refuses.&lt;/li&gt;
&lt;li&gt;After a PASS, this run’s own coordination-branch commits outside the span (teardown
bookkeeping) are not recorded; a resume after the target moves off the anchor refuses with
&lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A release saved by an &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; that then fails on another branch stays in the record; a
later plain &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; still honours it while the branch sits at the bound SHA.&lt;/li&gt;
&lt;li&gt;A killed run’s global merge lock is not reclaimed (unchanged).&lt;/li&gt;
&lt;li&gt;Closed (#5788): a released mission branch whose kept commit dropped a work package’s
approved code no longer ships at exit 0. The presence axis measures each approved code
lane’s content over its first-parent spine from the target’s pre-mutation tip (the base
the #5668 approved-bound check measures a lane’s own range from), less every commit the
mission branch already carries that the lane’s own base also reaches. The lane’s own base
is the lane head at its first governed claim (the closed world’s first anchor). So a lane
commit made after that claim and merged into the mission branch by an earlier attempt is
still judged, and the next consolidation refuses with &lt;code dir=&quot;auto&quot;&gt;APPROVED_CONTENT_MISSING&lt;/code&gt;; a
mission-branch commit made outside every lane before the lane was cut is never read as
the lane’s content (#5792 review). Without a readable first-claim stamp every carried
commit is dropped, the pre-#5788 reading. The fully-canceled lanes’ commits are subtracted
as measured from that same base. Residual: a lane the released mission branch already
carries never lands, even with its code intact, under either strategy, because the
authorship axes still measure from the mission-branch tip and find it attributable to no
approved WP (refused, fail closed: under squash by file attribution, under merge by the
closed world). Content committed on the mission branch outside every lane is refused the
same way. Measuring authorship from the target tip would attribute such commits to a lane;
that is a design decision left open.&lt;/li&gt;
&lt;li&gt;A foreign commit that lands on a step’s own branch inside that step’s window (the
status-surface branch during the operator attestations, the &lt;code dir=&quot;auto&quot;&gt;coord_ref&lt;/code&gt; during the heal)
and is still the tip at the claim is taken as this process’s own move. In a mission with no
coordination topology (&lt;code dir=&quot;auto&quot;&gt;single_branch&lt;/code&gt; / &lt;code dir=&quot;auto&quot;&gt;lanes&lt;/code&gt;) the status-surface branch &lt;em&gt;is&lt;/em&gt; the target,
so this window can fold a concurrent foreign commit on the target itself into the run’s own
move; it requires both an explicit &lt;code dir=&quot;auto&quot;&gt;--attest-*&lt;/code&gt; and a writer landing inside one &lt;code dir=&quot;auto&quot;&gt;safe_commit&lt;/code&gt;
window.&lt;/li&gt;
&lt;li&gt;A &lt;code dir=&quot;auto&quot;&gt;git pull&lt;/code&gt; (or any other commit) on an unsettled target after a hard kill makes the next
re-run or &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; refuse with &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt; until the operator releases or
moves that commit.&lt;/li&gt;
&lt;li&gt;&lt;code dir=&quot;auto&quot;&gt;orchestrator-api&lt;/code&gt;’s planning-closeout path reports these refusals as &lt;code dir=&quot;auto&quot;&gt;PREFLIGHT_FAILED&lt;/code&gt;
without the &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt; code.&lt;/li&gt;
&lt;li&gt;&lt;code dir=&quot;auto&quot;&gt;consolidate --dry-run&lt;/code&gt; does not forecast &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;A phase that started at an unexpected tip records no post tip for that branch (taint), so a
later gate FAIL reports the target &lt;code dir=&quot;auto&quot;&gt;NOT restored&lt;/code&gt; instead of restoring it. Safer by design:
the record cannot prove the content under the phase is this run’s.&lt;/li&gt;
&lt;li&gt;&lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; writes no bookkeeping on a resume whose unexplained rows a verified landing
exempts (it refuses nothing and records nothing new); harmless, since the resume only
finishes the teardown.&lt;/li&gt;
&lt;li&gt;Out of scope: #5372 (stale flags adopted from an auto-resumed record), the window-base half
of #5667 (C-003, PR #5724), #5638 (coordination status files dirty after a rollback),
#5048(a) (PASS-anchor re-arm), and the #5687 resume that re-bases its window after
&lt;code dir=&quot;auto&quot;&gt;git pull&lt;/code&gt; and then pushes.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;follow-up-2026-10-31--a-rollback-that-restored-everything-re-baselines-the-record-6770&quot;&gt;Follow-up 2026-10-31 — a rollback that restored everything re-baselines the record (#6770)&lt;/h3&gt;
&lt;p&gt;Issue #6770, PR #6867, a recurrence of #5667 on 4.0.0rc8. A reconciliation FAIL whose door restored
every branch left the record on disk. The next plain &lt;code dir=&quot;auto&quot;&gt;consolidate&lt;/code&gt; auto-resumed it and reused
attempt 1’s &lt;code dir=&quot;auto&quot;&gt;pre_mutation_target_sha&lt;/code&gt; as the window base, so commits landed on the target between
the attempts were offered as un-attributable and rolled back over, and a plain &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; refused
with “no post-mutation tip was recorded”.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Rule.&lt;/strong&gt; When &lt;code dir=&quot;auto&quot;&gt;RollbackReport.rebaselineable&lt;/code&gt; holds, the door calls
&lt;code dir=&quot;auto&quot;&gt;rollback.rebaseline_after_full_restore&lt;/code&gt;. &lt;strong&gt;Dropped:&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;pre_mutation_target_sha&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;pre_mutation_refs&lt;/code&gt; (the snapshot), &lt;code dir=&quot;auto&quot;&gt;restore_targets&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;post_mutation_refs&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;advance_intents&lt;/code&gt;,
the releases, &lt;code dir=&quot;auto&quot;&gt;snapshot_lane_branches&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;resume_seeded_refs&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;unsettled_refs&lt;/code&gt;, the PASS anchor
and the per-attempt progress. The next run or &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; recaptures from live tips. &lt;strong&gt;Kept:&lt;/strong&gt;
the record and its marker, &lt;code dir=&quot;auto&quot;&gt;wp_order&lt;/code&gt;, the strategy and cleanup flags.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Coordination anchor rule.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;pre_mutation_coord_sha&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;pre_mutation_coord_ref&lt;/code&gt; and
&lt;code dir=&quot;auto&quot;&gt;pre_interrupt_lane_tips&lt;/code&gt; stay only on a coordination topology, where they are the
reconciliation claim’s authorship base (#5001, #4982, #5051) and the H5 resume guard needs a tip
for every lane. When &lt;code dir=&quot;auto&quot;&gt;pre_mutation_coord_ref&lt;/code&gt; is unset or equals the target (LANES,
SINGLE_BRANCH), the “anchor” is a second copy of the dead attempt’s target tip and is dropped.
Lanes are report-only: one that moved during the failed attempt is accepted by the per-lane CAS
unless it diverged, which refuses closed.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;code dir=&quot;auto&quot;&gt;rebaselineable&lt;/code&gt; is stricter than &lt;code dir=&quot;auto&quot;&gt;fully_restored&lt;/code&gt;.&lt;/strong&gt; It also refuses &lt;code dir=&quot;auto&quot;&gt;KEPT_BY_OPERATOR&lt;/code&gt; (the
record is the only place that holds the release and its reason) and &lt;code dir=&quot;auto&quot;&gt;LANE_MISSING&lt;/code&gt; (the record
holds the last copy of the deleted lane’s snapshot SHA). An unsettled run-movable branch with
no recorded post tip that moved is &lt;code dir=&quot;auto&quot;&gt;NOT_RESTORED&lt;/code&gt;, so it never re-baselines.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Lock widening.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; took the global merge lock only for a record with a snapshot. A
snapshot-less record is now the normal post-failure shape, and one that still names
coordination state (anchor or &lt;code dir=&quot;auto&quot;&gt;pending_coord_reconcile&lt;/code&gt;) can tear the coordination worktree
and marker down, so that shape takes the lock too. A bare legacy record still does not.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residuals (named, not closed).&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;LANE_MISSING&lt;/code&gt; (a lane branch deleted mid-run) reaches the
door and blocks the re-baseline, so the #5667 shape persists for that Mission until &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt;.
&lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt; has no rollback door and never re-baselines. &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt;
tears down the coordination worktree only (never the branch) and takes no tip compare-and-swap,
so a coordination commit made after the rollback survives it.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;amendment-2026-11-06--what-the-late-teardown-window-proves-and-on-which-tip-7265&quot;&gt;Amendment 2026-11-06 — what the late teardown window proves, and on which tip (#7265)&lt;/h3&gt;
&lt;p&gt;Issues #7198 and #7199, design issue #7265, one pull request superseding PRs #7228 and #7226. The
late window (#5570, #6791, #6871) carried residual fixes one at a time. Operator decision
(2026-11-06): one statement for both run kinds, then the two fixes land together.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Tip.&lt;/strong&gt; The teardown reads the coordination tip ONCE (&lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;git rev-parse&lt;/code&gt; with the exit code
kept: exit 1 is a no-op, any other failure refuses with the triple kept). The projection and the
proof read &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt;, never the live branch name. A commit that lands after &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt; was read is not in the
window: its branch content is neither projected nor judged under a late-projection refusal kind.
The status union is the one exception by construction: it folds the coordination worktree’s
working-tree log, so events committed from inside that worktree after &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt; can be unioned onto the
target before the gate refuses. That is additive, and the next &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; proves them.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Base.&lt;/strong&gt; First run: &lt;code dir=&quot;auto&quot;&gt;coord_tip_after_projection&lt;/code&gt;, the anchor captured after the bookkeeping
phase. Resume: &lt;code dir=&quot;auto&quot;&gt;state.pre_mutation_coord_sha&lt;/code&gt;. The 2026-10-31 re-baseline (#6770) keeps that
anchor on a coordination topology and drops it where no coordination branch exists, so a resume
after a full restore still has its base. A first run with no anchor builds no window (#7121,
unchanged).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Proof.&lt;/strong&gt; Over the tree delta &lt;code dir=&quot;auto&quot;&gt;B → T&lt;/code&gt; of the Mission directory (plus the existing check for paths
outside it), against the TARGET REF’s committed blobs, never the working tree. Blob reads tell
absence from failure; a read failure refuses. Renames are judged as delete + add. Each changed
path gets exactly one disposition: &lt;strong&gt;landed&lt;/strong&gt; (byte-equal); &lt;strong&gt;landed by the union&lt;/strong&gt;
(&lt;code dir=&quot;auto&quot;&gt;status.events.jsonl&lt;/code&gt;: every event id at &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt; is in the target’s committed log, after the
canonical event union, which refuses one id with two payloads); &lt;strong&gt;derived&lt;/strong&gt; (&lt;code dir=&quot;auto&quot;&gt;status.json&lt;/code&gt;, only
while the target’s committed snapshot is the reduction of its committed log); &lt;strong&gt;carried by the
target’s copy&lt;/strong&gt; (a target-authored JSON document whose &lt;code dir=&quot;auto&quot;&gt;B → T&lt;/code&gt; delta is on the target, a removed
key absent); &lt;strong&gt;refused&lt;/strong&gt; (anything else, and a deletion the target still holds). No path in the
judged directory is exempt by filename.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Every directory of the Mission (#7271).&lt;/strong&gt; A bare-slug coordination Mission keeps its coordination
directory under the composed &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;slug&gt;-&amp;#x3C;mid8&gt;&lt;/code&gt; name (#5651), and the outside-directory check skips it as
the Mission’s own. The proof therefore judges every directory &lt;code dir=&quot;auto&quot;&gt;mission_dir_aliases&lt;/code&gt; returns, plus the
primary directory’s own name, mapping each path to the target’s copy. Not advancing the tip would not
protect such a commit: a short-circuited resume’s gate falls back to the live checkpoint.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Approval.&lt;/strong&gt; Only a fully proven &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt; becomes &lt;code dir=&quot;auto&quot;&gt;coord_tip_after_projection&lt;/code&gt;, on BOTH run kinds,
and only by a guarded read (the live ref still equals &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt;). The projection teardown gate and
the compare-and-swap branch delete anchor on that value, so a commit after &lt;code dir=&quot;auto&quot;&gt;T&lt;/code&gt; is never
approved: the gate refuses and keeps the triple. The resume advance (#7199) is sound only
because the proof exempts nothing it approves (#7198, #7271); that is why
the two land together.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Refusal and rollback.&lt;/strong&gt; An unproven path refuses with &lt;code dir=&quot;auto&quot;&gt;COORD_LATE_PROJECTION_REFUSED&lt;/code&gt; (exit 1),
one refusal kind per remedy (three added: &lt;code dir=&quot;auto&quot;&gt;STATUS_EVENTS_NOT_LANDED&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;STATUS_LOG_NOT_RECONCILABLE&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;NON_COORDINATION_RECORD_NOT_LANDED&lt;/code&gt;), and keeps the branch,
worktree and marker. It never rolls back: teardown runs after the gate PASS, the late projection
commit is additive and carried over the PASS anchor, and the next &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; re-proves it
idempotently. Teardown calls no restore path, so the single rollback authority stays the only one.
No CLI flag, exit code or error code is added.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Sequencing (epic #7276, operator rulings 2026-11-06).&lt;/strong&gt; This is slice S10 of the lane and
worktree hardening epic. The order inside the consolidation phase is: landing and the
reconciliation gate PASS, then this late window (projection, proof, guarded advance), then the
projection teardown gate and the compare-and-swap branch delete, both anchored on the approved
tip. Worktree and branch cleanup is the final step of the consolidation phase (ruling 6, slice S5
#7280). It runs after the late window, anchors on the tip this window approved, and does not wait
for the pull request to merge. &lt;code dir=&quot;auto&quot;&gt;doctor workspaces --prune&lt;/code&gt; stays the proof-based backstop. This
amendment adds no deletion of its own. Routing the existing teardown delete through the #7264
proof list and &lt;code dir=&quot;auto&quot;&gt;git/destructive_guard.py&lt;/code&gt; (ruling 7, slice S4) is left to S5. The proof reads
the resolved status surface only: the target ref’s committed log, and the coordination worktree’s
log the union folds. It reads no lane-branch status copy (ruling 3, slice S6 #7281; #6466,
#6884).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residuals (named, not closed).&lt;/strong&gt; #7300 (a first run loses a commit made between the target advancing and the anchor capture), #7121 (a first run with no anchor), #5460 (primary artifacts are judged, never
projected), #7201 (the retrospective commit’s target, PR #7233, separate).&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&quot;consequences&quot;&gt;Consequences&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Positive.&lt;/strong&gt; A default-config command can no longer wedge an in-flight mission or push
unreviewed code toward the mainline; &lt;code dir=&quot;auto&quot;&gt;mission close&lt;/code&gt; can no longer fabricate a completion
record; one authority means a future fix in one command cannot silently diverge from the
others. Closes the class, not the symptoms.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Cost / risk.&lt;/strong&gt; Merge now imports a status reader (via the &lt;code dir=&quot;auto&quot;&gt;specify_cli.status&lt;/code&gt; facade —
battery-only &lt;code dir=&quot;auto&quot;&gt;test_status_module_boundary&lt;/code&gt; gate); preconditions must raise &lt;code dir=&quot;auto&quot;&gt;typer.Exit(1)&lt;/code&gt;
in-executor to stay inside the fixed CLI error-translation chains (&lt;code dir=&quot;auto&quot;&gt;merge.py:545-554&lt;/code&gt;); a
new pre-merge coord reset interacts with the resume-coherence and split-brain revert tests
(&lt;code dir=&quot;auto&quot;&gt;test_issue_2711_*&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;test_issue_2786_*&lt;/code&gt;); new helpers/shifted lines may require an
arch-battery re-pin (os-detect exemption, dead-symbol allowlist) in the same PR.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;ATDD.&lt;/strong&gt; Each defect gets an issue-pinned &lt;code dir=&quot;auto&quot;&gt;@pytest.mark.regression&lt;/code&gt; test that is red
through the pre-existing CLI entry point before the fix and green after.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;follow-up-2026-10-31--the-branch-integration-target-is-judged-too-6464&quot;&gt;Follow-up 2026-10-31 — the branch-integration target is judged too (#6464)&lt;/h3&gt;
&lt;p&gt;Issue #6464, mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/protected-target-override-refusal-01M68JPV/&lt;/code&gt;. The 2026-09-30
follow-up left one residual above: the protected-target preflight reads the RECORDED target. The
branch-integration step, however, commits to the EFFECTIVE target (&lt;code dir=&quot;auto&quot;&gt;--target&lt;/code&gt; &gt; persisted record &gt;
&lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; &gt; repo default) — and it does so with a raw &lt;code dir=&quot;auto&quot;&gt;git commit&lt;/code&gt; in an ephemeral worktree
(&lt;code dir=&quot;auto&quot;&gt;lanes/consolidation.py::_merge_branch_into&lt;/code&gt; → &lt;code dir=&quot;auto&quot;&gt;conclude_in_progress_op&lt;/code&gt;), so the workflow mutation
policy that gates every status commit never saw it. &lt;code dir=&quot;auto&quot;&gt;spec-kitty consolidate --target main&lt;/code&gt; on a
mission recorded for &lt;code dir=&quot;auto&quot;&gt;develop&lt;/code&gt; therefore landed the squash on &lt;code dir=&quot;auto&quot;&gt;main&lt;/code&gt; and only unwound because the
next bookkeeping phase tripped &lt;code dir=&quot;auto&quot;&gt;SafeCommitHeadMismatch&lt;/code&gt; against the recorded target.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;One refusal for the retarget.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;consolidation/preflight.py::refuse_protected_target_override&lt;/code&gt;
returns the policy’s &lt;code dir=&quot;auto&quot;&gt;Refused&lt;/code&gt; when the effective target is NOT the recorded target and
&lt;code dir=&quot;auto&quot;&gt;ProtectionPolicy.is_protected&lt;/code&gt; says that branch is protected. It reuses the policy’s own decision
(&lt;code dir=&quot;auto&quot;&gt;resolve_for_mission&lt;/code&gt;, so the operator hatch and a mission-scoped &lt;code dir=&quot;auto&quot;&gt;commit_to_target&lt;/code&gt; apply exactly
as everywhere else) and the existing &lt;code dir=&quot;auto&quot;&gt;PROTECTED_BRANCH_REFUSED&lt;/code&gt; code; there is no new code, no
second protected-branch list and no GitHub branch-protection call.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Scope is the override, deliberately.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;#5385&lt;/code&gt; keeps the recorded-target decision, including the
landings it allows by design (a coordination-topology mission on &lt;code dir=&quot;auto&quot;&gt;main&lt;/code&gt;, an all-done mission, a
&lt;code dir=&quot;auto&quot;&gt;single_branch&lt;/code&gt; mission created with &lt;code dir=&quot;auto&quot;&gt;--commit-to-target&lt;/code&gt;). A run that restates the recorded target
with &lt;code dir=&quot;auto&quot;&gt;--target&lt;/code&gt; is not a retarget and is not refused. The guard runs AFTER the recorded-target probe
so that refusal’s pinned text is unchanged.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;All three entries.&lt;/strong&gt; Pre-lock in the CLI door
(&lt;code dir=&quot;auto&quot;&gt;entry_preflight._refuse_protected_target_override_or_continue&lt;/code&gt;, before the merge lock, so nothing
is written and the refusal points at &lt;code dir=&quot;auto&quot;&gt;consolidate --abort&lt;/code&gt; when an earlier attempt may have moved a
branch), in the &lt;code dir=&quot;auto&quot;&gt;--dry-run --json&lt;/code&gt; payload (&lt;code dir=&quot;auto&quot;&gt;forecast&lt;/code&gt;, same code and remedy) and in
&lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt;’s failure envelope.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Pin.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;tests/terminus/test_protected_target_preflight.py&lt;/code&gt; (real CLI, real git, plus the
in-bounds and operator-hatch controls on the same fixture) and
&lt;code dir=&quot;auto&quot;&gt;tests/orchestrator_api/test_consolidate_mission_protected_target.py&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Residual (named, not closed).&lt;/strong&gt; An override onto an UNPROTECTED branch other than the recorded
target is not refused: the squash lands there and the run then fails its &lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt; bookkeeping on the
checkout HEAD mismatch, rolling back through the one door. That is a coherence defect, not a
protection bypass, and it is out of this follow-up’s scope.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&quot;amendment-2026-11-17--a-retarget-is-a-recorded-run-mutation-inside-the-one-door-7692&quot;&gt;Amendment 2026-11-17 — a retarget is a recorded run mutation inside the one door (#7692)&lt;/h3&gt;
&lt;p&gt;Issue #7692, mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/consolidate-retarget-01M7M5JA/&lt;/code&gt;. #5783 (#7688) refuses a plain
&lt;code dir=&quot;auto&quot;&gt;--target&lt;/code&gt; whose recorded target cannot be written, with &lt;code dir=&quot;auto&quot;&gt;TARGET_OVERRIDE_RECORDED_TARGET_UNWRITABLE&lt;/code&gt;.
That left no way to move a Mission to a new target in one run. &lt;code dir=&quot;auto&quot;&gt;spec-kitty consolidate --target &amp;#x3C;b&gt; --retarget&lt;/code&gt; (with an optional &lt;code dir=&quot;auto&quot;&gt;--retarget-reason&lt;/code&gt;) makes &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; the recorded target, and every write
of the run follows it. Naming the recorded target again is not a retarget.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;The record.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; gets &lt;code dir=&quot;auto&quot;&gt;target_branch = &amp;#x3C;b&gt;&lt;/code&gt; and one &lt;code dir=&quot;auto&quot;&gt;retarget_history&lt;/code&gt; entry
(&lt;code dir=&quot;auto&quot;&gt;from&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;to&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;actor&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;at&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;reason&lt;/code&gt;), bounded by the shared &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; history cap. It is
committed on every branch whose tree carries the Mission’s &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;preflight_retarget.retarget_record_holders&lt;/code&gt;, the one owner of that rule): the Mission branch, which for
a default-topology Mission is its topic branch and is where the landing reads the record from,
and &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; when it carries the file, from the repository root checkout. &lt;code dir=&quot;auto&quot;&gt;lanes.json&lt;/code&gt; is not
rewritten. The commit is the run’s first mutation: &lt;code dir=&quot;auto&quot;&gt;phase_advance._phase_retarget_record&lt;/code&gt; runs
inside the rollback door and records its post tips like every other phase. The AST pin’s
&lt;code dir=&quot;auto&quot;&gt;_SPAN_PHASES&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;tests/consolidation/test_single_rollback_authority.py&lt;/code&gt;) gained it. No gate
allowlist was added. On a default-topology Mission the record commit is made on the topic
branch, and the default squash landing folds it in. &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; then shows no separate retarget
commit; &lt;code dir=&quot;auto&quot;&gt;retarget_history&lt;/code&gt; holds exactly one entry
(&lt;code dir=&quot;auto&quot;&gt;tests/integration/test_default_mission_consolidate_retarget.py&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The run record.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;ConsolidationState.retarget&lt;/code&gt; is &lt;code dir=&quot;auto&quot;&gt;{from, to, actor, at, reason, committed}&lt;/code&gt;.
It is created with the record, before the claim, with &lt;code dir=&quot;auto&quot;&gt;committed=False&lt;/code&gt;, and set to &lt;code dir=&quot;auto&quot;&gt;True&lt;/code&gt; right
after the &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; commits. A full-restore re-baseline (#6770) keeps it and sets
&lt;code dir=&quot;auto&quot;&gt;committed=False&lt;/code&gt;, so a bare &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; or a re-run applies it again. A loaded record with no
snapshot adopts a new retarget: its &lt;code dir=&quot;auto&quot;&gt;target_branch&lt;/code&gt; moves to &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; and the anchors that name the
old target are dropped (the target tip, a coordination anchor that is the old target, and the
reconciliation PASS anchor). A record with a snapshot never adopts one. &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; clears the
record and the retarget with it. While the record holds a retarget, a run whose target is not
the persisted &lt;code dir=&quot;auto&quot;&gt;to&lt;/code&gt; refuses with &lt;code dir=&quot;auto&quot;&gt;RETARGET_RESUME_MISMATCH&lt;/code&gt;, with or without &lt;code dir=&quot;auto&quot;&gt;--retarget&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;preflight_retarget.retarget_mode&lt;/code&gt;, read by the entry preflight and &lt;code dir=&quot;auto&quot;&gt;--dry-run&lt;/code&gt;). &lt;code dir=&quot;auto&quot;&gt;--target &amp;#x3C;old target&gt;&lt;/code&gt; is included: before the mission review it passed the entry preflight, and the locked
run then applied the persisted retarget anyway.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Undo.&lt;/strong&gt; The retarget commits are undone ONLY by the one rollback authority
(&lt;code dir=&quot;auto&quot;&gt;rollback.rollback_to_snapshot&lt;/code&gt;), which restores &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; and the Mission branch to their snapshot
tips. There is no second undo path. On a Mission without a coordination branch, the &lt;code dir=&quot;auto&quot;&gt;--attest-*&lt;/code&gt;
status events a retarget run records on &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; before the claim are part of the run (mission
review RISK-2): the executor marks that move as an undoable own move (&lt;code dir=&quot;auto&quot;&gt;rollback.OwnMove.undo&lt;/code&gt;),
the snapshot takes &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;’s tip from before the attestations (&lt;code dir=&quot;auto&quot;&gt;capture_pre_mutation_snapshot&lt;/code&gt;’s
&lt;code dir=&quot;auto&quot;&gt;seed&lt;/code&gt;), and &lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt; carries the attested tip as this run’s post tip. The move is also
persisted in the record’s &lt;code dir=&quot;auto&quot;&gt;retarget&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;attestation_undo&lt;/code&gt;) as soon as the record is loaded or
created, and the seeded snapshot records the attested tip as the post tip in the same save, so
after a SIGKILL before the snapshot or before &lt;code dir=&quot;auto&quot;&gt;begin_attempt&lt;/code&gt;, a &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt; or re-run that then
fails restores &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;, and so does &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; once the killed run had taken its snapshot (review
R2-a). A re-run that attests again continues the persisted move (its &lt;code dir=&quot;auto&quot;&gt;before&lt;/code&gt; is the persisted
&lt;code dir=&quot;auto&quot;&gt;after&lt;/code&gt;), so &lt;code dir=&quot;auto&quot;&gt;persist_attestation_undo&lt;/code&gt; chains it to the first attestation’s origin and both are
undone (re-review MEDIUM-1). A rollback or &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; leaves &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; at its pre-run tip,
and a re-run with the same &lt;code dir=&quot;auto&quot;&gt;--attest-*&lt;/code&gt; flags records the attestation once (a bare &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt;
records none and fails the same claim check). A plain run’s attestations still re-anchor and
survive, as before. Residuals: a claim-time refusal, which comes before the snapshot, still
keeps them (F4); a kill between the attestation commit and the record save (the review-artifact
gate in between is read-only) keeps them; &lt;code dir=&quot;auto&quot;&gt;--abort&lt;/code&gt; after a kill before the snapshot finds no
snapshot (&lt;code dir=&quot;auto&quot;&gt;_NO_SNAPSHOT_REASON&lt;/code&gt;), restores nothing and clears the record, so it keeps them too.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Status surface.&lt;/strong&gt; The claim’s status surface follows the effective target: on a retarget run
the old recorded target maps to &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;run_state&lt;/code&gt;, &lt;code dir=&quot;auto&quot;&gt;status_surface&lt;/code&gt;). The #5385 status-write
probe is re-pointed at &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;, never skipped. &lt;code dir=&quot;auto&quot;&gt;--attest-*&lt;/code&gt; flags follow the retarget too: on a
Mission without a coordination branch, their status events land on &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Refusals, all before any branch moves.&lt;/strong&gt; &lt;code dir=&quot;auto&quot;&gt;RETARGET_RECORD_UNWRITABLE&lt;/code&gt;: neither the Mission
branch nor &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; carries &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt;; or &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; carries it but the root checkout cannot take the
commit (not on &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;, or &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; untracked or dirty there); or &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; carries it and
&lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; carries the skip-worktree or assume-unchanged bit in the root checkout, even with no
edit (&lt;code dir=&quot;auto&quot;&gt;preflight._index_bit&lt;/code&gt;); or &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; does not carry it and the root checkout, on &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt;, holds
untracked &lt;code dir=&quot;auto&quot;&gt;kitty-specs/&amp;#x3C;slug&gt;/&lt;/code&gt; copies the landing would overwrite
(&lt;code dir=&quot;auto&quot;&gt;preflight._untracked_mission_copies_refusal&lt;/code&gt;).
&lt;code dir=&quot;auto&quot;&gt;RETARGET_WRITE_BRANCH_IS_RECORDED_TARGET&lt;/code&gt;: a commit-to-target &lt;code dir=&quot;auto&quot;&gt;single_branch&lt;/code&gt; Mission, whose
write branch is the recorded target; the run would land that branch and then delete it.
&lt;code dir=&quot;auto&quot;&gt;PROTECTED_BRANCH_REFUSED&lt;/code&gt;: &lt;code dir=&quot;auto&quot;&gt;&amp;#x3C;b&gt;&lt;/code&gt; is protected (#6464), or the re-pointed #5385 probe refuses.
&lt;code dir=&quot;auto&quot;&gt;RETARGET_RESUME_MISMATCH&lt;/code&gt; (above). A retarget away from a protected recorded target onto an
unprotected branch is admitted: the old target receives nothing. A plain &lt;code dir=&quot;auto&quot;&gt;--target&lt;/code&gt; keeps
&lt;code dir=&quot;auto&quot;&gt;TARGET_OVERRIDE_RECORDED_TARGET_UNWRITABLE&lt;/code&gt;; its next step now names &lt;code dir=&quot;auto&quot;&gt;--retarget&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Scope.&lt;/strong&gt; Explicit &lt;code dir=&quot;auto&quot;&gt;lanes&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;lanes_with_coord&lt;/code&gt; Missions, and default-topology Missions
settled to &lt;code dir=&quot;auto&quot;&gt;lanes_with_coord&lt;/code&gt; or &lt;code dir=&quot;auto&quot;&gt;single_branch&lt;/code&gt;. &lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt; cannot
retarget, because it has no rollback door (#7361). It keeps refusing a differing target with
&lt;code dir=&quot;auto&quot;&gt;PREFLIGHT_FAILED&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;TARGET_OVERRIDE_RECORDED_TARGET_UNWRITABLE&lt;/code&gt;. While the run record holds
a retarget, it refuses any target with &lt;code dir=&quot;auto&quot;&gt;PREFLIGHT_FAILED&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;RETARGET_RESUME_MISMATCH&lt;/code&gt;
(&lt;code dir=&quot;auto&quot;&gt;preflight_retarget.persisted_retarget_refusal&lt;/code&gt;), so it never finishes or overrides a retarget. &lt;code dir=&quot;auto&quot;&gt;CONTRACT_VERSION&lt;/code&gt; is
unchanged.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The kill window is not a residual.&lt;/strong&gt; The plan named a kill between the record commits and the
&lt;code dir=&quot;auto&quot;&gt;committed&lt;/code&gt; persist as a residual that would refuse with &lt;code dir=&quot;auto&quot;&gt;UNEXPLAINED_BRANCH_MOVE&lt;/code&gt;. The
end-to-end test does not confirm it. A hard kill at &lt;code dir=&quot;auto&quot;&gt;phase_advance._persist_retarget_committed&lt;/code&gt;,
then &lt;code dir=&quot;auto&quot;&gt;consolidate --resume&lt;/code&gt;, exits 0 and lands with exactly one record. The record commits ran
inside the door’s advance intents, so the resume adopts both moves, and the deduplicating record
write leaves both copies unchanged (&lt;code dir=&quot;auto&quot;&gt;tests/terminus/test_consolidate_retarget_resume.py&lt;/code&gt;). No
&lt;code dir=&quot;auto&quot;&gt;--release-branch&lt;/code&gt; is needed.&lt;/li&gt;
&lt;/ul&gt;
&lt;h4 id=&quot;follow-up-2026-11-17--a-skip-worktree-entry-the-run-writes-is-refused-up-front&quot;&gt;Follow-up 2026-11-17 — a skip-worktree entry the run writes is refused up front&lt;/h4&gt;
&lt;p&gt;Found while building the retarget refusals, on every &lt;code dir=&quot;auto&quot;&gt;consolidate&lt;/code&gt;, not only a retarget: with the
skip-worktree bit set (no edit) on the root checkout’s &lt;code dir=&quot;auto&quot;&gt;kitty-specs/&amp;#x3C;slug&gt;/meta.json&lt;/code&gt;, a plain run
landed, and the forward resync succeeded. The run’s own post-merge bookkeeping then wrote
&lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt; on disk, the bit left that write out of the commit (“No post-merge bookkeeping changes
to commit”), the baseline validation failed (&lt;code dir=&quot;auto&quot;&gt;baseline_merge_commit&lt;/code&gt; missing), and the rollback’s
resync back to the snapshot failed on the now-edited file (git refuses to reset the entry). The branch tips were
restored, but the root checkout’s index kept the landing and the merge record stayed. The resync
contract and the rollback authority are unchanged. Instead the run refuses before the lock and
before any snapshot, with &lt;code dir=&quot;auto&quot;&gt;CHECKOUT_SKIP_WORKTREE_ENTRIES&lt;/code&gt; (&lt;code dir=&quot;auto&quot;&gt;preflight_skip_worktree.skip_worktree_landing_refusal&lt;/code&gt;,
read by the entry preflight, &lt;code dir=&quot;auto&quot;&gt;--dry-run&lt;/code&gt; and &lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt;), when a
checkout holding the target or the Mission branch has an entry tagged &lt;code dir=&quot;auto&quot;&gt;S&lt;/code&gt; or &lt;code dir=&quot;auto&quot;&gt;s&lt;/code&gt; whose path is
present (&lt;code dir=&quot;auto&quot;&gt;lexists&lt;/code&gt;; never a sparse-checkout exclusion) under the Mission directory or on a path
the Mission and lane branches change. Refusing Mission-directory entries is the real fix. Entries
on changed code paths are refused conservatively: an edited skip-worktree file is invisible to
&lt;code dir=&quot;auto&quot;&gt;git status&lt;/code&gt; and the dirty-checkout gate, so the resync would overwrite or trip on it; an unedited
one would land and is refused anyway. An assume-unchanged bit alone landed fine and is not
refused; the retarget’s stricter rule for its record commit (&lt;code dir=&quot;auto&quot;&gt;RETARGET_RECORD_UNWRITABLE&lt;/code&gt;, either
bit) stays. &lt;code dir=&quot;auto&quot;&gt;orchestrator-api consolidate-mission&lt;/code&gt; never writes &lt;code dir=&quot;auto&quot;&gt;meta.json&lt;/code&gt;, so with the bit there
it landed cleanly, but with the bit on &lt;code dir=&quot;auto&quot;&gt;status.events.jsonl&lt;/code&gt; it landed and then crashed in its
&lt;code dir=&quot;auto&quot;&gt;done&lt;/code&gt; status commit with no rollback door; it now refuses with &lt;code dir=&quot;auto&quot;&gt;PREFLIGHT_FAILED&lt;/code&gt; and the same
&lt;code dir=&quot;auto&quot;&gt;data.preflight_error_code&lt;/code&gt;, and &lt;code dir=&quot;auto&quot;&gt;CONTRACT_VERSION&lt;/code&gt; moves to 1.29.0. The index listing expands a
sparse index in memory: &lt;code dir=&quot;auto&quot;&gt;ls-files --sparse&lt;/code&gt; needs git 2.35, above the supported floor
(&lt;code dir=&quot;auto&quot;&gt;tests/terminus/test_consolidate_skip_worktree_checkout.py&lt;/code&gt;,
&lt;code dir=&quot;auto&quot;&gt;tests/consolidation/test_skip_worktree_landing_refusal.py&lt;/code&gt;).&lt;/p&gt;
&lt;h2 id=&quot;alternatives-considered&quot;&gt;Alternatives Considered&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Two independent point-fixes for #4764 and #4765 only.&lt;/strong&gt; Rejected (D1): leaves #4474/#2745
and the broader non-transactional-completion tail open, and invites a future 6th “done”
definition.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Rollback-only fix for #4764 (treat warn as intentionally permitting unapproved merges).&lt;/strong&gt;
Rejected (D2): keeps the fail-open; unreviewed code still consolidates onto the mission
branch. The operator ruled the terminal-lane invariant is hard regardless of mode.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Single &lt;code dir=&quot;auto&quot;&gt;is_mission_completed&lt;/code&gt; predicate for all three commands.&lt;/strong&gt; Rejected (D4):
false-blocks normal merges and passes vacuously on &lt;code dir=&quot;auto&quot;&gt;--resume&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&quot;references&quot;&gt;References&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Issues: #4764, #4765, #4474, #2745; epic #3897 (parent), #1795 (#2745’s lane-mechanics epic).&lt;/li&gt;
&lt;li&gt;Amendment 2026-09-29: #5338, #5318, #5332, #5296 (epic #5001); mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/consolidation-claim-rollback-integrity-01M3PD1T/&lt;/code&gt;; residuals #5385, #5371, #5372.&lt;/li&gt;
&lt;li&gt;Follow-up 2026-09-30: #5385; mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/single-rollback-authority-01M3RCP4/&lt;/code&gt;; out-of-scope follow-ups #3536, #5371, #5372.&lt;/li&gt;
&lt;li&gt;Follow-up 2026-10-04: #5613 (hardening of #5569, #5570, #5571, #5572).&lt;/li&gt;
&lt;li&gt;Follow-up 2026-10-31: #6770 (PR #6867), a recurrence of #5667.&lt;/li&gt;
&lt;li&gt;Follow-up 2026-10-05: #5686, #5666, the deadlock part of #5687; mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/rollback-anchor-authority-01M45VSA/&lt;/code&gt;; out-of-scope follow-ups #5372, #5667, #5638, #5048, #5784.&lt;/li&gt;
&lt;li&gt;Follow-up 2026-10-31: #6464; mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/protected-target-override-refusal-01M68JPV/&lt;/code&gt;; residual: an override onto an unprotected non-recorded branch. Context-only: #3132 (PR-required delivery policy, not implemented here), #5100 (mission-scoped &lt;code dir=&quot;auto&quot;&gt;commit_to_target&lt;/code&gt;), #3080 (&lt;code dir=&quot;auto&quot;&gt;merge&lt;/code&gt; → &lt;code dir=&quot;auto&quot;&gt;consolidate&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Amendment 2026-11-06: #7265 (design, slice S10 of epic #7276), #7198, #7199; sequencing with #7280 (S5), #7264 (S4), #7281 (S6); supersedes PRs #7228 and #7226 (author Ivan-Melck); closes #7271; residuals #7300, #7121, #5460; separate: #7201 / PR #7233.&lt;/li&gt;
&lt;li&gt;Amendment 2026-11-17: #7692; mission &lt;code dir=&quot;auto&quot;&gt;kitty-specs/consolidate-retarget-01M7M5JA/&lt;/code&gt;; builds on #5783 (#7688) and #6464; orchestrator-api rollback door: #7361; kill window between the record commits and the &lt;code dir=&quot;auto&quot;&gt;committed&lt;/code&gt; persist: resumes once, &lt;code dir=&quot;auto&quot;&gt;tests/terminus/test_consolidate_retarget_resume.py&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Mission: &lt;code dir=&quot;auto&quot;&gt;kitty-specs/terminus-safety-invariant-01M2XFT7/spec.md&lt;/code&gt;; Decision Moments
&lt;code dir=&quot;auto&quot;&gt;01M2XFVSK8JCCXMXCJNTBB0X5V&lt;/code&gt; (scope), &lt;code dir=&quot;auto&quot;&gt;01M2XFW9B71WKJ4XPCDCH8VYCQ&lt;/code&gt; (warn semantics).&lt;/li&gt;
&lt;li&gt;Related (separate): #3967 (shared integration view, epic #3894), #4161 (&lt;code dir=&quot;auto&quot;&gt;next&lt;/code&gt; FSM),
#4474-adjacent cleanup cluster #4753/#4754/#4762.&lt;/li&gt;
&lt;li&gt;Charter: DIRECTIVE_040 (structural intervention on recurring bugs), DIRECTIVE_044 /
canonical-source-unification (single authority), DIRECTIVE_003 (decision documentation),
DIRECTIVE_043 (close defect classes by construction).&lt;/li&gt;
&lt;/ul&gt;</content>
</entry>
