Skip to content

fix: treat a replied close frame like a :close result - #102

Merged
nmbrone merged 3 commits into
mainfrom
fix/reply-close-parity
Sep 30, 2026
Merged

nmbrone merged 3 commits into
mainfrom
fix/reply-close-parity

Conversation

@nmbrone

@nmbrone nmbrone commented Sep 30, 2026

Copy link
Copy Markdown
Owner

A close frame returned as {:reply, frame, state} went through handle_send/1, so a close that could not be sent was logged through handle_error/2 while the same intent spelled {:close, code, reason, state} went through handle_close/1: ignored when there is nothing to close, and a disconnect when the write itself failed.

Both spellings now take the same path.

A close frame returned as `{:reply, frame, state}` went through `handle_send/1`, so a close that could not be sent was logged through `handle_error/2` while the same intent spelled `{:close, code, reason, state}` went through `handle_close/1`: ignored when there is nothing to close, and a disconnect when the write itself failed.

Both spellings now take the same path.
The server answered the close and the client stopped before the later assertions ran, so the call exited instead of returning {:error, :closing}. It only opened on a loaded runner.
@nmbrone
nmbrone merged commit 4e02550 into main Sep 30, 2026
4 checks passed
@nmbrone
nmbrone deleted the fix/reply-close-parity branch September 30, 2026 08:00
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