Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crashes and clears queue when no results found for a song #99

Open
andreyrd opened this issue Apr 8, 2022 · 2 comments
Open

Crashes and clears queue when no results found for a song #99

andreyrd opened this issue Apr 8, 2022 · 2 comments

Comments

@andreyrd
Copy link

andreyrd commented Apr 8, 2022

When I add a song, via Spotify link, that cannot be found on YouTube, once the song is reached it clears out the entire queue and I get this error:

[download] Downloading playlist: Habakkuk  Georgia Costolo, Tyler Costolo
[youtube:search] query "Habakkuk  Georgia Costolo, Tyler Costolo " page 1: Downloading API JSON
[youtube:search] playlist Habakkuk  Georgia Costolo, Tyler Costolo : Downloading 0 videos
[download] Finished downloading playlist: Habakkuk  Georgia Costolo, Tyler Costolo
Future exception was never retrieved
future: <Future finished exception=IndexError('list index out of range')>
Traceback (most recent call last):
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\concurrent\futures\thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py", line 245, in down
    song.info.webpage_url = self.search_youtube(song.info.title)
  File "C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py", line 289, in search_youtube
    videocode = r['entries'][0]['id']
IndexError: list index out of range
[download] Downloading playlist: Sodom's Sins  Georgia Costolo, Tyler Costolo
[youtube:search] query "Sodom's Sins  Georgia Costolo, Tyler Costolo " page 1: Downloading API JSON
[youtube:search] playlist Sodom's Sins  Georgia Costolo, Tyler Costolo : Downloading 0 videos
[download] Finished downloading playlist: Sodom's Sins  Georgia Costolo, Tyler Costolo
Future exception was never retrieved
future: <Future finished exception=IndexError('list index out of range')>
Traceback (most recent call last):
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\concurrent\futures\thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py", line 245, in down
    song.info.webpage_url = self.search_youtube(song.info.title)
  File "C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py", line 289, in search_youtube
    videocode = r['entries'][0]['id']
IndexError: list index out of range
Task exception was never retrieved
future: <Task finished name='Task-5465' coro=<AudioController.play_song() done, defined at C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py:68> exception=TypeError('expected str, bytes or os.PathLike object, not NoneType')>
Traceback (most recent call last):
  File "C:\Users\andre\applications\DingoLingo\musicbot\audiocontroller.py", line 105, in play_song
    self.guild.voice_client.play(discord.FFmpegPCMAudio(
  File "C:\Users\andre\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\player.py", line 225, in __init__
    super().__init__(source, executable=executable, args=args, **subprocess_kwargs)
  File "C:\Users\andre\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\player.py", line 138, in __init__
    self._process = self._spawn_process(args, **kwargs)
  File "C:\Users\andre\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\player.py", line 144, in _spawn_process
    process = subprocess.Popen(args, creationflags=CREATE_NO_WINDOW, **subprocess_kwargs)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 966, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 1375, in _execute_child
    args = list2cmdline(args)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 561, in list2cmdline
    for arg in map(os.fsdecode, seq):
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.1264.0_x64__qbz5n2kfra8p0\lib\os.py", line 822, in fsdecode
    filename = fspath(filename)  # Does type-checking of `filename`.
@RafaelSolVargas
Copy link
Contributor

RafaelSolVargas commented Apr 11, 2022

Can you give us an example of an url that presents this problem?

@andreyrd
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants