Closed skick1234 closed 3 years ago
might be related to #124
Can you share your code? And also whether or not any errors are emitted from the player
Can you share your code? And also whether or not any errors are emitted from the player
The stream stop and AudioPlayer
change the state to Idle. Error event is not emitted.
I don't think it is due to my code
<AudioPlayer>.play(createAudioResource("stream url", {
inputType: StreamType.Arbitrary,
inlineVolume: true,
})).on("stateChange", (oldState, newState) => {
if (newState.status === AudioPlayerStatus.Idle && oldState.status !== AudioPlayerStatus.Idle) {
// Finish song
}
}).on("error", console.error);
It randomly happens, not every time play.
Can you see if the suggestions in this thread fix your issue:
Can you see if the suggestions in this thread fix your issue:
I created this issue because of arbitrary stream .-. So it is not recommended to use this?
I think your issue is due to using FFmpeg, by default we don't provide any reconnect parameters since that would be opinionated.
I am looking into a way to make this easier to customise, but for now, you'd have to create your own FFmpeg with reconnect parameters as shown in the issue above (your issue has the same symptoms as the issue above, so I'm assuming it's due to that)
I think your issue is due to using FFmpeg, by default we don't provide any reconnect parameters since that would be opinionated.
Yes, my bot uses raw stream with reconnect params doesn't have that problem.
I am looking into a way to make this easier to customise
Sounds promising, should I open the issue till you solve this?
Sure, opening an issue would be useful 👍
I mean open this issue :v anyway, hope you find out a good solution soon. I have no idea :>
Closing this issue since it seems to be resolved using the above steps, and is a duplicate of https://github.com/discordjs/voice/issues/117.
Will track the overall issue in a new separate issue.
Please describe the problem you are having in as much detail as possible:
Arbitrary stream randomly ends at the middle of the track. I cannot reproduce it but sometimes it happened with the same URL. I check the URL after the stream ended. It is still downloadable and plays the full track after downloading on my PC.
Further details: