- See below release candidates for further changes. TLDR: Improved WebSocket stability and reconnection logic.
Added - `retries` argument so that users specify how many times the WebSocket tries to reconnect upon disconnection - The default is `10`. To retry forever, set it to `0`. pybit will wait 1 second between each retry.
Modified - Improved the logging around WebSocket disconnection
2.2.2rc2
Added - WebSocket topic resubscription so that when a WebSocket connection is dropped and then reconnected it should resume pushing the same data as before. Essentially, completes the expected functionality of reconnecting to the WebSocket.
Modified - `is_connected()` function to work with modules that utilise >1 WebSocket connections
2.2.2rc1
Added - `is_connected()` function to `WebSocket` class so that you can check if your WebSocket connection is alive
Fixed - Bug where, upon WebSocket disconnection, pybit rapidly tries to re-establish the connection, which results in being banned by the CDN for malicious activity
2.2.2rc0
Modified - Improved HTTP error handling and logging to ease troubleshooting
2.2.1
Modified - `usdt_perpetual` -> `get_risk_limit()` to not require authentication
Fixed - `usdt_perpetual` -> `add_reduce_margin()` to use the correct request method
2.2.0
Added - USDC options `WebSocket` and `HTTP` classes - Deposit/withdrawal endpoints to `account_asset` module