Skip to content
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

Error creating S3 bucket in region us-east-1 #811

Closed
boompig opened this issue Sep 15, 2016 · 1 comment
Closed

Error creating S3 bucket in region us-east-1 #811

boompig opened this issue Sep 15, 2016 · 1 comment
Labels
duplicate This issue is a duplicate. feature-request This issue requests a feature.

Comments

@boompig
Copy link

boompig commented Sep 15, 2016

This code fails

response = client.create_bucket(ACL="private", Bucket=s3_bucket_name, CreateBucketConfiguration={ "LocationConstraint": "us-east-1"})

With this error:

botocore.exceptions.ClientError: An error occurred (InvalidLocationConstraint) when calling the CreateBucket operation: The specified location-constraint is not valid

This probably has to do with this "bug/quirk":

The location constraint for S3 US East region is an empty string according to the following documentation. You should always leave it blank when referring to S3 US Standard region.

http://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketGETlocation.html

But IMO the library should handle this quirk and allow "us-east-1" as the location string.

EDIT: Actually empty string also doesn't work, you have to omit the LocationConstraint parameter entirely.

@kyleknap kyleknap added duplicate This issue is a duplicate. feature-request This issue requests a feature. labels Sep 19, 2016
@kyleknap
Copy link
Contributor

Yeah this is the same as this request: #125. I think it would be nice if we did something to handle this or autopopulate location constraint for the user. I am going to close this as a duplicate, but let's keep the conversation going in the linked issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue is a duplicate. feature-request This issue requests a feature.
Projects
None yet
Development

No branches or pull requests

2 participants