Chanzhaoyu / chatgpt-web

用 Express 和 Vue3 搭建的 ChatGPT 演示网页
MIT License
31.45k stars 11.21k forks source link

用https://bypass.churchless.tech/api/conversation 提示fetch failed了 #1078

Closed bluefrankey closed 1 year ago

wujt1084 commented 1 year ago

自己搭代理要如何使用?

xiaodou435 commented 1 year ago

今天突然这样了,搞的很懵逼

jack331200 commented 1 year ago

是的,提示如下错误 undefined [ChatGPTUnofficialProxyAPI.sendMessage: conversationId and parentMessageId must both be set or both be undefined]

1205129045x commented 1 year ago

我刚刚使用https://api.pawan.krd/backend-api/conversation这个也不行

wydweb commented 1 year ago

我刚刚使用这个也不行https://api.pawan.krd/backend-api/conversation

我用的这个可以,[@acheong08]的就不行

luckzack commented 1 year ago

https://api.pawan.krd/backend-api/conversation 这个限频太厉害了

runningwa commented 1 year ago

不能去掉吗?不走代理不行吗?

fishslidenas commented 1 year ago

是的,有时候得半分钟才有响应,我还以为死机了

fishslidenas commented 1 year ago

不能去掉吗?不走代理不行吗?

accesstoken必须要有反向代理啊

runningwa commented 1 year ago

必须吗?为啥我自己做的flask 就不用反向代理呢,自己nginx 搭一个是否可行?

jack331200 commented 1 year ago

accesstoken 不走反代可以吗? 这是直接部署在外面的机器上的。

fishslidenas commented 1 year ago

看大神的教程必须走。是api的代理,不是页面的代理

lqqkk commented 1 year ago

今天突然这样了,搞的很懵逼

兄弟找到解决方案了吗?

acheong08 commented 1 year ago

我刚刚使用这个也不行https://api.pawan.krd/backend-api/conversation

我用的这个可以,[@acheong08]的就不行

出了什么问题?

acheong08 commented 1 year ago

是不是 CORS error?

lqqkk commented 1 year ago

TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11413:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at fetchSSE (/app/node_modules/.pnpm/chatgpt@5.0.10/node_modules/chatgpt/build/index.js:46:15) { cause: Error: unable to verify the first certificate at TLSSocket.onConnectSecure (node:_tls_wrap:1540:34) at TLSSocket.emit (node:events:513:28) at TLSSocket.emit (node:domain:489:12) at TLSSocket._finishInit (node:_tls_wrap:959:8) at ssl.onhandshakedone (node:_tls_wrap:743:12) { code: 'UNABLE_TO_VERIFY_LEAF_SIGNATURE'

acheong08 commented 1 year ago

Check dig bypass.churchless.tech. 有可能是 DNS poisoning

acheong08 commented 1 year ago

SSL is managed by Cloudflare. Is cloudflare blocked?

leilif commented 1 year ago

same problem

weilai-all commented 1 year ago

Check dig bypass.churchless.tech. 有可能是 DNS poisoning

一直用大佬的代理,反正我这一直没问题,大几率dns被污染了。

wuuuyifan commented 1 year ago

大佬们 我这边用的APIkey 在测试的时候也反馈fetch failed

lie5860 commented 1 year ago

+1,一定要重试两三次才行。

KaranaLJX commented 1 year ago

是的,提示如下错误 undefined [ChatGPTUnofficialProxyAPI.sendMessage: conversationId and parentMessageId must both be set or both be undefined]

这个是你传参问题?

wuuuyifan commented 1 year ago

TypeError: fetch failed cause: ConnectTimeoutError: Connect Timeout Error code: 'UND_ERR_CONNECT_TIMEOUT' 大佬们 测试了一下 反馈是这个样子 是我的代理有问题吗

KaranaLJX commented 1 year ago

我的是这个错误 TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11413:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at fetchSSE (/app/node_modules/.pnpm/chatgpt@5.1.2/node_modules/chatgpt/build/index.js:46:15) { cause: Error: connect ECONNREFUSED 127.0.0.1:443 at node_internal_captureLargerStackTrace (node:internal/errors:490:5) at node_internal_exceptionWithHostPort (node:internal/errors:668:12) at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '127.0.0.1', port: 443 }

dahaoGPT commented 1 year ago

我的也是,代理好像没绕过CF的墙

pavlelee commented 1 year ago

POST https://bypass.duti.tech/api/conversation { body: { action: 'next', messages: [ [Object] ], model: 'gpt-3.5-turbo', parent_message_id: '4f41068d-5d4f-49e4-9cd1-36f2987fa705' }, headers: { Authorization: 'Bearer ', Accept: 'text/event-stream', 'Content-Type': 'application/json' } } TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11413:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async fetchSSE (file:///app/node_modules/.pnpm/chatgpt@5.1.2/node_modules/chatgpt/build/index.js:46:15) { cause: Error: connect ECONNREFUSED 127.0.0.1:443 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '127.0.0.1', port: 443 } } 为什么是127.0.0.1:443,我直接curl是没问题的

curl https://bypass.churchless.tech/api/conversation -d '{"action":"next","messages":[{"id":"66d477c3-0929-4c1a-ae13-d05ce29534c6","author":{"role":"user"},"role":"user","content":{"content_type":"text","parts":["感冒吃什么"]}}],"parent_message_id":"84523d32-8aa6-4c43-832b-08fe79ce48de","model":"text-davinci-002-render-sha","timezone_offset_min":-480}' -H 'authorization: Bearer '

nicechin commented 1 year ago

POST https://bypass.duti.tech/api/conversation { body: { action: 'next', messages: [ [Object] ], model: 'gpt-3.5-turbo', parent_message_id: '4f41068d-5d4f-49e4-9cd1-36f2987fa705' }, headers: { Authorization: 'Bearer ', Accept: 'text/event-stream', 'Content-Type': 'application/json' } } TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11413:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async fetchSSE (file:///app/node_modules/.pnpm/chatgpt@5.1.2/node_modules/chatgpt/build/index.js:46:15) { cause: Error: connect ECONNREFUSED 127.0.0.1:443 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1494:16) { errno: -111, code: 'ECONNREFUSED', syscall: 'connect', address: '127.0.0.1', port: 443 } } 为什么是127.0.0.1:443,我直接curl是没问题的

curl https://bypass.churchless.tech/api/conversation -d '{"action":"next","messages":[{"id":"66d477c3-0929-4c1a-ae13-d05ce29534c6","author":{"role":"user"},"role":"user","content":{"content_type":"text","parts":["感冒吃什么"]}}],"parent_message_id":"84523d32-8aa6-4c43-832b-08fe79ce48de","model":"text-davinci-002-render-sha","timezone_offset_min":-480}' -H 'authorization: Bearer '

好像是因域名过期(据说是某种不可抗拒原因)

KaranaLJX commented 1 year ago

老哥可以解释一下某种不可抗拒原因是啥意思(是我机器的问题还是代理的问题)吗,我看我的debug信息也是post了类似的请求

nicechin commented 1 year ago

这是老哥原话,nslookup解析就是指向本地了 For anyone who hasn't upgraded revChatGPT, please do so immediately. My domain name, [http://duti.tech], has expired and been taken over by an unknown entity.

KaranaLJX commented 1 year ago

dns被污染了,为什么直接curl却可以呢

bluefrankey commented 1 year ago

dns被污染了,为什么直接curl却可以呢

用curl试了 确实可以,这是为什么呢? 哪位大佬能解释一下?

wuuuyifan commented 1 year ago

大佬们 我本地搭了梯子 通过curl命令可以接收到 OpenAIAPI的回复,但是跟着这个开源项目做测试的话 终端的反馈如下: TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11413:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async fetchSSE (file:///Users/mac/Downloads/chatgpt-web-main/service/node_modules/.pnpm/chatgpt@5.1.2/node_modules/chatgpt/build/index.js:46:15) { cause: ConnectTimeoutError: Connect Timeout Error at onConnectTimeout (node:internal/deps/undici/undici:8380:28) at node:internal/deps/undici/undici:8338:50 at Immediate._onImmediate (node:internal/deps/undici/undici:8369:13) at process.processImmediate (node:internal/timers:476:21) { code: 'UND_ERR_CONNECT_TIMEOUT' } } 有大佬帮忙看看吗

CaoYunzhou commented 1 year ago

俺这里没啥问题,不过是用的serverless调用的API

terrywangt commented 1 year ago

怎么自己搭一个这个代理啊https://bypass.duti.tech/api/conversation,有教程吗。

zhangairen commented 1 year ago

104.21.8.183 bypass.duti.tech 手动加个hosts吧,我加完之后正常了

appotry commented 1 year ago

怎么自己搭一个这个代理啊https://bypass.duti.tech/api/conversation,有教程吗。

https://github.com/acheong08/ChatGPT-Proxy-V4 内置的是这个代理

PUID 需要plus账号才有,运行方法

export  ACCESS_TOKEN=***
export  PUID=***
./ChatGPT-Proxy-V4
MAXHONG commented 1 year ago

我修改完host,返回这个,有同样情况的大佬吗 undefined [[OpenAI] 服务器繁忙,请稍后再试 | Internal Server Error]

MAXHONG commented 1 year ago

我修改完host,返回这个,有同样情况的大佬吗 undefined [[OpenAI] 服务器繁忙,请稍后再试 | Internal Server Error]

可以了,重启下服务就行

everydoc commented 1 year ago

怎么自己搭一个这个代理啊https://bypass.duti.tech/api/conversation,有教程吗。

https://github.com/acheong08/ChatGPT-Proxy-V4 内置的是这个代理

PUID 需要plus账号才有,运行方法

export  ACCESS_TOKEN=***
export  PUID=***
./ChatGPT-Proxy-V4

我一直以为这个是可以白嫖的,原来始终是要有人开plus才行啊,感谢社区的大佬贡献!

acheong08 commented 1 year ago

Please merge!

jqtmviyu commented 1 year ago

104.21.8.183 bypass.duti.tech 手动加个hosts吧,我加完之后正常了

感谢, 在compose.yml下加入extra_hosts就ok了

ports:
      - 3002:3002
    extra_hosts:
      - "bypass.duti.tech:104.21.8.183"
s7word commented 1 year ago

是的,提示如下错误 undefined [ChatGPTUnofficialProxyAPI.sendMessage: conversationId and parentMessageId must both be set or both be undefined]

解决了吗

dahaoGPT commented 1 year ago

没有找到compose.yml文件,这个文件在哪个目录下的?

dahaoGPT commented 1 year ago

在docker-compose.yml文件下加入extra_hosts,还是报错 image