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

🐛 fix: fix tencent cloud api issue #6058

Merged
merged 2 commits into from
Feb 12, 2025
Merged

Conversation

hedeqiang
Copy link
Contributor

@hedeqiang hedeqiang commented Feb 12, 2025

💻 变更类型 | Change Type

  • ✨ feat
  • 🐛 fix
  • ♻️ refactor
  • 💄 style
  • 👷 build
  • ⚡️ perf
  • 📝 docs
  • 🔨 chore

🔀 变更说明 | Description of Change

修复腾讯云调用问题,补充环境变量

📝 补充信息 | Additional Information

Copy link

vercel bot commented Feb 12, 2025

@hedeqiang is attempting to deploy a commit to the LobeHub Team on Vercel.

A member of the Team first needs to authorize it.

@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Feb 12, 2025
@lobehubbot
Copy link
Member

👍 @hedeqiang

Thank you for raising your pull request and contributing to our Community
Please make sure you have followed our contributing guidelines. We will review it as soon as possible.
If you encounter any problems, please feel free to connect with us.
非常感谢您提出拉取请求并为我们的社区做出贡献,请确保您已经遵循了我们的贡献指南,我们会尽快审查它。
如果您遇到任何问题,请随时与我们联系。

@dosubot dosubot bot added the 🐛 Bug Something isn't working | 缺陷 label Feb 12, 2025
@hedeqiang hedeqiang changed the title Tencentcloud fix: TencentCloud Feb 12, 2025
@hedeqiang
Copy link
Contributor Author

害,重复了...

@lobehubbot
Copy link
Member

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


Harm, repeated...

@arvinxx
Copy link
Contributor

arvinxx commented Feb 12, 2025

@hedeqiang 没事,你写的比我好。我把我的关了

@lobehubbot
Copy link
Member

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


@hedeqiang It's okay, you wrote better than me. I've shut down mine

@arvinxx arvinxx changed the title fix: TencentCloud 🐛 fix: fix tencent cloud api issue Feb 12, 2025
Copy link

vercel bot commented Feb 12, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
lobe-chat-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 12, 2025 2:14pm

Copy link

codecov bot commented Feb 12, 2025

Codecov Report

Attention: Patch coverage is 57.14286% with 6 lines in your changes missing coverage. Please review.

Project coverage is 92.18%. Comparing base (63b22ce) to head (e8bc19f).
Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
src/server/modules/AgentRuntime/index.ts 25.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6058      +/-   ##
==========================================
- Coverage   92.19%   92.18%   -0.01%     
==========================================
  Files         659      659              
  Lines       59757    59771      +14     
  Branches     4127     4326     +199     
==========================================
+ Hits        55091    55100       +9     
- Misses       4666     4671       +5     
Flag Coverage Δ
app 92.18% <57.14%> (-0.01%) ⬇️
server 98.01% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@arvinxx arvinxx merged commit 025d0bc into lobehub:main Feb 12, 2025
11 of 13 checks passed
@lobehubbot
Copy link
Member

❤️ Great PR @hedeqiang ❤️

The growth of project is inseparable from user feedback and contribution, thanks for your contribution! If you are interesting with the lobehub developer community, please join our discord and then dm @arvinxx or @canisminor1990. They will invite you to our private developer channel. We are talking about the lobe-chat development or sharing ai newsletter around the world.
项目的成长离不开用户反馈和贡献,感谢您的贡献! 如果您对 LobeHub 开发者社区感兴趣,请加入我们的 discord,然后私信 @arvinxx@canisminor1990。他们会邀请您加入我们的私密开发者频道。我们将会讨论关于 Lobe Chat 的开发,分享和讨论全球范围内的 AI 消息。

github-actions bot pushed a commit that referenced this pull request Feb 12, 2025
### [Version&nbsp;1.53.3](v1.53.2...v1.53.3)
<sup>Released on **2025-02-12**</sup>

#### 🐛 Bug Fixes

- **misc**: Fix tencent cloud api issue.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### What's fixed

* **misc**: Fix tencent cloud api issue, closes [#6058](#6058) ([025d0bc](025d0bc))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
@lobehubbot
Copy link
Member

🎉 This PR is included in version 1.53.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

github-actions bot pushed a commit to bentwnghk/lobe-chat that referenced this pull request Feb 13, 2025
### [Version&nbsp;1.95.2](v1.95.1...v1.95.2)
<sup>Released on **2025-02-13**</sup>

#### 🐛 Bug Fixes

- **misc**: Fix ai model abilities issue, fix latex in thinking tag render, fix not enable models correctly, fix tencent cloud api issue.

#### 💄 Styles

- **misc**: Update model list.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### What's fixed

* **misc**: Fix ai model abilities issue, closes [lobehub#6060](https://github.com/bentwnghk/lobe-chat/issues/6060) ([718f477](718f477))
* **misc**: Fix latex in thinking tag render, closes [lobehub#6063](https://github.com/bentwnghk/lobe-chat/issues/6063) ([7e89b2d](7e89b2d))
* **misc**: Fix not enable models correctly, closes [lobehub#6071](https://github.com/bentwnghk/lobe-chat/issues/6071) ([b78328e](b78328e))
* **misc**: Fix tencent cloud api issue, closes [lobehub#6058](https://github.com/bentwnghk/lobe-chat/issues/6058) ([025d0bc](025d0bc))

#### Styles

* **misc**: Update model list, closes [lobehub#6056](https://github.com/bentwnghk/lobe-chat/issues/6056) ([be0d7f6](be0d7f6))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
@hedeqiang hedeqiang deleted the tencentcloud branch February 13, 2025 13:12
AirboZH pushed a commit to yuanze-dev/lobe-chat that referenced this pull request Feb 14, 2025
* fix: tencentcloud

* fix: tencentcloud
AirboZH pushed a commit to yuanze-dev/lobe-chat that referenced this pull request Feb 14, 2025
### [Version&nbsp;1.53.3](lobehub/lobe-chat@v1.53.2...v1.53.3)
<sup>Released on **2025-02-12**</sup>

#### 🐛 Bug Fixes

- **misc**: Fix tencent cloud api issue.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### What's fixed

* **misc**: Fix tencent cloud api issue, closes [lobehub#6058](lobehub#6058) ([025d0bc](lobehub@025d0bc))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
@VincentSit
Copy link

环境变量并没有真正使用, 只是声明在这里, 这个是否可以修复一下. @hedeqiang

@lobehubbot
Copy link
Member

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


Environment variables are not really used, they just declare here, can this be fixed? @hedeqiang

@hedeqiang
Copy link
Contributor Author

环境变量并没有真正使用, 只是声明在这里, 这个是否可以修复一下. @hedeqiang

使用了的吧,我目前已经再用环境变量了,你是什么构建方式

@lobehubbot
Copy link
Member

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


Environment variables are not really used, just declared here, can this be fixed? @hedeqiang

I've used it, I've used environment variables now, what's your construction method

@VincentSit
Copy link

VincentSit commented Feb 14, 2025

环境变量并没有真正使用, 只是声明在这里, 这个是否可以修复一下. @hedeqiang

使用了的吧,我目前已经再用环境变量了,你是什么构建方式

你好, 我使用 Docker Compose 部署。这种情况两个环境变量似乎都没生效, 无论是否 指定 ENABLED_TENCENT_CLOUD: 1.

并且我还发现了另一个问题, 如果把 TENCENT_CLOUD_API_KEY 环境变量放在 ENABLED_OLLAMA 这个变量前面, 那么包括 ENABLED_OLLAMA 在内的后续所有环境变量都会失效.

我使用的 lobe-chat 版本是 v1.53.12.

这是部署的配置

version: '3.9'

services:
  lobe-chat:
    image: lobehub/lobe-chat
    user: root
    container_name: lobe-chat
    restart: always
    ports:
      - '3210:3210'
    environment:
      SSRF_ALLOW_PRIVATE_IP_ADDRESS: 1
      ACCESS_CODE: xxxx
      DEFAULT_AGENT_CONFIG: 'model=gpt-4o;params.max_tokens=30000;'
      FEATURE_FLAGS: -openai_api_key,-openai_proxy_url,-check_updates,-webrtc_sync,-language_model_settings,-clerk_sign_up,-cloud_promotion
      OPENAI_API_KEY: sk-proj-xx
      ENABLED_OLLAMA: 0
      ENABLED_AWS_BEDROCK: 1
      AWS_ACCESS_KEY_ID: xx
      AWS_SECRET_ACCESS_KEY: xx
      AWS_REGION: us-west-2
      QWEN_API_KEY: sk-xx
      TENCENT_CLOUD_API_KEY: sk-xx

@lobehubbot
Copy link
Member

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


Environment variables are not really used, just declared here, can this be fixed? @hedeqiang

Used it, I have used environment variables again, what is your construction method

Hello, I'm using [Docker Compose Deployment](https://lobehub.com/zh/docs/self-hosting/platform/docker-compose#%E8%BF%90%E8%A1%8C-docker-compose- %E9%83%A8%E7%BD%B2%E6%8C%87%E4%BB%A4). In this case, neither environment variable seems to be effective, whether or not ENABLED_TENCENT_CLOUD: 1 is specified.

And I also found another problem. If the TENCENT_CLOUD_API_KEY environment variable is placed before the ENABLED_OLLAMA variable, then all subsequent environment variables including ENABLED_OLLAMA will be invalid.

The version of lobe-chat I'm using is v1.53.12.

This is the deployment configuration

version: '3.9'

services:
  lobe-chat:
    image: lobehub/lobe-chat
    user: root
    container_name: lobe-chat
    restart: always
    Ports:
      - '3210:3210'
    environment:
      SSRF_ALLOW_PRIVATE_IP_ADDRESS: 1
      ACCESS_CODE: xxxx
      DEFAULT_AGENT_CONFIG: 'model=gpt-4o;params.max_tokens=30000;'
      FEATURE_FLAGS: -openai_api_key,-openai_proxy_url,-check_updates,-webrtc_sync,-language_model_settings,-clerk_sign_up,-cloud_promotion
      OPENAI_API_KEY: sk-proj-xx
      ENABLED_OLLAMA: 0
      ENABLED_AWS_BEDROCK: 1
      AWS_ACCESS_KEY_ID: xx
      AWS_SECRET_ACCESS_KEY: xx
      AWS_REGION: us-west-2
      QWEN_API_KEY: sk-xx
      TENCENT_CLOUD_API_KEY: sk-xx
      ```  
      

@hedeqiang
Copy link
Contributor Author

环境变量并没有真正使用, 只是声明在这里, 这个是否可以修复一下. @hedeqiang

使用了的吧,我目前已经再用环境变量了,你是什么构建方式

你好, 我使用 Docker Compose 部署。这种情况两个环境变量似乎都没生效, 无论是否 指定 ENABLED_TENCENT_CLOUD: 1.

并且我还发现了另一个问题, 如果把 TENCENT_CLOUD_API_KEY 环境变量放在 ENABLED_OLLAMA 这个变量前面, 那么包括 ENABLED_OLLAMA 在内的后续所有环境变量都会失效.

我使用的 lobe-chat 版本是 v1.53.12.

这是部署的配置

version: '3.9'



services:

  lobe-chat:

    image: lobehub/lobe-chat

    user: root

    container_name: lobe-chat

    restart: always

    ports:

      - '3210:3210'

    environment:

      SSRF_ALLOW_PRIVATE_IP_ADDRESS: 1

      ACCESS_CODE: xxxx

      DEFAULT_AGENT_CONFIG: 'model=gpt-4o;params.max_tokens=30000;'

      FEATURE_FLAGS: -openai_api_key,-openai_proxy_url,-check_updates,-webrtc_sync,-language_model_settings,-clerk_sign_up,-cloud_promotion

      OPENAI_API_KEY: sk-proj-xx

      ENABLED_OLLAMA: 0

      ENABLED_AWS_BEDROCK: 1

      AWS_ACCESS_KEY_ID: xx

      AWS_SECRET_ACCESS_KEY: xx

      AWS_REGION: us-west-2

      QWEN_API_KEY: sk-xx

      TENCENT_CLOUD_API_KEY: sk-xx


新起一个 issue 吧

@lobehubbot
Copy link
Member

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


Environment variables are not really used, just declared here, can this be fixed? @hedeqiang

Used it, I have used environment variables now, what is your construction method

Hello, I use [Docker Compose Deployment](https://lobehub.com/zh/docs/self-hosting/platform/docker-compose#%E8%BF%90%E8%A1%8C-docker-compose -%E9%83%A8%E7%BD%B2%E6%8C%87%E4%BB%A4). In this case, neither environment variable seems to be effective, whether or not ENABLED_TENCENT_CLOUD: 1 is specified.

And I also found another problem. If the TENCENT_CLOUD_API_KEY environment variable is placed before the ENABLED_OLLAMA variable, then all subsequent environment variables including ENABLED_OLLAMA will be invalid.

The version of lobe-chat I'm using is v1.53.12.

This is the deployment configuration

version: '3.9'



services:

lobe-chat:

image: lobehub/lobe-chat

user: root

container_name: lobe-chat

restart: always

ports:

- '3210:3210'

environment:

SSRF_ALLOW_PRIVATE_IP_ADDRESS: 1

ACCESS_CODE: xxxx

DEFAULT_AGENT_CONFIG: 'model=gpt-4o;params.max_tokens=30000;'

FEATURE_FLAGS: -openai_api_key,-openai_proxy_url,-check_updates,-webrtc_sync,-language_model_settings,-clerk_sign_up,-cloud_promotion

OPENAI_API_KEY: sk-proj-xx

ENABLED_OLLAMA: 0

ENABLED_AWS_BEDROCK: 1

AWS_ACCESS_KEY_ID: xx

AWS_SECRET_ACCESS_KEY: xx

AWS_REGION: us-west-2

QWEN_API_KEY: sk-xx

TENCENT_CLOUD_API_KEY: sk-xx


A new issue

ramu-narasinga pushed a commit to ramu-narasinga/lobe-chat that referenced this pull request Feb 17, 2025
* fix: tencentcloud

* fix: tencentcloud
ramu-narasinga pushed a commit to ramu-narasinga/lobe-chat that referenced this pull request Feb 17, 2025
### [Version&nbsp;1.53.3](lobehub/lobe-chat@v1.53.2...v1.53.3)
<sup>Released on **2025-02-12**</sup>

#### 🐛 Bug Fixes

- **misc**: Fix tencent cloud api issue.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### What's fixed

* **misc**: Fix tencent cloud api issue, closes [lobehub#6058](lobehub#6058) ([025d0bc](lobehub@025d0bc))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Something isn't working | 缺陷 released size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] 使用腾讯云模型调用出错
4 participants