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.
Python agentagentic-aiagentic-frameworkagentic-workflowaiautomationclaudedeepseekgenaigptllmlow-codemcpnextjsno-codeopenaipythonskillsworkflow
fix(tool): tool node error (#7459)
luckylhb909a715f6b687d
diff --git a/api/core/workflow/nodes/tool/tool_node.py b/api/core/workflow/nodes/tool/tool_node.pyindex 9b52cd2f6be..ccce9ef3607 100644--- a/api/core/workflow/nodes/tool/tool_node.py+++ b/api/core/workflow/nodes/tool/tool_node.py@@ -2,7 +2,7 @@ from collections.abc import Mapping, Sequencefrom os import pathfrom typing import Any, cast-from core.app.segments import ArrayAnyVariable, parser+from core.app.segments import ArrayAnySegment, ArrayAnyVariable, parserfrom core.callback_handler.workflow_tool_callback_handler import DifyWorkflowCallbackHandlerfrom core.file.file_obj import FileTransferMethod, FileType, FileVarfrom core.tools.entities.tool_entities import ToolInvokeMessage, ToolParameter@@ -142,7 +142,7 @@ class ToolNode(BaseNode):def _fetch_files(self, variable_pool: VariablePool) -> list[FileVar]:variable = variable_pool.get(['sys', SystemVariableKey.FILES.value])- assert isinstance(variable, ArrayAnyVariable)+ assert isinstance(variable, ArrayAnyVariable | ArrayAnySegment)return list(variable.value) if variable else []def _convert_tool_messages(self, messages: list[ToolInvokeMessage]):