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: #24292 HTTP Request Node Unable to Access File from Start Node When Using Remote URL in Workflow API Call (#24293)

Qiang Leeb84bb4164f7d
diff --git a/api/core/workflow/nodes/http_request/executor.py b/api/core/workflow/nodes/http_request/executor.py
index c9f7fa1221a..a5a578a6fff 100644
--- a/api/core/workflow/nodes/http_request/executor.py
+++ b/api/core/workflow/nodes/http_request/executor.py
@@ -12,6 +12,7 @@ from json_repair import repair_json
from configs import dify_config
from core.file import file_manager
+from core.file.enums import FileTransferMethod
from core.helper import ssrf_proxy
from core.variables.segments import ArrayFileSegment, FileSegment
from core.workflow.entities.variable_pool import VariablePool
@@ -228,7 +229,9 @@ class Executor:
files: dict[str, list[tuple[str | None, bytes, str]]] = {}
for key, files_in_segment in files_list:
for file in files_in_segment:
- if file.related_id is not None:
+ if file.related_id is not None or (
+ file.transfer_method == FileTransferMethod.REMOTE_URL and file.remote_url is not None
+ ):
file_tuple = (
file.filename,
file_manager.download(file),