Cog-Creators / Red-DiscordBot

A multi-function Discord bot
https://docs.discord.red
GNU General Public License v3.0
4.81k stars 2.31k forks source link

Playing from Youtube Error #329

Closed infrasparker closed 8 years ago

infrasparker commented 8 years ago

Redbot throws an error every time I attempt to !play using youtube search options. For instance, when I type: !play retro funky sundance in the discord chat, I see

ERROR: Signature extraction failed: Traceback (most recent call last): File "C:\Users\Infrasparker\AppData\Local\Programs\Python\Python35\lib\site-packages\youtube_dl\extractor\youtube.py", line 997, in _decrypt_signature video_id, player_url, s File "C:\Users\Infrasparker\AppData\Local\Programs\Python\Python35\lib\site-packages\youtube_dl\extractor\youtube.py", line 912, in _extract_signature_function res = self._parse_sig_js(code) File "C:\Users\Infrasparker\AppData\Local\Programs\Python\Python35\lib\site-packages\youtube_dl\extractor\youtube.py", line 975, in _parse_sig_js initial_function = jsi.extract_function(funcname) File "C:\Users\Infrasparker\AppData\Local\Programs\Python\Python35\lib\site-packages\youtube_dl\jsinterp.py", line 241, in extract_function raise ExtractorError('Could not find JS function %r' % funcname) youtube_dl.utils.ExtractorError: Could not find JS function 'wr'; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output. (caused by ExtractorError("Could not find JS function 'wr'; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.",)); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output. Task exception was never retrieved future: <Task finished coro=<Audio.queue_manager() done, defined at C:\Users\Infrasparker\Documents\Red-DiscordBot\cogs\audio.py:1750> exception=AttributeError("'NoneType' object has no attribute 'duration'",)> Traceback (most recent call last): File "C:\Users\Infrasparker\AppData\Local\Programs\Python\Python35\lib\asyncio\tasks.py", line 239, in _step result = coro.send(None) File "C:\Users\Infrasparker\Documents\Red-DiscordBot\cogs\audio.py", line 1781, in queue_manager song = await self._play(sid, url) File "C:\Users\Infrasparker\Documents\Red-DiscordBot\cogs\audio.py", line 730, in _play song = await self._guarantee_downloaded(server, url) File "C:\Users\Infrasparker\Documents\Red-DiscordBot\cogs\audio.py", line 542, in _guarantee_downloaded self.downloaders[server.id].duration_check() File "C:\Users\Infrasparker\Documents\Red-DiscordBot\cogs\audio.py", line 206, in duration_check log.debug("duration {} for songid {}".format(self.song.duration, AttributeError: 'NoneType' object has no attribute 'duration'

In the console. I don't really know where to start reading the error message, but since I know red is working for others can anyone help me? Thanks.

EDIT: Missposted. Already found solution to this issue.

Twentysix26 commented 8 years ago

I guess you fixed this with
pip3 install --upgrade youtube_dl

infrasparker commented 8 years ago

Yeah, exactly. Sorry for the spam[?] thread.

graysonspop4444 commented 7 years ago

please help i know absolutely nothing about bots and when i plug that command into the terminal for my mac it does nothing

palmtree5 commented 7 years ago

If the bot's running, commands should be entered inside discord

Rekiamer commented 7 years ago

how do I enter the command in the bot? or in the discord have the same problem

palmtree5 commented 7 years ago

You should just be able to install requirements via the launcher @Rekiamer

redsmok04 commented 6 years ago

i have this error ModuleNotFoundError: No module named 'youtube_dl'

bobloy commented 6 years ago

Ask your question in the discord instead of commenting on a year old Issue https://discord.gg/red