Voice player sometimes doesn't start playing music

Hi, like the title says, the voice player randomly doesn't start playing music

The code responsible for it is the boilerplate from https://discordjs.guide/voice/audio-player.html#playing-audio modified only by a 20sec timeout which just disconnects the bot:

const connection = getVoiceConnection(this.guild.id);
connection?.destroy();


Relevant package versions:
"@discordjs/opus": "^0.8.0",
"@discordjs/voice": "^0.13.0",
"ffmpeg-static": "^5.1.0",
"libsodium-wrappers": "^0.7.10",
"node-opus": "^0.3.3",
"opusscript": "^0.0.8",

Any leads would be appreciated and in advance I'm sorry for the incomplete info, i can't run it in debug mode right now
Was this page helpful?