Stuck at connecting
I have noticed that sometimes the connection state of a voice channel goes through these states:
signalling > connecting
connecting > connecting
connecting > connecting
And then it just gets stuck in that connecting state indefinitely.
The bot does join the voice channel but does nothing.
The normal events usually look like:
signalling > connecting
connecting > connecting
connecting > connecting
connecting > connecting
connecting > ready
2 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!To debug your voice connection and player:
- Use
debug: true
when creating your VoiceConnection
and AudioPlayer
- Add an event listener to the <VoiceConnection> and the <AudioPlayer>:
- Add an error
listener to the stream you are passing to the resource:
Note: The <>
represents classes that need to be adapted to their respective name in your code