Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] 回复消息超时 #198

Closed
MQPearth opened this issue Mar 3, 2023 · 5 comments · Fixed by #200
Closed

[BUG] 回复消息超时 #198

MQPearth opened this issue Mar 3, 2023 · 5 comments · Fixed by #200
Labels
m: Provider OpenAI API 或其他 LLM 模型相关

Comments

@MQPearth
Copy link

MQPearth commented Mar 3, 2023

请认真按照实际情况填写以下信息!!!!

运行环境

  • 部署方式:
    手动部署
  • 系统环境:
    Ubuntu 20.04.5 LTS
  • Python环境(仅手动部署填写):
    Python 3.8.10

描述漏洞
什么时候发生的,mirai还是主程序,越详细越好

完整报错信息

使用qq向机器人发送消息

2023-03-03 09:39:44 - INFO     [WebSocket] 成功登录到账号xxxx。
[2023-03-03 09:39:44.364] websocket.py (194) - [INFO] : [WebSocket] 成功登录到账号xxxx。
2023-03-03 09:39:44 - INFO     [WebSocket] 机器人开始运行。按 Ctrl + C 停止。
[2023-03-03 09:39:44.364] websocket.py (250) - [INFO] : [WebSocket] 机器人开始运行。按 Ctrl + C 停止。
[2023-03-03 09:39:56.158] main.py (232) - [INFO] : 程序启动完成,如长时间未显示 ”成功登录到账号xxxxx“ ,并且不回复消息,请
查看 https://github.com/RockChinQ/QChatGPT/issues/37
[2023-03-03 09:40:01.376] connectionpool.py (744) - [WARNING] : Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')])"))': /RockChinQ/QChatGPT/info/refs?service=git-upload-pack
[2023-03-03 09:40:01.586] connectionpool.py (744) - [WARNING] : Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')])"))': /RockChinQ/QChatGPT/info/refs?service=git-upload-pack
[2023-03-03 09:40:01.783] connectionpool.py (744) - [WARNING] : Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')])"))': /RockChinQ/QChatGPT/info/refs?service=git-upload-pack
[2023-03-03 09:40:01.989] main.py (266) - [WARNING] : 检查更新失败:HTTPSConnectionPool(host='github.com', port=443): Max retries exceeded with url: /RockChinQ/QChatGPT/info/refs?service=git-upload-pack (Caused by SSLError(SSLError("bad handshake: Error([('SSL routines', 'tls_process_server_certificate', 'certificate verify failed')])")))
[2023-03-03 09:41:21.348] message.py (28) - [INFO] : [person_xxxx]发送消息:test
[2023-03-03 09:41:51.449] manager.py (235) - [WARNING] : person_xxxx: 超时,重试中(0)
[2023-03-03 09:41:51.450] message.py (28) - [INFO] : [person_xxxx]发送消息:test
[2023-03-03 09:42:21.552] manager.py (235) - [WARNING] : person_xxxx: 超时,重试中(1)
[2023-03-03 09:42:21.553] message.py (28) - [INFO] : [person_xxxx]发送消息:test
[2023-03-03 09:42:51.654] manager.py (235) - [WARNING] : person_xxxx: 超时,重试中(2)
[2023-03-03 09:42:51.654] manager.py (307) - [INFO] : 通知管理员:person_xxxx 请求超时
@RockChinQ
Copy link
Owner

openai接口被墙了,请尝试使用代理或更换境外主机,或等待近期敏感时期结束

@RockChinQ RockChinQ added the m: Provider OpenAI API 或其他 LLM 模型相关 label Mar 3, 2023
@RockChinQ
Copy link
Owner

即将支持正向代理以解决此问题 #200

@RockChinQ RockChinQ linked a pull request Mar 3, 2023 that will close this issue
@MQPearth
Copy link
Author

MQPearth commented Mar 3, 2023

使用 proxychains 报错

proxychains python3 main.py
[proxychains] Dynamic chain  ...  127.0.0.1:7891  ...  ::1:10121  ...  OK
2023-03-03 15:12:21 - ERROR    did not receive a valid HTTP response
[2023-03-03 15:12:21.272] base.py (43) - [ERROR] : did not receive a valid HTTP response
[2023-03-03 15:12:21.273] main.py (217) - [ERROR] : mirai-api-http端口无法使用:did not receive a valid HTTP response, 解决方案: https://github.com/RockChinQ/QChatGPT/issues/22

与目前不支持代理配置有关吗

@RockChinQ
Copy link
Owner

请等待 #200 合并

@RockChinQ
Copy link
Owner

RockChinQ commented Mar 3, 2023

现已支持配置openai代理以使国内主机也能通过网络代理访问OpenAI接口
请更新主程序,并在主机上运行网络代理软件,并允许通过http进行代理
例如使用ClashForWindows进行代理
image
设置Port并启用Allow LAN

然后参考config-template.pyopenai_config字段的注释,在config.pyopenai_config字段中增加http_proxy字段填写你的代理地址

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
m: Provider OpenAI API 或其他 LLM 模型相关
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants