Releases: sentinelb51/revoltgo
2.2.0 — Bug fixes, Bulk Message Delete method
This update fixes a major bug that was caused by the previous performance update, which stopped AbstactEventUpdate events from being dispatched and processed properly, leading to a dead state. Additionally, a missing method for bulk-deleting messages is also added.
2.1.0 — Performance and stability improvements
This update brings performance improvements and bugfixes:
- Events are no longer decoded when there's no handler for processing it.
This means that unwanted events now take0 nanoseconds
to process, reducing CPU usage - Added and fixed events. New events include
EventBulkMessageDelete
,EventMessageRemoveReaction
. The eventEventChannelCreate
now includes all the information about a channel, andEventServerCreate
includes channels and emojis - Improvements and fixes to the state logic. Server member updates now cache rather than warning, creating channels now caches all the data thanks to the previous bug fix with
EventChannelCreate
, and adding/removing members from groups correctly updates them in the state. A potential runtime panic has also been safe-guarded against.
Other small changes include general code house-keeping and consistency improvements.
v2.0.1 — Minor (major) bug fix
This small update changes the data type of Role.Rank from uint to int, preventing a decoding error for the Ready event. If the Ready event fails to decode, your client will be missing out on a lot of data, such as State.Self.
Additionally, some minor housekeeping involves removing non-existent endpoints.
Major release: 2.0.0
This is a major release that brings about many breaking yet enhancing changes to the library. While a curated list would be too long, some of the main changes include:
- Maturation of the State logic; objects are properly updated, cleared, and are race-protected with mutexes
- Performance improvements; the library now uses lxzan's gws websocket library and goccy/go-json to improve the performance. Furthermore, the state update logic no longer uses reflection.
- More events, endpoints, session methods; the library now supports virtually all endpoints and methods
- Convenience for adding handlers; call session.AddHandler() just like in discordgo, and the appropriate handler will be appended to based on the function signature
- Various logic improvements; includes better re-connection logic, streamlined authorisation, protocol-based heartbeat rather than payload, handling of bulk events, and probably more.
We also have a new Revoltgo support server (the old one was deleted by accident)
Full Changelog: 1.0.2...2.0.0
Stable release
Fixes a critical error where bots would 401 due to incorrect headers. While revolt's documentation shows X-Session-Token as the auth header, X-Bot-Token is required instead. Both will be set as the library does not know if it's acting as a self-bot or not.
In the future, maybe during the initial handshake we could fetch the user, then the request method can determine if we're a self-bot by checking s.State.User?
Stable release
Fixed a minor bug that resulted in duplicate ratelimit buckets for the same endpoint. This was caused by URL query parameters.
Stable release
This release features a stable and ready-to-use API, with support for almost everything included in the API, as well as caching, ratelimiting, and reconnects on websocket errors.