hyperliquid-dex / hyperliquid-rust-sdk

MIT License
57 stars 47 forks source link

When using websockets, the user should also be sent the Errors #45

Closed Frixoe closed 1 month ago

Frixoe commented 1 month ago

Right now, some errors cause a panic in the websocket data parsing thread while others just keep going(ReaderDataNotFound). This behaviour doesn't allow the user to react to the errors. It simply requires a full reset of the thread but the user doesn't even know when the error occurs because it's only being logged and not sent to the user.