Skip to content
Snippets Groups Projects
Commit 3a2b326e89cc authored by Efflam Lemaillet's avatar Efflam Lemaillet :robot:
Browse files

use upload_fileobj insted of put_object #12

parent 2dd30b8ecf85
No related branches found
No related tags found
No related merge requests found
Pipeline #151984 failed
...@@ -102,8 +102,11 @@ ...@@ -102,8 +102,11 @@
else: else:
upload_key = key upload_key = key
extra_args = self.get_upload_extra_args(entity, attr, key) extra_args = self.get_upload_extra_args(entity, attr, key)
self.s3cnx.upload_fileobj(buffer, self.bucket, upload_key,
ExtraArgs=extra_args) s3_object = self.bucket.put_object(
Body=buffer,
Key=upload_key,
**extra_args)
buffer.close() buffer.close()
# when key is suffixed, move to final key in post commit event # when key is suffixed, move to final key in post commit event
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment