Skip to content

Conversation

@jgrund
Copy link

@jgrund jgrund commented Feb 9, 2026

Without this, the QUIC CONNECTION_CLOSE frame sent when the caller closes the connection can race with (and arrive before) the stream data at the server, causing the server's accept_bi to see ApplicationClosed instead of the notify message.

Call finish() to signal end-of-stream, then stopped().await to wait for the peer's transport-level ACK before returning. This ensures the server has the stream data before the connection is closed.

Without this, the QUIC CONNECTION_CLOSE frame sent when the caller
closes the connection can race with (and arrive before) the stream
data at the server, causing the server's accept_bi to see
ApplicationClosed instead of the notify message.

Call finish() to signal end-of-stream, then stopped().await to wait
for the peer's transport-level ACK before returning. This ensures the
server has the stream data before the connection is closed.

Signed-off-by: Joe Grund <grundjoseph@gmail.com>
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