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: when upload file response 3** will raise error (#9555)

非法操作a5777683f354
diff --git a/api/factories/file_factory.py b/api/factories/file_factory.py
index 91b188270af..eac5090c2bc 100644
--- a/api/factories/file_factory.py
+++ b/api/factories/file_factory.py
@@ -177,7 +177,7 @@ def _build_from_remote_url(
url = mapping.get("url")
if not url:
raise ValueError("Invalid file url")
- resp = ssrf_proxy.head(url)
+ resp = ssrf_proxy.head(url, follow_redirects=True)
resp.raise_for_status()
# Try to extract filename from response headers or URL