-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
S3: add error for DeleteObject preconditions for regular buckets #12787
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
Conversation
Test Results - Alternative Providers988 tests 621 ✅ 34m 12s ⏱️ Results for commit 94293b0. |
Test Results (amd64) - Integration, Bootstrap 5 files 5 suites 1h 25m 11s ⏱️ Results for commit 94293b0. |
LocalStack Community integration with Pro 2 files ± 0 2 suites ±0 1h 3m 53s ⏱️ - 39m 0s Results for commit 94293b0. ± Comparison against base commit b36bb1a. This pull request removes 2666 and adds 4 tests. Note that renamed tests count towards both. |
k-a-il
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🚀
| LOG.warning( | ||
| "DeleteObject Preconditions is only supported for Directory Buckets. " | ||
| "LocalStack does not support Directory Buckets yet." | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, this will improve user experience
Motivation
We got a report with #12783 that we did not support
IfMatchheader forDeleteObject. This is because this is only supported for Directory Bucket (S3 Express One Zone), which we don't support yet (requested at #12184).In the reported issue, the bucket was not created as a Directory Bucket, which would raise an exception in S3 when trying to use preconditions headers for
DeleteObject.This PR adds that parity + a log message to indicate that directory buckets are not yet supported by LocalStack, to avoid users not understanding why such feature would just fail silently.
Changes
Side note regarding Directory Buckets
It seems AWS is adding more feature again only to Directory Buckets, as seen by #12785 and https://aws.amazon.com/about-aws/whats-new/2025/06/amazon-s3-express-one-zone-atomic-renaming-objects-api/