Skip to content

fix(opencode): count silent streamed replies while the first-byte guard stays off - #15455

Open
maxmad64bis wants to merge 1 commit into
diegosouzapw:release/v3.8.52from
maxmad64bis:fix/responses-stall-measure
Open

maxmad64bis wants to merge 1 commit into
diegosouzapw:release/v3.8.52from
maxmad64bis:fix/responses-stall-measure

Conversation

@maxmad64bis

@maxmad64bis maxmad64bis commented Oct 3, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ base-red inherited: #15306

Summary

Streamed replies that go silent after headers pass through without a trace, so the 15 s first-byte window cannot be calibrated. The change adds a passive shadow watch: when the guard stays off, a silent streamed reply is now counted and logged with its running total, while the reply itself is returned untouched. Talking streams, non-streamed calls and other formats stay as before, and nothing rotates, cools down or changes defaults.

Related Issues

Validation

  • Change type: other
  • 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-responses-stall-measure.test.ts — new: silent reply counted and logged with the reply returned intact; talking body stays silent; non-streamed and non-Responses requests ignored; armed guard excludes the shadow; storage stays constant.
  • tests/unit/opencode-responses-stall-harden.test.ts — untouched, rerun green; covers the unchanged guard.
  • tests/unit/opencode-responses-first-byte-stall.test.ts — untouched, rerun green; covers the executor wiring.

Coverage Notes

  • open-sse/executors/opencodeResponsesStall.ts — covered by the new measure test (shadow counting, exclusion paths, constant storage) plus the harden suite for the unchanged guard.
  • open-sse/executors/opencode.ts — one wiring hunk, exercised through the executor-level first-byte stall suite.

Reviewer Notes

…rd stays off

Unmeasured silent streams left the 15 s window uncalibrated; each new case fails without the change.

This branch has not been deployed

No deployments
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