Skip to content

fix(open-sse): reuse the verdict read once for a replayed shape refusal - #15737

Merged
diegosouzapw merged 1 commit into
diegosouzapw:release/v3.8.52from
maxmad64bis:fix/shape-replay-verdict-reread
Oct 8, 2026
Merged

diegosouzapw merged 1 commit into
diegosouzapw:release/v3.8.52from
maxmad64bis:fix/shape-replay-verdict-reread

Conversation

@maxmad64bis

@maxmad64bis maxmad64bis commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ base-red inherited: #15306

Summary

A replayed shape refusal is read twice before scoring: once to decide the replay and again inside the replay. The verdict read the first time now travels to the replay, so the refused body is read once and the same verdict reaches scoring.

Related Issues

  • No linked issue — double read reproduced on the release base

Validation

  • Change type: routing
  • Focused tests and category gates from the golden path
  • npm run lint
  • Reconciled with the current active release base; focused checks rerun afterward
  • Production-code changes include a new or updated automated test in this PR

Tests Added Or Updated

  • tests/unit/opencode-shape-replay-verdict-reread.test.ts — counts body reads on a replayed shape refusal: replay, second refusal, and unreadable body.

Coverage Notes

  • open-sse/executors/opencodeRequestShape.ts — covered by the new replay-verdict test (three cases) and the existing request-shape suites.
  • tests/unit/opencode-shape-replay-verdict-reread.test.ts — new test, covers the change directly.
  • changelog fragment — release note, no code to cover.

Reviewer Notes

  • Behavior: same verdict and same notation as before; a replayed refusal now reads the refused body once instead of twice (2 → 1 reads per replay).

@maxmad64bis
maxmad64bis marked this pull request as ready for review October 7, 2026 18:37
@maxmad64bis
maxmad64bis force-pushed the fix/shape-replay-verdict-reread branch from 0eb81c9 to 8dc5469 Compare October 7, 2026 18:42
@maxmad64bis
maxmad64bis marked this pull request as draft October 7, 2026 20:23
The replay reread the refused body before scoring; the first read now travels to the replay.
@maxmad64bis
maxmad64bis force-pushed the fix/shape-replay-verdict-reread branch from 8dc5469 to 3a7b978 Compare October 7, 2026 20:28
@maxmad64bis
maxmad64bis marked this pull request as ready for review October 7, 2026 20:38
@diegosouzapw
diegosouzapw merged commit 940b646 into diegosouzapw:release/v3.8.52 Oct 8, 2026
29 of 52 checks passed
@maxmad64bis
maxmad64bis deleted the fix/shape-replay-verdict-reread branch October 8, 2026 19:35
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.

2 participants