During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 680, in __await_impl__
await protocol.wait_closed()
asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.9/asyncio/tasks.py", line 490, in wait_for
return fut.result()
asyncio.exceptions.CancelledError
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/local/lib/python3.9/threading.py", line 980, in _bootstrap_inner
self.run()
File "/usr/local/lib/python3.9/threading.py", line 917, in run
self._target(self._args, self._kwargs)
File "/bot/main.py", line 186, in run_bot_wrapper
raise e
File "/bot/main.py", line 148, in run_bot_wrapper
qqbot.bot.run()
File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 199, in run
MiraiRunner(self).run(host, port, asgi_server, kwargs)
File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 276, in run
asyncio.run(self._run())
File "/usr/local/lib/python3.9/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/usr/local/lib/python3.9/asyncio/base_events.py", line 647, in run_until_complete
return future.result()
File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 240, in _run
await self.startup()
File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 228, in startup
await asyncio.gather(coros)
File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 137, in startup
await self._adapter.login(self.qq)
File "/usr/local/lib/python3.9/site-packages/mirai/adapters/base.py", line 35, in wrapped
return await func(self, *args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/mirai/adapters/websocket.py", line 187, in login
self.connection = await connect(self.host_name, extra_headers=headers)
File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 659, in await_impl_timeout
return await asyncio.wait_for(self.__await_impl__(), self.open_timeout)
File "/usr/local/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
ERROR: 1
运行环境
描述漏洞
主程序 在启动一段时间后便报错并退出
完整报错信息
2023-02-19 06:09:05 - WARNING 未找到可用的 ASGI 服务,反向 WebSocket 和 WebHook 上报将不可用。 仅 HTTP 轮询与正向 WebSocket 可用。 建议安装 ASGI 服务器,如
uvicorn
或hypercorn
。 在命令行键入: pip install uvicorn 或者 pip install hypercorn WARNING: 未找到可用的 ASGI 服务,反向 WebSocket 和 WebHook 上报将不可用。 仅 HTTP 轮询与正向 WebSocket 可用。 建议安装 ASGI 服务器,如uvicorn
或hypercorn
。 在命令行键入: pip install uvicorn 或者 pip install hypercorn [2023-02-19 06:09:05.358] bot.py (262) - [WARNING] : 未找到可用的 ASGI 服务,反向 WebSocket 和 WebHook 上报将不可用。 仅 HTTP 轮询与正向 WebSocket 可用。 建议安装 ASGI 服务器,如uvicorn
或hypercorn
。 在命令行键入: pip install uvicorn 或者 pip install hypercorn 2023-02-19 06:09:15 - ERRORERROR: [2023-02-19 06:09:15.394] base.py (43) - [ERROR] : ERROR: 捕捉到未知异常:, 请前往 https://github.com/RockChinQ/QChatGPT/issues 查找或提issue [2023-02-19 06:09:15.409] main.py (183) - [ERROR] : 捕捉到未知异常:, 请前往 https://github.com/RockChinQ/QChatGPT/issues 查找或提issue Exception in thread Thread-2: Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 666, in __await_impl__ await protocol.handshake( File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 332, in handshake raise InvalidStatusCode(status_code, response_headers) websockets.exceptions.InvalidStatusCode: server rejected WebSocket connection: HTTP 404
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 680, in __await_impl__ await protocol.wait_closed() asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/usr/local/lib/python3.9/asyncio/tasks.py", line 490, in wait_for return fut.result() asyncio.exceptions.CancelledError
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/local/lib/python3.9/threading.py", line 980, in _bootstrap_inner self.run() File "/usr/local/lib/python3.9/threading.py", line 917, in run self._target(self._args, self._kwargs) File "/bot/main.py", line 186, in run_bot_wrapper raise e File "/bot/main.py", line 148, in run_bot_wrapper qqbot.bot.run() File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 199, in run MiraiRunner(self).run(host, port, asgi_server, kwargs) File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 276, in run asyncio.run(self._run()) File "/usr/local/lib/python3.9/asyncio/runners.py", line 44, in run return loop.run_until_complete(main) File "/usr/local/lib/python3.9/asyncio/base_events.py", line 647, in run_until_complete return future.result() File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 240, in _run await self.startup() File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 228, in startup await asyncio.gather(coros) File "/usr/local/lib/python3.9/site-packages/mirai/bot.py", line 137, in startup await self._adapter.login(self.qq) File "/usr/local/lib/python3.9/site-packages/mirai/adapters/base.py", line 35, in wrapped return await func(self, *args, **kwargs) File "/usr/local/lib/python3.9/site-packages/mirai/adapters/websocket.py", line 187, in login self.connection = await connect(self.host_name, extra_headers=headers) File "/usr/local/lib/python3.9/site-packages/websockets/legacy/client.py", line 659, in await_impl_timeout return await asyncio.wait_for(self.__await_impl__(), self.open_timeout) File "/usr/local/lib/python3.9/asyncio/tasks.py", line 492, in wait_for raise exceptions.TimeoutError() from exc asyncio.exceptions.TimeoutError ERROR: 1