-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
An empty Content-Encoding header is set in object's metadata after uploading the object to s3 with extra argument ChecksumAlgorithm #3629
Comments
Hi @ronanliu thanks for reporting this issue. I could reproduce the behavior you described. Just to clarify the differences between #3568, the specific issue reported there now appears to be resolved, as the |
Upon further discussion with a colleague, we concluded that this is likely an issue with the S3 console. The payloads generated by the code snippets referenced above include I created a new issue in our cross-SDK repository (aws/aws-sdk#498) and will reach out to S3 for further review. For updates please refer to that issue going forward. Thanks! |
Hi @tim-finnigan , thanks for looking into it!. I'll keep an eye on the new issue. |
Re-opening this issue to track updates here. Closing the old tracking issue P83760338 / D119267049 |
Since aws/aws-sdk#498 (comment) has been closed in favor of this to track, just bringing back up that this happens from Boto3 as well so is not limited to console uploads as theorized above. There are reports of the same behavior with sdks for other languages as well, implying this is more fundamental. |
Since I haven't seen anyone mention this -- it does appear to be documented behavior. "If you specify Content-Encoding in your request as Content-Encoding : aws-chunked, S3 adds an empty value for Content-Encoding and stores the object metadata (Content-Encoding : ) to the resulting object." The issue is that an empty Content-Encoding header is invalid and causes undefined behavior, i.e. when it conflicts with cloudfront's compression headers. Just throwing this out there in case it helps locate the root cause. |
This issue has now been resolved by S3. Going forward, uploading objects via chunked encoding will no longer result in storing or retrieving
|
This issue is now closed. Comments on closed issues are hard for our team to see. |
Describe the bug
There's an issue which is similar to #3568. When calling the method upload_file with

ChecksumAlgorithm
argument, an emptyContent-Encoding
record will be set in uploaded object's metadata.Expected Behavior
I would expect no
Content-Encoding
record is set as object's metadata if I don't pass it as argument when uploading a object.Current Behavior
Without specifying an extra argument for Content Encoding, the object's metadata still have an empty record for this header.
Reproduction Steps
Possible Solution
No response
Additional Information/Context
No response
SDK version used
1.26.90
Environment details (OS name and version, etc.)
Linux
The text was updated successfully, but these errors were encountered: