nstanev255 / dsors

A small discord gateway sdk.
MIT License
0 stars 0 forks source link

Heartbeat loop is not correct. #4

Open nstanev255 opened 9 months ago

nstanev255 commented 9 months ago

As per discord's api, the library should send a "heartbeat" event to the websocket every x seconds... Which the seconds are received on the HelloEvent that discord sends us on new connection,

This is tricky with regular blocking websockets, because we will need to introduce threading and rewrite a big portion of the general logic. For now, we will just skip this functionality and return back to it after we migrate the lib to tokio.

Documentation

nstanev255 commented 8 months ago

The heartbeat interval is handled in this PR https://github.com/nstanev255/dsors/pull/7

Use this issue to handle sending the actual message.