Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: state that no session disconnected event before closed #48

Merged
merged 1 commit into from
Apr 28, 2024

Conversation

kezhuw
Copy link
Owner

@kezhuw kezhuw commented Apr 28, 2024

Though there is code path to deliver Disconnected before Closed, but
it is unreachable and several tests have assert immediate Closed after
clients dropped, e.g. test_state_watcher, test_client_drop and
test_client_detach.

I favor immediate Closed now since it states the truth and avoid false
reactions against Disconnected. Whoever want a Disconnected could do
it themselves.

Though there is code path to deliver `Disconnected` before `Closed`, but
it is unreachable and several tests have assert immediate `Closed` after
clients dropped, e.g. `test_state_watcher`, `test_client_drop` and
`test_client_detach`.

I favor immediate `Closed` now since it states the truth and avoid false
reactions against `Disconnected`. Whoever want a `Disconnected` could do
it themselves.
@kezhuw kezhuw merged commit ea64b7f into master Apr 28, 2024
12 checks passed
@kezhuw kezhuw deleted the state-no-disconnected-before-closed branch April 28, 2024 01:57
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