From 985fa501582fd231e19ea537082e478134524c85 Mon Sep 17 00:00:00 2001 From: Akim Juillerat Date: Tue, 11 Feb 2020 17:34:42 +0100 Subject: [PATCH] Support minio.io for DEV without error --- attachment_s3/models/ir_attachment.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/attachment_s3/models/ir_attachment.py b/attachment_s3/models/ir_attachment.py index f8135ba..98d960c 100644 --- a/attachment_s3/models/ir_attachment.py +++ b/attachment_s3/models/ir_attachment.py @@ -133,10 +133,15 @@ class IrAttachment(models.Model): _logger.exception( "Object %s does not exists on S3 bucket" % fname ) + elif error_code == 'NotImplemented': + _logger.exception( + "S3 storage does not implement ACL" % fname + ) else: _logger.exception( "Cannot set ACL %s on object %s" % (acl, fname) ) + return False else: _logger.warning("Cannot set ACL on object not stored on S3") return False