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(storage): 🐛 HeadBucket Operation Permission (#7733)

Vimpas4682e0ac7c41
diff --git a/api/extensions/storage/s3_storage.py b/api/extensions/storage/s3_storage.py
index 424d441cdcb..0858be3af6a 100644
--- a/api/extensions/storage/s3_storage.py
+++ b/api/extensions/storage/s3_storage.py
@@ -35,6 +35,9 @@ class S3Storage(BaseStorage):
# if bucket not exists, create it
if e.response["Error"]["Code"] == "404":
self.client.create_bucket(Bucket=self.bucket_name)
+ # if bucket is not accessible, pass, maybe the bucket is existing but not accessible
+ elif e.response["Error"]["Code"] == "403":
+ pass
else:
# other error, raise exception
raise