PhasecoreX / docker-red-discordbot

The newest Red-Discordbot in a convenient container

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Audio Cog not Loading

acedapig opened this issue · comments

Completed above, no change

Describe the bug

After starting the bot, not getting the audio cog to initialize, getting error messages:

[2021-09-14 16:35:48] [ERROR] red.cogs.Audio.cog.Tasks.startup: Audio failed to start up, please report this issue.
ssl.SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)
aiohttp.client_exceptions.ClientConnectorSSLError: Cannot connect to host gist.githubusercontent.com:443 ssl:default [[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)]
[2021-09-14 16:35:48] [ERROR] red.cogs.Audio.task.callback: Task-316 raised an Exception

Run command

The Docker command/docker-compose.yml you are using to start the bot.
Be sure to censor your bot token (or any other sensitive info) if it is present!

Environment info:
Running docker on Unraid 6.8.3
Docker Version 19.03.5

Additional context
[2021-09-14 16:35:48] [ERROR] red.cogs.Audio.cog.Tasks.startup: Audio failed to start up, please report this issue.

Traceback (most recent call last):
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 969, in _wrap_create_connection
return await self._loop.create_connection(*args, **kwargs) # type: ignore # noqa
File "uvloop/loop.pyx", line 2069, in create_connection
File "uvloop/loop.pyx", line 2064, in uvloop.loop.Loop.create_connection
File "uvloop/sslproto.pyx", line 517, in uvloop.loop.SSLProtocol._on_handshake_complete
File "uvloop/sslproto.pyx", line 499, in uvloop.loop.SSLProtocol._do_handshake
File "/usr/local/lib/python3.8/ssl.py", line 944, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/tasks/startup.py", line 57, in initialize
await self._build_bundled_playlist()
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/utilities/playlists.py", line 713, in _build_bundled_playlist
web_version, tracks = await self._get_bundled_playlist_tracks()
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/utilities/playlists.py", line 690, in _get_bundled_playlist_tracks
async with session.get(
File "/data/venv/lib/python3.8/site-packages/aiohttp/client.py", line 1117, in aenter
self._resp = await self._coro
File "/data/venv/lib/python3.8/site-packages/aiohttp/client.py", line 520, in _request
conn = await self._connector.connect(
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 535, in connect
proto = await self._create_connection(req, traces, timeout)
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 892, in _create_connection
_, proto = await self._create_direct_connection(req, traces, timeout)
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 1051, in _create_direct_connection
raise last_exc
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 1020, in _create_direct_connection
transp, proto = await self._wrap_create_connection(
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 973, in _wrap_create_connection
raise ClientConnectorSSLError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorSSLError: Cannot connect to host gist.githubusercontent.com:443 ssl:default [[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)]

[2021-09-14 16:35:48] [ERROR] red.cogs.Audio.task.callback: Task-316 raised an Exception

Traceback (most recent call last):
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 969, in _wrap_create_connection
return await self._loop.create_connection(*args, **kwargs) # type: ignore # noqa
File "uvloop/loop.pyx", line 2069, in create_connection
File "uvloop/loop.pyx", line 2064, in uvloop.loop.Loop.create_connection
File "uvloop/sslproto.pyx", line 517, in uvloop.loop.SSLProtocol._on_handshake_complete
File "uvloop/sslproto.pyx", line 499, in uvloop.loop.SSLProtocol._do_handshake
File "/usr/local/lib/python3.8/ssl.py", line 944, in do_handshake
self._sslobj.do_handshake()
ssl.SSLError: [SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/tasks/startup.py", line 65, in initialize
raise err
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/tasks/startup.py", line 57, in initialize
await self._build_bundled_playlist()
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/utilities/playlists.py", line 713, in _build_bundled_playlist
web_version, tracks = await self._get_bundled_playlist_tracks()
File "/data/venv/lib/python3.8/site-packages/redbot/cogs/audio/core/utilities/playlists.py", line 690, in _get_bundled_playlist_tracks
async with session.get(
File "/data/venv/lib/python3.8/site-packages/aiohttp/client.py", line 1117, in aenter
self._resp = await self._coro
File "/data/venv/lib/python3.8/site-packages/aiohttp/client.py", line 520, in _request
conn = await self._connector.connect(
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 535, in connect
proto = await self._create_connection(req, traces, timeout)
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 892, in _create_connection
_, proto = await self._create_direct_connection(req, traces, timeout)
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 1051, in _create_direct_connection
raise last_exc
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 1020, in _create_direct_connection
transp, proto = await self._wrap_create_connection(
File "/data/venv/lib/python3.8/site-packages/aiohttp/connector.py", line 973, in _wrap_create_connection
raise ClientConnectorSSLError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorSSLError: Cannot connect to host gist.githubusercontent.com:443 ssl:default [[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:1131)]

GitHub might be doing something weird as of recent. I see that some users are having this error recently in the Red support server (thankfully they seem to be regular Red installs, not in Docker). I actually just tested the Audio cog with a new arm64 VM, and the Audio cog downloaded just fine and the playlist works. I've also verified that it loads on a new amd64 server too.

Does this error happen every time you try loading the Audio cog?

It appears to be occurring as soon as the container runs and starts the bot with the cog loaded.

When I joined the Red support server, I noticed the same thing, but the auto-bot informed me that I'm using an unsupported installation method by using Docker and not utilizing one of their installation methods.

Is there some sort of extra setup I need to do other than pull the docker container down?

Nope, should be just pull the image and then start it. You aren't using the noaudio tag, correct? I tested the audio/latest tag and the container starts just fine, loading the Audio cog. Do you have some sort of a network firewall, or is Unraid doing something weird with network connections? I don't have much to go off of here haha.

I believe i pulled the full not the audio latest. I can give that a shot. Otherwise no firewalls outside of the xfinity built in gateway. Sorry for not much other info. Let me know how else i can provide info for you

Rebooted the bot today without making any changes for giggles, and it's working now. No changes were made from the previous post where I stated I would attempt audio/latest, instead stayed on full.

Well that's good at least! Maybe GitHub was having some weird SSL issues, not sure. Glad it's working for you now!