Closed innuos-ccarvalho closed 1 year ago
Merging #20 (633dbab) into main (271f8fc) will not change coverage. The diff coverage is
100.00%
.
@@ Coverage Diff @@
## main #20 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 2 2
Lines 195 200 +5
Branches 41 42 +1
=========================================
+ Hits 195 200 +5
Impacted Files | Coverage Δ | |
---|---|---|
src/simple_websocket/ws.py | 100.00% <100.00%> (ø) |
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more
This is now merged. I have simplified the closing logic a bit, and also added a missing close for the selector, which is used when the optional pings are enabled. Thanks!
Thanks for your work!
Server now closes socket when connection is dropped by client to avoid sockets hanging in CLOSE_WAIT state.
This aims at solving issue #19 as discussed. I changed the solution a bit from what was proposed at first to follow the pattern already existent in Client. I'm not sure however about the best reason and message for the disconnection.
I'm not sure about the testing rules for this branch, I tested this case has best I could manually. If I should do something else, like updating automatic tests, please do say.
Also took the liberty to fix a couple of typos in comments, hope you don't mind.
Thank you