sedmelluq / lavaplayer

Audio player library for Discord
Apache License 2.0
967 stars 247 forks source link

Loading information for a YouTube track failed #688

Open BlastyTheDev opened 2 years ago

BlastyTheDev commented 2 years ago

Lavaplayer was no longer able to load YouTube tracks after a day of use (strange) due to "Loading information for a YouTube track failed."

Stack Trace:


com.sedmelluq.discord.lavaplayer.tools.FriendlyException: Loading information for a YouTube track failed.
    at com.sedmelluq.discord.lavaplayer.tools.ExceptionTools.wrapUnfriendlyExceptions(ExceptionTools.java:44)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager.loadTrackWithVideoId(YoutubeAudioSourceManager.java:220)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager$LoadingRoutes.track(YoutubeAudioSourceManager.java:232)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager$LoadingRoutes.track(YoutubeAudioSourceManager.java:228)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeLinkRouter.routeFromUrlWithVideoId(DefaultYoutubeLinkRouter.java:99)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeLinkRouter.routeFromMainDomain(DefaultYoutubeLinkRouter.java:64)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeLinkRouter.route(DefaultYoutubeLinkRouter.java:42)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager.loadItemOnce(YoutubeAudioSourceManager.java:196)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager.loadItem(YoutubeAudioSourceManager.java:131)
    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:1136)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
    at java.base/java.lang.Thread.run(Thread.java:833)
    Suppressed: com.sedmelluq.discord.lavaplayer.tools.exception.EnvironmentInformation: 
  lavaplayer.version: 1.3.77
  os.arch: amd64
  os.name: Windows 10
  os.version: 10.0
  java.vendor: Oracle Corporation
  java.version: 17.0.1
  java.runtime.version: 17.0.1+12-LTS-39
  java.vm.version: 17.0.1+12-LTS-39
Caused by: java.lang.RuntimeException: Error when extracting data EID: 8845d838-5a65-4680-b617-c3ae5f5e7ff7, mainJson <redacted>
    at com.sedmelluq.discord.lavaplayer.tools.ExceptionTools.throwWithDebugInfo(ExceptionTools.java:134)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeTrackDetailsLoader.load(DefaultYoutubeTrackDetailsLoader.java:70)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeTrackDetailsLoader.loadDetails(DefaultYoutubeTrackDetailsLoader.java:45)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeAudioSourceManager.loadTrackWithVideoId(YoutubeAudioSourceManager.java:208)
    ... 16 more
Caused by: java.lang.RuntimeException: Neither player nor playerResponse in result EID: 68313e65-d911-4965-af60-11f8580cb6d2, json <redacted>
    at com.sedmelluq.discord.lavaplayer.tools.ExceptionTools.throwWithDebugInfo(ExceptionTools.java:134)
    at com.sedmelluq.discord.lavaplayer.source.youtube.YoutubeTrackJsonData.fromMainResult(YoutubeTrackJsonData.java:53)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeTrackDetailsLoader.loadBaseResponse(DefaultYoutubeTrackDetailsLoader.java:80)
    at com.sedmelluq.discord.lavaplayer.source.youtube.DefaultYoutubeTrackDetailsLoader.load(DefaultYoutubeTrackDetailsLoader.java:59)
    ... 18 more
MineTrainDevelopment commented 2 years ago

Same problem. Since yesterday(05.04.2022) ~20:00 UTC is YouTube broken.

image image image

And on windows the same: image

And here is an Strip log file, with the complete error: LatestBotLog.log

idpromnut commented 2 years ago

I have a PR that fixes this issue: https://github.com/sedmelluq/lavaplayer/pull/687

hugomjp28 commented 2 years ago

it works thank you!!

BlastyTheDev commented 2 years ago

I have a PR that fixes this issue: #687

How would I use this to fix the issue? (i dont really understand what a pull request is lol)

mdeslippe commented 2 years ago

I'm having this issue as well

MCOfficer commented 2 years ago

To fix this, all you need to is change your lavaplayer dependency.

Method 1, using the PR (= basically a user-provided fix that hasn't been accepted yet):

Method 2, using Walkyst's fork which doesn't have this issue and fixes a couple other things: