]> git.ipfire.org Git - thirdparty/tornado.git/commit
websockets: fix ping_timeout (#3376)
authorOliver Sanders <oliver.sanders@metoffice.gov.uk>
Tue, 22 Apr 2025 17:19:00 +0000 (18:19 +0100)
committerGitHub <noreply@github.com>
Tue, 22 Apr 2025 17:19:00 +0000 (13:19 -0400)
commit5b349e5bc9b726914da8bab81f7a7942548fa699
tree3d62234c056d2fb535140d85453e58c10a99291e
parent5e4fff49f9722768a695e0b3541530da9f173a26
websockets: fix ping_timeout (#3376)

* websockets: fix ping_timeout

* Closes #3258
* Closes #2905
* Closes #2655
* Fixes an issue with the calculation of ping timeout interval that
  could cause connections to be erroneously timed out and closed
  from the server end.

* websocket: Fix lint, remove hard-coded 30s default timeout

* websocket_test: Improve assertion error messages

* websocket_test: Allow a little slack in ping timing

Appears to be necessary on windows.

---------

Co-authored-by: Ben Darnell <ben@bendarnell.com>
tornado/test/websocket_test.py
tornado/websocket.py