Skip to content

fix(rex): S-4 cap in decide() records its reason (FALSIFY-RXG-008) - #5415

Merged
noahgift merged 1 commit into
mainfrom
84/rex-s4-reason-recut
Oct 16, 2026
Merged

noahgift merged 1 commit into
mainfrom
84/rex-s4-reason-recut

Conversation

@noahgift

Copy link
Copy Markdown
Contributor

What

decide() in aprender-review-experiment caps a lane at Tripwire when its primary cell is devbox or unnamed (S-4), but recorded no reason for the cap. It now pushes one S-4: reason, so the decision log says why the lane dropped. A reason already present from evidence() is not duplicated.

Why

Follow-up to the review finding on #5393: a capped lane produced a mode change with an empty reason trail.

Falsification

FALSIFY-RXG-008 (ladder_tests.rs) asserts exactly one S-4: reason for vote and tie-breaker lanes. It goes red with the fix reverted.

Verification

  • cargo test -p aprender-review-experiment --lib: 234 passed
  • clippy -D warnings and cargo fmt --all -- --check: clean

Refs #4354
keep-open: #4354 stays open, this is one step of its work.

🤖 Generated with Claude Code

decide() capped a devbox or unnamed-primary lane above tripwire at
Tripwire without adding a reason when the report alone was below
tripwire, so the Decision said Tripwire while its reasons explained
shadow. The S-4 branch now pushes one "S-4:" reason unless capped()
already did. RXG-008 asserts exactly one S-4 reason for vote and
tie-breaker lanes on a shadow report and on a full one. It goes red
with the fix reverted.

Follow-up to the C314 refusal on #5393.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@noahgift noahgift left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seat 2, aprender-seat-s12 @9852b061a5 APPROVE (no blocking finding)

Read-only review of the one Opus-authored commit (trailer Claude Opus 5.5), 2 files: ladder.rs +6, ladder_tests.rs +11.

  • Before the change, decide()'s S-4 cap path (devbox or unnamed primary, current > Tripwire) set mode to Tripwire and returned, without recording a reason when the report alone was already at or below Tripwire. Only capped() pushes "S-4:", and only when its own mode is above Tripwire. The patch adds the reason in decide() guarded by !reasons.any(starts_with "S-4:"), so the capped() case is not double-counted.
  • d is already mut. Mode derives Debug, so the {current:?} and {:?} format args compile. The mode is read before it is overwritten, so the text reports the report-alone mode.
  • Tests: the loop over Vote and TieBreaker on the devbox_h4_fail fixture (report alone = Shadow) asserts Tripwire plus exactly one "S-4:" reason. The devbox fixture at Vote asserts exactly one, which pins the dedupe where capped() already pushed. Both directions of the count are covered.
  • Not run locally: no isolated build of the PR head here. CI shards (workspace-test-shard 1-3, x86-main) were still pending when I read them, so the tests' pass state rests on CI.

@github-actions

Copy link
Copy Markdown

§13.11 rung 1 — quorum shadow verdict

S13-SHADOW pr=5415 head=9852b061a561f0e475dc2aba0c0cffdf49cf070b verdict=REFUSE class=Q1 arm_rc=1

Shadow mode: this records a verdict and merges nothing. A refusal
to arm is not a block (§13 adds zero rows to §7) — the pull request is
exactly as green as it was.

@noahgift noahgift left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seat 1, aprender-seat-s11 @9852b061a5 APPROVE (no blocking finding)

Read the 2-file diff and ran cargo test -p aprender-review-experiment --lib ladder in a throwaway worktree at 9852b06 (removed after the run): 10 passed, 0 failed, including falsify_rxg_008. I did not open the C314 receipt.

  • The early-return S-4 branch in decide() now records its reason. It only adds an "S-4:" reason when capped() did not already add one, so the reason appears exactly once. The mode result is unchanged: still Tripwire, same early return.
  • Tests: Vote and TieBreaker lanes on a devbox report whose own verdict is Shadow are capped at Tripwire with exactly one "S-4:" reason. The plain devbox report on a Vote lane also shows exactly one S-4 reason, which covers the path where capped() already pushed it.

Non-blocking: when the report alone says Shadow, the capped lane moves up to Tripwire. That predates this PR, and the new reason text states it ("the report alone gives Shadow").

@noahgift
noahgift added this pull request to the merge queue Oct 16, 2026
Merged via the queue into main with commit 79d2b05 Oct 16, 2026
12 checks passed
@noahgift
noahgift deleted the 84/rex-s4-reason-recut branch October 16, 2026 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant