jagrosh / MusicBot

🎶 A Discord music bot that's easy to set up and run yourself!
https://jmusicbot.com
Apache License 2.0
5.42k stars 2.58k forks source link

[Bug Report] "Error loading: null" when passing link from Watch Later playlist #636

Open lazaroblanc opened 3 years ago

lazaroblanc commented 3 years ago

Describe the bug YouTube URLs with the query parameter "list=WL" (User's Watch Later playlist) result in an "Error loading: null" message.

To Reproduce Steps to reproduce the behavior:

  1. Try the play command with any YouTube URL that has the query parameter "list=WL" in it

Expected behavior The query parameter list should be ignored if its value is WL. For example:

What the user puts in: !p https://youtu.be/uN9tulBHr8Y?list=WL Should be processed as if he put in: !p https://youtu.be/uN9tulBHr8Y

You could use a regex to remove the query parameter from the URL before it gets processed further Regex: (?:\?|&)list=WL

Screenshots image

Debug Info

System Properties:
  java.version = 11.0.10
  java.vm.name = OpenJDK 64-Bit Server VM
  java.vm.specification.version = 11
  java.runtime.name = OpenJDK Runtime Environment
  java.runtime.version = 11.0.10+9-Ubuntu-0ubuntu1.20.04
  java.specification.version = 11
  os.arch = amd64
  os.name = Linux

JMusicBot Information:
  Version = 0.3.3
  Owner = 237178792362246144
  Prefix = !
  AltPrefix = null
  MaxSeconds = 0
  NPImages = false
  SongInStatus = false
  StayInChannel = false
  UseEval = false
  UpdateAlerts = true

Dependency Information:
  JDA Version = 4.2.0_227
  JDA-Utilities Version = 3.0.5
  Lavaplayer Version = 1.3.67

Runtime Information:
  Total Memory = 171
  Used Memory = 55

Discord Information:
  ID = 790183313268277298
  Guilds = 2
  Users = 1
jagrosh commented 3 years ago

This seems more like a bug and/or oversight in lavaplayer