Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions tornado/websocket.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ def on_close(self):
If the application setting ``websocket_ping_interval`` has a non-zero
value, a ping will be sent periodically, and the connection will be
closed if a response is not received before the ``websocket_ping_timeout``.
Both settings are in seconds; floating point values are allowed.
The default timeout is equal to the interval.

Messages larger than the ``websocket_max_message_size`` application setting
(default 10MiB) will not be accepted.
Expand Down Expand Up @@ -308,7 +310,7 @@ def ping_timeout(self) -> Optional[float]:

Set ``websocket_ping_timeout = 0`` to disable the ping timeout.

Default: ``min(ping_interval, 30)``
Default: equal to the ``ping_interval``.

.. versionchanged:: 6.5.0
Default changed from the max of 3 pings or 30 seconds.
Expand Down Expand Up @@ -406,8 +408,8 @@ def get_compression_options(self) -> Optional[Dict[str, Any]]:

``mem_level`` specifies the amount of memory used for the internal compression state.

These parameters are documented in details here:
https://docs.python.org/3.6/library/zlib.html#zlib.compressobj
These parameters are documented in detail here:
https://docs.python.org/3.13/library/zlib.html#zlib.compressobj

.. versionadded:: 4.1

Expand Down