Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lavalink v4 update will break twilight-lavalink #2192

Open
Michael-1001 opened this issue Apr 8, 2023 · 3 comments
Open

Lavalink v4 update will break twilight-lavalink #2192

Michael-1001 opened this issue Apr 8, 2023 · 3 comments
Labels
c-lavalink Affects the lavalink crate m-breaking change Breaks the public API.

Comments

@Michael-1001
Copy link

I believe Lavalink is going ahead with their v4 update soon and removing their v2 websocket client requests (well, they were deprecated in v3 and from what I gathered in their Discord the choice was made to remove it entirely in v4).

This means while twilight-lavalink will still be able to listen in on websocket notifications (I believe the current version listens into PlayerUpdate and Stats op codes), it won't actually be able to make any requests as they're all being supplemented with REST API calls instead.

I'm happy to try and help contribute if possible but, this bot being my first major Rust project (well excluding my here and there with Serenity recently) I'm unsure anyone wants to see what I might produce.

For more information you can find it here:
Their current implementation details for version 3.7.5 can be found here.
Their implementation details for 4.0 can be found here.

@Gelbpunkt Gelbpunkt added c-lavalink Affects the lavalink crate m-breaking change Breaks the public API. labels Apr 15, 2023
@LinuxDevon
Copy link
Contributor

I am working on adding support for this. Fixed the current rc first and going to work on adding this support. Implementation overall is going to be a bigger rewrite than expected...

2024-03-04 23:12:54.572 WARN 1 --- [ XNIO-1 I/O-10] lavalink.server.io.WebSocketHandler : Sending websocket commands to Lavalink has been deprecated and will be removed in API version 4. API version 3 will be removed in Lavalink 5. Please use the new REST endpoints instead.

The lavalink bot is written on websockets 😮‍💨. New link to the implementation details since the original is broken / changed: https://lavalink.dev/api/index.html

@LinuxDevon
Copy link
Contributor

LinuxDevon commented Mar 14, 2024

@Michael-1001 if you have some time it would be helpful to have a second set of tests to see if you can also use it. Not sure if you have a bot or not to test on.

@Michael-1001
Copy link
Author

Michael-1001 commented Mar 20, 2024

Sorry for the late response!

I made some local additions to twilight-lavalink a while back so I'm running a real mess of code at the moment. I was going to come back to my bot soon (albeit slightly busy at the moment) so I'll give it a try then if no one else beats me to it.

Seeing some great commits though, thanks for looking into this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c-lavalink Affects the lavalink crate m-breaking change Breaks the public API.
Projects
None yet
Development

No branches or pull requests

3 participants