bigbug,help #748

Closed
opened 2026-02-16 10:20:22 -05:00 by yindo · 6 comments
Owner

Originally created by @LauWoods on GitHub (Oct 24, 2025).

Self Checks

  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • I have searched for existing issues Dify issues & Dify Official Plugins, including closed ones.
  • I confirm that I am using English to submit this report (我已阅读并同意 Language Policy).
  • [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.8.1

Plugin version

langgenius-tongyi_0.0.56.difypkg

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Run failed: [tongyi] Error: req_id: f9873d95ab PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"}

✔️ Error log

Run failed: [tongyi] Error: req_id: f9873d95ab PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"}

Originally created by @LauWoods on GitHub (Oct 24, 2025). ### Self Checks - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [Dify issues](https://github.com/langgenius/dify/issues) & [Dify Official Plugins](https://github.com/langgenius/dify-official-plugins/issues), including closed ones. - [x] I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)). - [x] [FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.8.1 ### Plugin version langgenius-tongyi_0.0.56.difypkg ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce Run failed: [tongyi] Error: req_id: f9873d95ab PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"} ### ✔️ Error log Run failed: [tongyi] Error: req_id: f9873d95ab PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"}
yindo added the bug label 2026-02-16 10:20:22 -05:00
yindo closed this issue 2026-02-16 10:20:22 -05:00
Author
Owner

@LauWoods commented on GitHub (Oct 24, 2025):

Error When Calling qwen-long via LLM Node (Other Qwen Models Work Fine)​​
When I call the qwen-longmodel through an LLM node, I encounter the following error. Other Qwen models do not produce this error.

Run failed: [tongyi] Error: req_id: bcb563d907 PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"}

@LauWoods commented on GitHub (Oct 24, 2025): Error When Calling qwen-long via LLM Node (Other Qwen Models Work Fine)​​ When I call the qwen-longmodel through an LLM node, I encounter the following error. Other Qwen models do not produce this error. Run failed: [tongyi] Error: req_id: bcb563d907 PluginInvokeError: {"args":{"description":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"},"error_type":"InvokeError","message":"[models] Error: 'dict' object has no attribute 'dashscope_api_key'"}
Author
Owner

@dosubot[bot] commented on GitHub (Oct 24, 2025):

This error happens because the plugin code tries to access the DashScope API key using dot notation (credentials.dashscope_api_key) when it should use dictionary key access (credentials['dashscope_api_key']). This bug is specific to the qwen-long model and has been reported by other users in self-hosted Docker environments. The robust fix is to patch the plugin code so all credential access uses dictionary keys, or to ensure credentials are always normalized before use. If you can't patch the code, workarounds include downgrading the Tongyi plugin to version 0.0.18 (which avoids the bug in some recent Dify releases), or switching the agent node strategy from EnhanceFunctionCalling to Dify's official agent strategy, but these do not always resolve the issue. Also, double-check that your API key is correctly configured and matches the expected format for DashScope. More details and user reports are available here and here.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Join Discord Share on X

@dosubot[bot] commented on GitHub (Oct 24, 2025): <!-- Answer --> This error happens because the plugin code tries to access the DashScope API key using dot notation (`credentials.dashscope_api_key`) when it should use dictionary key access (`credentials['dashscope_api_key']`). This bug is specific to the qwen-long model and has been reported by other users in self-hosted Docker environments. The robust fix is to patch the plugin code so all credential access uses dictionary keys, or to ensure credentials are always normalized before use. If you can't patch the code, workarounds include downgrading the Tongyi plugin to version 0.0.18 (which avoids the bug in some recent Dify releases), or switching the agent node strategy from EnhanceFunctionCalling to Dify's official agent strategy, but these do not always resolve the issue. Also, double-check that your API key is correctly configured and matches the expected format for DashScope. More details and user reports are available [here](https://github.com/langgenius/dify-official-plugins/issues/1762) and [here](https://github.com/langgenius/dify-official-plugins/issues/917). <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/89a7571f-e1b6-49a5-9554-73b71e843370?feedback_type=other)</sup>&nbsp;&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify-official-plugins/issues/1924)
Author
Owner

@hjlarry commented on GitHub (Oct 28, 2025):

can't reproduce this, I think you can try a different version of tongyi plugin

@hjlarry commented on GitHub (Oct 28, 2025): can't reproduce this, I think you can try a different version of tongyi plugin
Author
Owner

@U11Leung commented on GitHub (Dec 12, 2025):

I can confirm in latest tongyi plugin 0.1.8, dify self-host 1.8.1, this issue still exist.

The key to reproducing the issue is it only occurs when a file is sent in user context:
Image
The elapsed time is xx ms possibly indicating the message is returned from api.

Also, if the file is sent in system prompt, the error will change to UnsupportedDataType:
Image

@U11Leung commented on GitHub (Dec 12, 2025): I can confirm in latest tongyi plugin 0.1.8, dify self-host 1.8.1, this issue still exist. The key to reproducing the issue is it only occurs when a file is sent in user context: <img width="988" height="502" alt="Image" src="https://github.com/user-attachments/assets/c1e9b6e4-4854-4142-a622-057c3ee9ea0a" /> The elapsed time is xx ms possibly indicating the message is returned from api. Also, if the file is sent in system prompt, the error will change to UnsupportedDataType: <img width="996" height="462" alt="Image" src="https://github.com/user-attachments/assets/f99b656f-cfc2-4a66-85f7-51c06613a90b" />
Author
Owner

@U11Leung commented on GitHub (Dec 12, 2025):

I suggest the incompatibility be re-opened and re-investigate

@U11Leung commented on GitHub (Dec 12, 2025): I suggest the incompatibility be re-opened and re-investigate
Author
Owner

@U11Leung commented on GitHub (Dec 12, 2025):

By requesting tongyi api directly (upload file and then use fileid to provide file content), I confirm qwen-long actually supports docx, xlsx, pdf, images

@U11Leung commented on GitHub (Dec 12, 2025): By requesting tongyi api directly (upload file and then use fileid to provide file content), I confirm qwen-long actually supports docx, xlsx, pdf, images
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify-official-plugins#748