[PR #2507] [MERGED] fix(tongyi): fix credentials access and temp file upload compatibility #2531

Closed
opened 2026-02-16 11:17:15 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/langgenius/dify-official-plugins/pull/2507
Author: @Dnoob
Created: 1/28/2026
Status: Merged
Merged: 2/1/2026
Merged by: @crazywoola

Base: mainHead: fix/tongyi-credentials-and-file-upload


📝 Commits (4)

  • 6202373 fix(tongyi): fix credentials access and temp file upload compatibility
  • c55ee26 Merge origin/main and bump version to 0.1.24
  • 503f2a6 Merge remote-tracking branch 'upstream/main' into fix/tongyi-credentials-and-file-upload
  • 6d9a7b3 chore: bump version to 0.1.25

📊 Changes

2 files changed (+7 additions, -6 deletions)

View changed files

📝 models/tongyi/manifest.yaml (+1 -1)
📝 models/tongyi/models/llm/llm.py (+6 -5)

📄 Description

Summary

Fix two bugs in _upload_file_to_tongyi method:

  1. credentials.dashscope_api_key causes 'dict' object has no attribute 'dashscope_api_key' error when
    using Agent node with memory enabled
  2. tempfile._TemporaryFileWrapper is not compatible with new OpenAI SDK file upload

Related Issues or Context

This PR contains Changes to Non-Plugin

  • Documentation
  • Other

This PR contains Changes to Non-LLM Models Plugin

  • I have Run Comprehensive Tests Relevant to My Changes

This PR contains Changes to LLM Models Plugin

  • My Changes Affect Message Flow Handling (System Messages and User���Assistant Turn-Taking)

  • My Changes Affect Tool Interaction Flow (Multi-Round Usage and Output Handling, for both Agent App and
    Agent Node)

  • My Changes Affect Multimodal Input Handling (Images, PDFs, Audio, Video, etc.)

  • My Changes Affect Multimodal Output Generation (Images, Audio, Video, etc.)

  • My Changes Affect Structured Output Format (JSON, XML, etc.)

  • My Changes Affect Token Consumption Metrics

  • My Changes Affect Other LLM Functionalities (Reasoning Process, Grounding, Prompt Caching, etc.)

  • Other Changes (Add New Models, Fix Model Parameters etc.)

Version Control (Any Changes to the Plugin Will Require Bumping the Version)

  • I have Bumped Up the Version in Manifest.yaml (Top-Level Version Field, Not in Meta Section)

Dify Plugin SDK Version

  • I have Ensured dify_plugin>=0.3.0,<0.6.0 is in requirements.txt

Environment Verification (If Any Code Changes)

Local Deployment Environment

  • Dify Version is: 1.8.1, I have Tested My Changes on Local Deployment Dify with a Clean Environment That
    Matches the Production Configuration.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/langgenius/dify-official-plugins/pull/2507 **Author:** [@Dnoob](https://github.com/Dnoob) **Created:** 1/28/2026 **Status:** ✅ Merged **Merged:** 2/1/2026 **Merged by:** [@crazywoola](https://github.com/crazywoola) **Base:** `main` ← **Head:** `fix/tongyi-credentials-and-file-upload` --- ### 📝 Commits (4) - [`6202373`](https://github.com/langgenius/dify-official-plugins/commit/62023732494cefc83b204b6bd548bb04a6fd43ee) fix(tongyi): fix credentials access and temp file upload compatibility - [`c55ee26`](https://github.com/langgenius/dify-official-plugins/commit/c55ee26e63d759c3880450fd8c6609bee34c284f) Merge origin/main and bump version to 0.1.24 - [`503f2a6`](https://github.com/langgenius/dify-official-plugins/commit/503f2a680f0c2faaa19a39fea2ea9f435a865a91) Merge remote-tracking branch 'upstream/main' into fix/tongyi-credentials-and-file-upload - [`6d9a7b3`](https://github.com/langgenius/dify-official-plugins/commit/6d9a7b32de63b750b747860fce1ff9a901a08263) chore: bump version to 0.1.25 ### 📊 Changes **2 files changed** (+7 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `models/tongyi/manifest.yaml` (+1 -1) 📝 `models/tongyi/models/llm/llm.py` (+6 -5) </details> ### 📄 Description ## Summary Fix two bugs in `_upload_file_to_tongyi` method: 1. `credentials.dashscope_api_key` causes `'dict' object has no attribute 'dashscope_api_key'` error when using Agent node with memory enabled 2. `tempfile._TemporaryFileWrapper` is not compatible with new OpenAI SDK file upload ## Related Issues or Context - https://github.com/langgenius/dify-official-plugins/issues/1290 - https://github.com/langgenius/dify-official-plugins/issues/1110 ## This PR contains Changes to *Non-Plugin* - [ ] Documentation - [ ] Other ## This PR contains Changes to *Non-LLM Models Plugin* - [ ] I have Run Comprehensive Tests Relevant to My Changes ## This PR contains Changes to *LLM Models Plugin* - [ ] My Changes Affect Message Flow Handling (System Messages and User���Assistant Turn-Taking) - [ ] My Changes Affect Tool Interaction Flow (Multi-Round Usage and Output Handling, for both Agent App and Agent Node) - [x] My Changes Affect Multimodal Input Handling (Images, PDFs, Audio, Video, etc.) - [ ] My Changes Affect Multimodal Output Generation (Images, Audio, Video, etc.) - [ ] My Changes Affect Structured Output Format (JSON, XML, etc.) - [ ] My Changes Affect Token Consumption Metrics - [ ] My Changes Affect Other LLM Functionalities (Reasoning Process, Grounding, Prompt Caching, etc.) - [x] Other Changes (Add New Models, Fix Model Parameters etc.) ## Version Control (Any Changes to the Plugin Will Require Bumping the Version) - [x] I have Bumped Up the Version in Manifest.yaml (Top-Level `Version` Field, Not in Meta Section) ## Dify Plugin SDK Version - [x] I have Ensured `dify_plugin>=0.3.0,<0.6.0` is in requirements.txt ## Environment Verification (If Any Code Changes) ### Local Deployment Environment - [x] Dify Version is: 1.8.1, I have Tested My Changes on Local Deployment Dify with a Clean Environment That Matches the Production Configuration. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 11:17:15 -05:00
yindo closed this issue 2026-02-16 11:17:15 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-official-plugins#2531