pygelbooru icon indicating copy to clipboard operation
pygelbooru copied to clipboard

not work on server

Open Toisoi opened this issue 2 years ago • 0 comments

I made a discord bot to search for images and uploaded it to repl.it. It doesn't work there. got error: Traceback (most recent call last): File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord_slash/client.py", line 1353, in invoke_command await func.invoke(ctx, **args) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/discord_slash/model.py", line 209, in invoke return await self.func(self.cog, *args, **kwargs) File "/home/runner/PYTHON-DISCORD-BOT/commands/image.py", line 70, in _random_image url = await parser.get_random_url(теги, теги_исключения) File "/home/runner/PYTHON-DISCORD-BOT/image_parser.py", line 32, in get_random_url return await gelbooru.random_post(tags=tags, exclude_tags=exclude_tags) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/pygelbooru/gelbooru.py", line 215, in random_post payload = await self._request(str(endpoint)) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/pygelbooru/gelbooru.py", line 395, in _request status_code, response = await self._fetch(session, url) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/pygelbooru/gelbooru.py", line 403, in _fetch async with session.get(url) as response: File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/client.py", line 1117, in __aenter__ self._resp = await self._coro File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/client.py", line 520, in _request conn = await self._connector.connect( File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/connector.py", line 535, in connect proto = await self._create_connection(req, traces, timeout) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/connector.py", line 892, in _create_connection _, proto = await self._create_direct_connection(req, traces, timeout) File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/connector.py", line 1051, in _create_direct_connection raise last_exc File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/connector.py", line 1020, in _create_direct_connection transp, proto = await self._wrap_create_connection( File "/opt/virtualenvs/python3/lib/python3.8/site-packages/aiohttp/connector.py", line 975, in _wrap_create_connection raise client_error(req.connection_key, exc) from exc aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gelbooru.com:443 ssl:default [Connect call failed ('0.0.0.0', 443)]

Toisoi avatar Mar 27 '22 11:03 Toisoi