Skip to content

fix(server): stop emitting an empty interrupt frame at natural end of…#292

Open
decrypto21 wants to merge 1 commit into
mainfrom
fix/no-stream-end-interrupt
Open

fix(server): stop emitting an empty interrupt frame at natural end of…#292
decrypto21 wants to merge 1 commit into
mainfrom
fix/no-stream-end-interrupt

Conversation

@decrypto21

Copy link
Copy Markdown

What

A subscription stream that ends naturally no longer emits a zero-length interrupt frame. Natural end of stream emits nothing; only an explicit interrupt carries a terminal frame.

Slot cleanup is unchanged: the subscription task still removes its own generation's slot, and a superseding reservation still owns its own cleanup.

Why (this is D6 from #271)

No deployed host signals natural end of stream on the wire - the novasama host-container sends receive frames only. The core's extra empty interrupt frame is a conformance divergence, and the generated TS client treats the zero-length payload as an undecodable interrupt - so at best it is noise, at worst a decode error surfaced to the product.

This is decision-independent of the error-shape direction (#271 D4 → #259): it is about emitting a frame at all at natural end, not the shape of error frames. It previously rode the flat-wire branch (#285); with that PR closed in favour of #259, this ships on its own - same rationale as the novasama terminal-frames fix (paritytech/triangle-js-sdks#228), which is the mirror image (host answers a frame on every fault; core stays silent on natural end).

Evidence

  • truapi-server unit tests updated in place: register_completion_emits_no_terminal_frame (was register_completion_emits_interrupt), supersede/stop/dispose cases assert no stray frames.
  • Full cargo test -p truapi-server green (310 tests).
  • Differential probe (core vs novasama at triangle-js-sdks 592dc4b): S1 stream-end now "receive only" on both sides (W1-Convergence-Run-2026-07-16.md, row S1).

Relates to #271 (D6).

@decrypto21
decrypto21 marked this pull request as ready for review July 21, 2026 04:09
@decrypto21
decrypto21 requested a review from a team July 21, 2026 04:09
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