Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: 'dict_keys' object is not subscriptable error (#11957)

yihong26c10b9931bc
diff --git a/api/core/tools/provider/app_tool_provider.py b/api/core/tools/provider/app_tool_provider.py
index 09f328cd1fe..582ad636b19 100644
--- a/api/core/tools/provider/app_tool_provider.py
+++ b/api/core/tools/provider/app_tool_provider.py
@@ -62,7 +62,7 @@ class AppToolProviderEntity(ToolProviderController):
user_input_form_list = app_model_config.user_input_form_list
for input_form in user_input_form_list:
# get type
- form_type = input_form.keys()[0]
+ form_type = list(input_form.keys())[0]
default = input_form[form_type]["default"]
required = input_form[form_type]["required"]
label = input_form[form_type]["label"]