Closed piotr25691 closed 7 months ago
The bot errors out and disconnects after sending messages.
No response
Should’ve not disconnected
Errors are happening:
Exception in callback Task.task_wakeup(<Future finished result=None>) 8|clyde | handle: <Handle Task.task_wakeup(<Future finished result=None>)> 8|clyde | Traceback (most recent call last): 8|clyde | File "/usr/lib/python3.11/asyncio/events.py", line 80, in _run 8|clyde | self._context.run(self._callback, *self._args) 8|clyde | RuntimeError: Cannot enter into task <Task pending name='Task-1' coro=<Client.run.<locals>.runner() running at /root/runner/public/clyde/clyde-venv/lib/python3.11/site-packages/discord/client.py:1048> wait_for=<Future finished result=None> cb=[_run_until_complete_cb() at /usr/lib/python3.11/asyncio/base_events.py:180]> while another task <Task pending name='discord.py: on_message' coro=<Client._run_event() running at /root/runner/public/clyde/clyde-venv/lib/python3.11/site-packages/discord/client.py:600>> is being executed. 8|clyde | [2023-11-20 19:36:33] [WARNING ] discord.gateway: Gateway has stopped responding. Closing and restarting.
Mind I tell you, I was querying ChatGPT with the bot, was the library blocking the bot causing it to disconnect?
Alright fixed it, discovered that async tasks were blocking each other
Summary
The bot errors out and disconnects after sending messages.
Reproduction Steps
Code
No response
Expected Results
Should’ve not disconnected
Actual Results
Errors are happening:
System Information
Checklist
Additional Information
No response