My bot reports that the track is 9:56 minutes but it ends in a few seconds.
After re-encoding the track once to the same format using ffmpeg, this problem no longer occurs.
I've tried playing the file using vlc and ffplay, both report nothing wrong.
When loading the file, this error is logged:
[19:07:40] [WARN] [MediaContainerDetection]: Attempting to detect file with container wav failed.
java.lang.IllegalStateException: Invalid audio format 3, must be 1 (PCM)
at com.sedmelluq.discord.lavaplayer.container.wav.WavFileLoader$InfoBuilder.validateFormat(WavFileLoader.java:106)
at com.sedmelluq.discord.lavaplayer.container.wav.WavFileLoader$InfoBuilder.build(WavFileLoader.java:98)
at com.sedmelluq.discord.lavaplayer.container.wav.WavFileLoader$InfoBuilder.access$300(WavFileLoader.java:88)
at com.sedmelluq.discord.lavaplayer.container.wav.WavFileLoader.parseHeaders(WavFileLoader.java:53)
at com.sedmelluq.discord.lavaplayer.container.wav.WavContainerProbe.probe(WavContainerProbe.java:45)
at com.sedmelluq.discord.lavaplayer.container.MediaContainerDetection.checkContainer(MediaContainerDetection.java:91)
at com.sedmelluq.discord.lavaplayer.container.MediaContainerDetection.detectContainer(MediaContainerDetection.java:76)
at com.sedmelluq.discord.lavaplayer.container.MediaContainerDetection.detectContainer(MediaContainerDetection.java:61)
at com.sedmelluq.discord.lavaplayer.source.http.HttpAudioSourceManager.detectContainerWithClient(HttpAudioSourceManager.java:143)
at com.sedmelluq.discord.lavaplayer.source.http.HttpAudioSourceManager.detectContainer(HttpAudioSourceManager.java:121)
at com.sedmelluq.discord.lavaplayer.source.http.HttpAudioSourceManager.loadItem(HttpAudioSourceManager.java:82)
at com.sedmelluq.discord.lavaplayer.player.DefaultAudioPlayerManager.checkSourcesForItemOnce(DefaultAudioPlayerManager.java:436)
at com.sedmelluq.discord.lavaplayer.player.DefaultAudioPlayerManager.checkSourcesForItem(DefaultAudioPlayerManager.java:418)
at com.sedmelluq.discord.lavaplayer.player.DefaultAudioPlayerManager.lambda$createItemLoader$0(DefaultAudioPlayerManager.java:217)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at com.sedmelluq.discord.lavaplayer.tools.OrderedExecutor$ChannelRunnable.executeQueue(OrderedExecutor.java:98)
at com.sedmelluq.discord.lavaplayer.tools.OrderedExecutor$ChannelRunnable.run(OrderedExecutor.java:87)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
These error messages are also logged, many times, in a seemingly random order:
Warning: Big change (MPEG version, layer, rate). Frankenstein stream?
[src/libmpg123/layer3.c:465] error: big_values too large!
[src/libmpg123/layer3.c:496] error: Blocktype == 0 and window-switching == 1 not allowed.
[src/libmpg123/layer3.c:2016] error: bad frame - unable to get valid sideinfo
Trying to play this audio file: https://cdn.discordapp.com/attachments/942881728039620630/1044690508905201685/Action_mic.wav
Produces glitched sound that resemble nothing but a codec error.
When loading the file, this error is logged:
These error messages are also logged, many times, in a seemingly random order:
I'm using a fork of Jagrosh/MusicBot and a fork of Lavaplayer, although the changes shouldn't have caused this - I'll test this with an unmodified bot and Lavaplayer soon.
The bot is running on Linux in Docker, the container OS is Debian (bullseye) and has openjdk 11.