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

部署完成后,提示"提交的数据不合法" #34

Closed
hunhun010164 opened this issue Aug 9, 2023 · 14 comments
Closed

部署完成后,提示"提交的数据不合法" #34

hunhun010164 opened this issue Aug 9, 2023 · 14 comments

Comments

@hunhun010164
Copy link

完成后,打开网页,提示"提交的数据不合法",且微信公众号里无论开启服务器还是停止服务器,一样的报错,麻烦看一下,谢谢

@ilyydy
Copy link
Owner

ilyydy commented Aug 10, 2023

你用的哪种部署方式?这个错误可能的原因有好几种,还需要日志进一步确定。
你可以在 cloudflare 开启日志流,然后给公众号发消息,把日志发给我。也可以部署最新版本 0.4.2,开启 DEBUG_MODE并且建一个企业微信群机器人配置到告警 URL。这样所有日志都会发到企业微信群。

屏幕截图 2023-08-10 230725

@hunhun010164
Copy link
Author

你用的哪种部署方式?这个错误可能的原因有好几种,还需要日志进一步确定。 你可以在 cloudflare 开启日志流,然后给公众号发消息,把日志发给我。也可以部署最新版本 0.4.2,开启 DEBUG_MODE并且建一个企业微信群机器人配置到告警 URL。这样所有日志都会发到企业微信群。

屏幕截图 2023-08-10 230725

谢谢.域名和ID改了下,其他没动

OK GET https://mydomain/openai/wechat/test 8/11/2023 11:38:57AM

{
"outcome": "ok",
"scriptName": "hello-world-long-mountain-c56b",
"diagnosticsChannelEvents": [],
"exceptions": [],
"logs": [],
"eventTimestamp": 1691717937264,
"event": {
"request": {
"url": "https://mydomain/openai/wechat/test",
"method": "GET",
"headers": {
"accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,/;q=0.8,application/signed-exchange;v=b3;q=0.7",
"accept-encoding": "gzip",
"accept-language": "en-US,en;q=0.9",
"cache-control": "max-age=0",
"cf-connecting-ip": "60.242.21.22",
"cf-ipcountry": "AU",
"cf-ray": "7f4cc313dc79a819",
"cf-visitor": "{"scheme":"https"}",
"connection": "Keep-Alive",
"host": "mydomain",
"sec-ch-ua": ""Chromium";v="112", "Google Chrome";v="112", "Not:A-Brand";v="99"",
"sec-ch-ua-mobile": "?0",
"sec-ch-ua-platform": ""Windows"",
"sec-fetch-dest": "document",
"sec-fetch-mode": "navigate",
"sec-fetch-site": "none",
"sec-fetch-user": "?1",
"upgrade-insecure-requests": "1",
"user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/112.0.0.0 Safari/537.36",
"x-forwarded-proto": "https",
"x-real-ip": "60.242.21.22"
},
"cf": {
"clientTcpRtt": 5,
"longitude": "151.20060",
"latitude": "-33.87150",
"tlsCipher": "AEAD-AES128-GCM-SHA256",
"continent": "OC",
"asn": 7545,
"clientAcceptEncoding": "gzip, deflate, br",
"country": "AU",
"tlsClientAuth": {
"certIssuerDNLegacy": "",
"certIssuerSKI": "",
"certSubjectDNRFC2253": "",
"certSubjectDNLegacy": "",
"certFingerprintSHA256": "",
"certNotBefore": "",
"certSKI": "",
"certSerial": "",
"certIssuerDN": "",
"certVerified": "NONE",
"certNotAfter": "",
"certSubjectDN": "",
"certPresented": "0",
"certRevoked": "0",
"certIssuerSerial": "",
"certIssuerDNRFC2253": "",
"certFingerprintSHA1": ""
},
"tlsExportedAuthenticator": {
"clientFinished": "62dbd94f0d884fa865c60f2a52b5c7bd413c7468361841c970c63d99cd9b195f",
"clientHandshake": "175579e21e2d0b51ea6d8c7f96fa43bc181348b2f493d312ff558efb183d8843",
"serverHandshake": "1c39bec9a5a7424fc170754319e8aac6353b78c3732339ba71889d68fb79170b",
"serverFinished": "d497756f13bce0adf86bb43fd33c941f07b90c02f098f98d164bb890cb2306c1"
},
"tlsVersion": "TLSv1.3",
"colo": "SYD",
"timezone": "Australia/Sydney",
"city": "Sydney",
"edgeRequestKeepAliveStatus": 1,
"requestPriority": "weight=256;exclusive=1",
"httpProtocol": "HTTP/2",
"region": "New South Wales",
"regionCode": "NSW",
"asOrganization": "TPG Internet",
"postalCode": "2000"
}
},
"response": {
"status": 200
}
},
"id": 1
}

@hunhun010164
Copy link
Author

我是用cloudflare的方式部署的.
我之前部署的0.4.1.现在部署0.4.2,是不是只要替换index.mini.js里的内容到cloudflare上即可?另外,如何开启DEBUG_MODE呢?请赐教,谢谢

@ilyydy
Copy link
Owner

ilyydy commented Aug 11, 2023

感觉你好像用错了。我这个服务是没有网页的,你说的打开网页是这个链接吗?如果正常部署,在浏览器打开这个链接会显示当前时间

屏幕截图 2023-08-11 232508

屏幕截图 2023-08-11 232728

@ilyydy
Copy link
Owner

ilyydy commented Aug 11, 2023

我是用cloudflare的方式部署的. 我之前部署的0.4.1.现在部署0.4.2,是不是只要替换index.mini.js里的内容到cloudflare上即可?另外,如何开启DEBUG_MODE呢?请赐教,谢谢

对,复制替换就可以

屏幕截图 2023-08-11 233215

@hunhun010164
Copy link
Author

感觉你好像用错了。我这个服务是没有网页的,你说的打开网页是这个链接吗?如果正常部署,在浏览器打开这个链接会显示当前时间

屏幕截图 2023-08-11 232508

屏幕截图 2023-08-11 232728

对,如果浏览器只是打开https://mydomain/
是显示当前时间的:
2023-08-12T01:07:08.821Z hello world

我如果用浏览器打开https://mydomain/openai/wechat/test
才显示"提交的数据不合法",莫非部署已经成功了?是我使用的姿势不对?还请赐教,谢谢

@ilyydy
Copy link
Owner

ilyydy commented Aug 12, 2023

感觉你好像用错了。我这个服务是没有网页的,你说的打开网页是这个链接吗?如果正常部署,在浏览器打开这个链接会显示当前时间
屏幕截图 2023-08-11 232508
屏幕截图 2023-08-11 232728

对,如果浏览器只是打开https://mydomain/ 是显示当前时间的: 2023-08-12T01:07:08.821Z hello world

我如果用浏览器打开https://mydomain/openai/wechat/test 才显示"提交的数据不合法",莫非部署已经成功了?是我使用的姿势不对?还请赐教,谢谢

那说明你已经把服务部署好了。浏览器打开https://mydomain/openai/wechat/test 是没用的,这个地址不是给浏览器用的。你要在微信里给绑定的微信公众号发消息,比如发 /help

@ilyydy
Copy link
Owner

ilyydy commented Aug 12, 2023

发 /help 效果是这样

IMG_20230812_093632

@hunhun010164
Copy link
Author

发 /help 效果是这样

IMG_20230812_093632

谢谢,试了试,help指令正常
help

但其他指令貌似不能识别,麻烦看一下,谢谢
chat

@ilyydy
Copy link
Owner

ilyydy commented Aug 13, 2023

发 /help 效果是这样
IMG_20230812_093632

谢谢,试了试,help指令正常 help

但其他指令貌似不能识别,麻烦看一下,谢谢 chat

有试过 /testkey 这个命令吗,看 openai key 配置好没有

@hunhun010164
Copy link
Author

试了下,收到回复:
正在处理中,请稍后输入 .. 或以下命令获取回答
/retry 24222470899430138

@ilyydy
Copy link
Owner

ilyydy commented Aug 14, 2023

试了下,收到回复: 正在处理中,请稍后输入 .. 或以下命令获取回答 /retry 24222470899430138

很奇怪,看起来都超时了。没有日志不太好确定哪一步慢了。你抓一下 /testkey 的日志看看

@hunhun010164

This comment was marked as resolved.

@ilyydy
Copy link
Owner

ilyydy commented Aug 15, 2023

@hunhun010164 有2个问题

  1. 你的 openai key 有问题用不了,调用 openai 接口失败 {"message":"You exceeded your current quota, please check your plan and billing details.","type":"insufficient_quota","param":null,"code":"insufficient_quota"}。

因为你的 API 账户没有余额,或者余额过期了,你需要给账户绑定海外信用卡才能继续使用。,
Bin-Huang/chatbox#717 (comment)

  1. 你需要再更新一下最新版本,之前加的告警有点问题,会导致ExceededCpu

@ilyydy ilyydy closed this as completed Aug 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants