lobehub / lobe-chat

🤯 Lobe Chat - an open-source, modern-design AI chat framework. Supports Multi AI Providers( OpenAI / Claude 3 / Gemini / Ollama / Azure / DeepSeek), Knowledge Base (file upload / knowledge management / RAG ), Multi-Modals (Vision/TTS) and plugin system. One-click FREE deployment of your private ChatGPT/ Claude application.
https://chat-preview.lobehub.com
Other
40.95k stars 9.34k forks source link

[Bug] 知识库分块报错 #3775

Closed gray0128 closed 2 weeks ago

gray0128 commented 2 weeks ago

📦 部署环境

Docker

📌 软件版本

v1.15.12

💻 系统环境

Other Linux

🌐 浏览器

Chrome

🐛 问题描述

分块报错

界面报错如下

image

docker 内日志如下:

image

📷 复现步骤

No response

🚦 期望结果

No response

📝 补充信息

我在家里 nas 部署的 docker,通过内网穿透服务开放隧道到 vps,然后使用 vps 上的 1panel 反代,最后使用https进行访问。

lobehubbot commented 2 weeks ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


📦 Deployment environment

Docker

📌 Software version

v1.15.12

💻 System environment

Other Linux

🌐 Browser

Chrome

🐛 Problem description

Blocked error reporting

The interface error is as follows

image

The log in docker is as follows:

image

📷 Steps to reproduce

No response

🚦 Expected results

No response

📝 Supplementary information

I deployed docker on nas at home, opened a tunnel to the vps through the intranet penetration service, then used 1panel on the vps for reverse generation, and finally used https for access.

lobehubbot commented 2 weeks ago

👀 @gray0128

Thank you for raising an issue. We will investigate into the matter and get back to you as soon as possible. Please make sure you have given us as much context as possible.\ 非常感谢您提交 issue。我们会尽快调查此事,并尽快回复您。 请确保您已经提供了尽可能多的背景信息。

dosubot[bot] commented 2 weeks ago

Hey @gray0128! I'm here to help you squash bugs 🐞 Let's tackle this issue together!

I found a similar issue that might be relevant to your problem:

  1. [Bug] 上传文件分块失败 - This issue was closed and the solution was to remove an internal authentication layer that was causing the server's RPC call to fail [1].

  2. 请教各位大佬,文件分块失败 - This discussion suggests checking if Cloudflare (cf) shield or similar protection is enabled, which might be causing the issue [2].

The error message you are seeing, "[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly," indicates that there might be an issue with your app's public availability or proxy settings.

Given your deployment setup (NAS with Docker, internal network tunneling to VPS, and reverse proxy with HTTPS), here are a few steps you can take to troubleshoot:

  1. Check Public Availability: Ensure that your app is accessible publicly without any restrictions. Verify that the URL is correctly configured and reachable from the internet.

  2. Proxy Settings: Double-check your proxy settings. Ensure that the proxy URL is correctly set and that there are no SSL issues. You might need to configure the proxy settings in the ProviderConfig component and the environment configuration file src/config/llm.ts [3][4].

  3. SSL Configuration: The error logs indicate SSL issues (ERR_SSL_WRONG_VERSION_NUMBER). Ensure that your SSL certificates are correctly configured and that the SSL/TLS versions are compatible between your app and the proxy.

  4. Supported Models: The logs also mention that the model meta-llama/Meta-Llama-3.1-405B-Instruct is not supported. Verify that you are using supported models listed in src/libs/agent-runtime/togetherai/fixtures/models.json [5].

By addressing these points, you should be able to resolve the chunking error.

To continue talking to Dosu, mention @dosu.

ykangw commented 2 weeks ago

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

gray0128 commented 2 weeks ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

lobehubbot commented 2 weeks ago

✅ @gray0128

This issue is closed, If you have any questions, you can comment and reply.\ 此问题已经关闭。如果您有任何问题,可以留言并回复。

H-TTTTT commented 1 week ago

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

我的使用的zeabur一切都是正常的 但是我家里威联通nas就是不行,一直出问题,报错一致

H-TTTTT commented 1 week ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

能详细说一下解决的方法吗,我也是使用的nas我的是威联通,使用的是威联通自己的ddns和反向代理服务且使用了ssl,但是我只有公网ipv6不知道这个有没有影响

gray0128 commented 1 week ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

能详细说一下解决的方法吗,我也是使用的nas我的是威联通,使用的是威联通自己的ddns和反向代理服务且使用了ssl,但是我只有公网ipv6不知道这个有没有影响

我是 NAS 与 VPS 建了转发隧道,在 VPS 做的反代,可能隧道用来加密的证书影响了。反正现在 NAS 本地用 lucky 反代是正常的。我也公网 ipv6

lobehubbot commented 1 week ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


It should be related to my network structure, a self-signed certificate for the tunnel from NAS to VPS. Now I switch to using the anti-generation service directly on the NAS, and it's normal.

Encountered the same error. The error message is: [TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly. I deployed with Vercel, set up Azure SSO login, S3 and PostSQL were deployed correctly, login, Functions such as conversations and uploading pictures are normal, only file segmentation errors are reported.

Brother, take a look again.

Can you tell me the solution in detail? I also use nas. My QNAP is QNAP. I use QNAP’s own ddns and reverse proxy service and use SSL, but I only have public network IPv6. I don’t know if this is available. Influence

I have a forwarding tunnel built between NAS and VPS, and the reverse generation on the VPS may be affected by the certificate used for encryption in the tunnel. Anyway, it is now normal for NAS to use lucky reverse generation locally. I also have public network ipv6

H-TTTTT commented 1 week ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

能详细说一下解决的方法吗,我也是使用的nas我的是威联通,使用的是威联通自己的ddns和反向代理服务且使用了ssl,但是我只有公网ipv6不知道这个有没有影响

我是 NAS 与 VPS 建了转发隧道,在 VPS 做的反代,可能隧道用来加密的证书影响了。反正现在 NAS 本地用 lucky 反代是正常的。我也公网 ipv6

感谢大佬的回复,我这边同样是使用的威联通自己的反向代理,但是还是不行,折腾了快1周了 而且lobe-chat的部署文档是分为本地部署和生产环境部署的 我的本地部署是可以分块成功的 但是我的生产环境部署方式我折腾了很久一直分块不成功,我是使用的nas自带的反向代理,所有的env和yml地址都是https+域名+端口的方式,不知道跟你是否一致。

请问你使用威联通自带的反向代理的时候使用的是https协议吗?

这两个值

谢谢~

lobehubbot commented 1 week ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


It should be related to my network structure, a self-signed certificate for the tunnel from NAS to VPS. Now I switch to using the anti-generation service directly on the NAS, and it's normal.

Encountered the same error. The error message is: [TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly. I deployed with Vercel, set up Azure SSO login, S3 and PostSQL were deployed correctly, login, Functions such as conversations and uploading pictures are normal, only file segmentation errors are reported.

Brother, take a look again.

Can you tell me the solution in detail? I also use nas. My QNAP is QNAP. I use QNAP’s own ddns and reverse proxy service and use SSL, but I only have public network IPv6 and I don’t know if this works. no impact

I have a forwarding tunnel built between NAS and VPS. When doing reverse generation on VPS, the certificate used for encryption in the tunnel may be affected. Anyway, it is now normal for NAS to use lucky reverse generation locally. I also have public network ipv6

Thanks for the reply. I am also using QNAP’s own reverse proxy, but it still doesn’t work. I’ve been struggling for almost a week. Moreover, the deployment documents of lobe-chat are divided into local deployment and production environment deployment. My local deployment can be successful in chunks But I have struggled with the deployment method of my production environment for a long time and have been unsuccessful in blocking. I use the reverse proxy that comes with NAS. All env and yml addresses are https+domain name+port. I don’t know if it is consistent with yours. .

Are you using the https protocol when using QNAP’s built-in reverse proxy?

These two values

Thank you~

gray0128 commented 1 week ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

能详细说一下解决的方法吗,我也是使用的nas我的是威联通,使用的是威联通自己的ddns和反向代理服务且使用了ssl,但是我只有公网ipv6不知道这个有没有影响

我是 NAS 与 VPS 建了转发隧道,在 VPS 做的反代,可能隧道用来加密的证书影响了。反正现在 NAS 本地用 lucky 反代是正常的。我也公网 ipv6

感谢大佬的回复,我这边同样是使用的威联通自己的反向代理,但是还是不行,折腾了快1周了 而且lobe-chat的部署文档是分为本地部署和生产环境部署的 我的本地部署是可以分块成功的 但是我的生产环境部署方式我折腾了很久一直分块不成功,我是使用的nas自带的反向代理,所有的env和yml地址都是https+域名+端口的方式,不知道跟你是否一致。

请问你使用威联通自带的反向代理的时候使用的是https协议吗?

这两个值 - 'S3_ENDPOINT=http://localhost:${MINIO_PORT}' - 'S3_PUBLIC_DOMAIN=http://localhost:${MINIO_PORT}' 你是怎么填写的是直接填写的域名还是填写的内网ip地址?

谢谢~

我用的 cloudflare 的 R2, S3_ENDPOIN填 cloudflare 提供的S3 API,注意不需要链接最后的桶名,这个部署文档里有提。S3_PUBLIC_DOMAIN填的自定义域,在 R2 里自己设置。我是 unraid 系统,没有用自建的 S3

image
lobehubbot commented 1 week ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


It should be related to my network structure, a self-signed certificate for the tunnel from NAS to VPS. Now I switch to using the anti-generation service directly on the NAS, and it's normal.

Encountered the same error. The error message is: [TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly. I deployed with Vercel, set up Azure SSO login, S3 and PostSQL were deployed correctly, login, Functions such as conversations and uploading pictures are normal, only file segmentation errors are reported.

Brother, take a look again.

Can you tell me the solution in detail? I also use nas. My QNAP is QNAP. I use QNAP’s own ddns and reverse proxy service and use SSL, but I only have public network IPv6 and don’t know this. Is there any impact?

I have a forwarding tunnel between NAS and VPS. When doing reverse generation on VPS, the certificate used for encryption in the tunnel may be affected. Anyway, it is now normal for NAS to use lucky reverse generation locally. I also have public network ipv6

Thanks for the reply. I am also using QNAP’s own reverse proxy, but it still doesn’t work. I have been struggling for almost a week and the deployment document of lobe-chat is divided into local deployment and production environment deployment. The local deployment can be successful in chunking. However, my production environment deployment method has been struggling for a long time and has been unsuccessful. I use the reverse proxy that comes with nas. All env and yml addresses are https+domain name+port. The method, I don’t know if it is consistent with yours.

When you use QNAP’s built-in reverse proxy, do you use the https protocol?

These two values ​​- 'S3_ENDPOINT=http://localhost:${MINIO_PORT}' - 'S3_PUBLIC_DOMAIN=http://localhost:${MINIO_PORT} ' How did you fill in the domain name directly or the intranet IP address?

Thank you~

I use cloudflare's R2, S3_ENDPOIN to fill in the S3 API provided by cloudflare. Note that the last bucket name of the link is not required. This is mentioned in the deployment document. The custom domain filled in S3_PUBLIC_DOMAIN is set by yourself in R2. I am an unraid system and do not use the self-built S3.

image
gray0128 commented 1 week ago

应该是跟我的网络结构有关系,NAS 到 VPS 的隧道用的自签证书。 现在换成直接使用 NAS 上的反代服务,正常了。

遇到相同的报错。 报错信息是:[TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly 我是用Vercel部署,设置了Azure SSO登陆,S3和PostSQL部署正确,登陆、对话、上传图片等功能都正常,只有文件分块报错。

兄弟你再看看吧。

能详细说一下解决的方法吗,我也是使用的nas我的是威联通,使用的是威联通自己的ddns和反向代理服务且使用了ssl,但是我只有公网ipv6不知道这个有没有影响

我是 NAS 与 VPS 建了转发隧道,在 VPS 做的反代,可能隧道用来加密的证书影响了。反正现在 NAS 本地用 lucky 反代是正常的。我也公网 ipv6

感谢大佬的回复,我这边同样是使用的威联通自己的反向代理,但是还是不行,折腾了快1周了 而且lobe-chat的部署文档是分为本地部署和生产环境部署的 我的本地部署是可以分块成功的 但是我的生产环境部署方式我折腾了很久一直分块不成功,我是使用的nas自带的反向代理,所有的env和yml地址都是https+域名+端口的方式,不知道跟你是否一致。

请问你使用威联通自带的反向代理的时候使用的是https协议吗?

这两个值 - 'S3_ENDPOINT=http://localhost:${MINIO_PORT}' - 'S3_PUBLIC_DOMAIN=http://localhost:${MINIO_PORT}' 你是怎么填写的是直接填写的域名还是填写的内网ip地址?

谢谢~

反代是 HTTPS,因为公司只有 ipv4,所以证书域名开了小黄云。

lobehubbot commented 1 week ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


It should be related to my network structure, a self-signed certificate for the tunnel from NAS to VPS. Now I switch to using the anti-generation service directly on the NAS, and it's normal.

Encountered the same error. The error message is: [TriggerError]: trigger file parse async task error. Please check your app is public available or check your proxy settings is set correctly. I deployed with Vercel, set up Azure SSO login, S3 and PostSQL were deployed correctly, login, Functions such as conversations and uploading pictures are normal, only file segmentation errors are reported.

Brother, take a look again.

Can you tell me the solution in detail? I also use nas. My QNAP is QNAP. I use QNAP’s own ddns and reverse proxy service and use SSL, but I only have public network IPv6 and don’t know this. Is there any impact?

I have a forwarding tunnel between NAS and VPS. When doing reverse generation on VPS, the certificate used for encryption in the tunnel may be affected. Anyway, it is now normal for NAS to use lucky reverse generation locally. I also have public network ipv6

Thanks for the reply. I am also using QNAP’s own reverse proxy, but it still doesn’t work. I have been struggling for almost a week and the deployment document of lobe-chat is divided into local deployment and production environment deployment. The local deployment can be successful in chunking. However, my production environment deployment method has been struggling for a long time and has been unsuccessful. I use the reverse proxy that comes with nas. All env and yml addresses are https+domain name+port. The method, I don’t know if it is consistent with yours.

When you use QNAP’s built-in reverse proxy, do you use the https protocol?

These two values ​​- 'S3_ENDPOINT=http://localhost:${MINIO_PORT}' - 'S3_PUBLIC_DOMAIN=http://localhost:${MINIO_PORT} ' How did you fill in the domain name directly or the intranet IP address?

Thank you~

The reverse generation is HTTPS. Because the company only has IPv4, the certificate domain name is opened in Xiaohuangyun.

H-TTTTT commented 6 days ago

Author

我这边问题都解决了,我最后也是上了cloudflare然后 zero trust 又买了域名做了DNS解析才搞定 官方文档的两个方式,一个本地版本,一个生产环境 这本地版本,直接本地使用是可以分块的一切正常。如果映射出去,第一个是鉴权那个跳转会有问题,紧接着s3也会有问题,你要是都反向代理出去,其实就成了生产环境的部署,还是不能分块 直接生产环境部署,就是之前说的分块不成功的问题 我最终发现这个生产环境所有的地址都必须是配置域名然后做代理才行,不能加端口,因为我威联通nas只有ipv6公网地址,所以用威联通公网ipv6地址做反向代理必须是加各种端口,但是这样就是会导致分块不成功 我上了cloudflare然后 zero trust 又买了域名做了做了透传才最终搞定,一切分块都正常 这时候我已经用了cloudflare r2 存储和 auth0鉴权,其实这时候本地用minio和logto也是可以成功的,不过就是要给他们的web还有api都要加域,就像文档里说的这样才可以,然后文件就可以进行分块了

lobehubbot commented 6 days ago

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Author

All the problems on my side were solved. I ended up using cloudflare and then using zero trust to buy a domain name and do DNS resolution. Two ways of official documentation, one local version and one production environment This local version can be divided into chunks for direct local use and everything will work fine. If mapped out, there will be a problem with the authentication jump first, and then there will be a problem with s3. If you reverse proxy them all, it will actually become a production environment deployment, and it still cannot be divided into chunks. Deploying directly to the production environment is the problem of unsuccessful chunking mentioned before. I finally found that all addresses in this production environment must be configured with domain names and then used as proxies. Ports cannot be added because my QNAP NAS only has IPv6 public network addresses, so using QNAP public IPv6 addresses as reverse proxy must be added. Various ports, but this will lead to unsuccessful chunking I went to cloudflare and then bought a domain name with zero trust and did transparent transmission before finally getting it done. Everything was divided into chunks normally. At this time, I have used cloudflare r2 storage and auth0 authentication. In fact, using minio and logto locally at this time can also be successful, but it is necessary to add domains to their web and api, as stated in the document. Yes, then the file can be divided into chunks