chatgpt-on-wechat icon indicating copy to clipboard operation
chatgpt-on-wechat copied to clipboard

error 111错误 “我连接不到你的网络‘

Open lukiugi opened this issue 9 months ago • 8 comments

前置确认

  • [X] 我确认我运行的是最新版本的代码,并且安装了所需的依赖,在FAQS中也未找到类似问题。

⚠️ 搜索issues中是否已存在类似问题

  • [X] 我已经搜索过issues和disscussions,没有跟我遇到的问题相关的issue

操作系统类型?

Windows

运行的python版本是?

python 3.7

使用的chatgpt-on-wechat版本是?

Latest Release

运行的channel类型是?

wxy(个人微信, wechaty)

复现步骤 🕹

chatgpt-on-wechat | [INFO][2024-04-29 11:35:28][chat_gpt_bot.py:49] - [CHATGPT] query=你好

问题描述 😯

(1)在clash的规则模式下,PAC模式已开 chatgpt-on-wechat | [WARNING][2024-04-29 11:35:28][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456ed49f30>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [WARNING][2024-04-29 11:35:33][chat_gpt_bot.py:160] - [CHATGPT] 第1次重试 chatgpt-on-wechat | [WARNING][2024-04-29 11:35:33][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456ed49720>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [WARNING][2024-04-29 11:35:38][chat_gpt_bot.py:160] - [CHATGPT] 第2次重试 chatgpt-on-wechat | [WARNING][2024-04-29 11:35:38][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456e219f30>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [INFO][2024-04-29 11:35:38][wechat_channel.py:217] - [WX] sendMsg=Reply(type=ERROR, content=[ERROR] chatgpt-on-wechat | 我连接不到你的网络), receiver=@b6a2f363f5d533dc8ae2653461ebc578043d37fb1f5d1486a1f8c83cffce7ed (2)先扫码登陆后开启clash全局模式下的反馈 [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe110fdbc10>: Failed to establish a new connection: [Errno 111] Connection refused')))

终端日志 📒

(1) chatgpt-on-wechat | [WARNING][2024-04-29 11:35:28][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456ed49f30>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [WARNING][2024-04-29 11:35:33][chat_gpt_bot.py:160] - [CHATGPT] 第1次重试 chatgpt-on-wechat | [WARNING][2024-04-29 11:35:33][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456ed49720>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [WARNING][2024-04-29 11:35:38][chat_gpt_bot.py:160] - [CHATGPT] 第2次重试 chatgpt-on-wechat | [WARNING][2024-04-29 11:35:38][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456e219f30>: Failed to establish a new connection: [Errno 111] Connection refused'))) chatgpt-on-wechat | [INFO][2024-04-29 11:35:38][wechat_channel.py:217] - [WX] sendMsg=Reply(type=ERROR, content=[ERROR] chatgpt-on-wechat | 我连接不到你的网络), receiver=@b6a2f363f5d533dc8ae2653461ebc578043d37fb1f5d1486a1f8c83cffce7ed (2) [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe110fdbc10>: Failed to establish a new connection: [Errno 111] Connection refused')))

lukiugi avatar Apr 29 '24 11:04 lukiugi

看看你的open_ai_api_base的键值对 是不是正确的。

Wanghh666 avatar Apr 30 '24 09:04 Wanghh666

我也是这个问题

sugar-orange666 avatar Apr 30 '24 13:04 sugar-orange666

看看你的open_ai_api_base的键值对 是不是正确的。

我之前用的是docker部署,只配置了proxy,没配置base,现在用了个服务器域名来做base 2024-04-30 21:12:01 [WARNING][2024-04-30 13:12:01][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', OSError('Tunnel connection failed: 400 Bad Request'))) 又另外报错

lukiugi avatar Apr 30 '24 13:04 lukiugi

这是我的docker配置文件

lukiugi avatar Apr 30 '24 14:04 lukiugi

企业微信截图_17144857582472

lukiugi avatar Apr 30 '24 14:04 lukiugi

chatgpt-on-wechat | [WARNING][2024-04-29 11:35:28][chat_gpt_bot.py:150] - [CHATGPT] APIConnectionError: Error communicating with OpenAI: HTTPSConnectionPool(host='api.openai.com', port=443): Max retries exceeded with url: /v1/chat/completions (Caused by ProxyError('Unable to connect to proxy', NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f456ed49f30>: Failed to establish a new connection: [Errno 111] Connection refused'))) GPT: 这个警告说明在与 OpenAI 通信时,尝试连接代理时出现了连接拒绝的错误(Connection refused)。这可能是由于代理设置错误、代理服务器不可用或网络问题等原因导致的。 应该是代理的设置问题,但是不知道问题出现在哪里

lukiugi avatar Apr 30 '24 14:04 lukiugi

我的docker配置如下,能够正常运行使用,可以试下把base最后后面的/去掉? image

sbcxk avatar May 01 '24 10:05 sbcxk

我也是这个问题,在open_ai_api_base改好了base_url,不管怎么弄都会转到api.openai.com上面去。

Neoisava avatar May 14 '24 15:05 Neoisava