-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
GetBucketPolicy broken by PR #3276 #3286
Comments
Thanks for reporting, the team in looking into this issue and will post updates here. |
Linking PR including fix: #3288, which should be released soon. |
@tim-finnigan just confirming, is this fix to be released in |
@mukitmomin the fix for |
@mukitmomin - release 1.35.47 is now out, please update your version of boto3/botocore in order to have access to this fix. |
This issue is now closed. Comments on closed issues are hard for our team to see. |
Describe the bug
Trying to get a bucket policy consistently fails with fake error 500 Internal Server Error.
The issue comes from PR #3276 forcibly trying to parse the body as an XML document and failing as it's a JSON document and then considering it
_looks_like_special_case_error
due to this line:botocore/botocore/handlers.py
Line 180 in bab77d8
Regression Issue
Expected Behavior
The bucket policy document is returned successfully.
Current Behavior
An error is ClientError is raised.
Reproduction Steps
With adequate permissions, and a bucket with some policy configured, run:
Possible Solution
Don't feed a response body whose header says
Content-Type: application/json
to an XML parser.Additional Information/Context
No response
SDK version used
1.35.45
Environment details (OS name and version, etc.)
Ubuntu 22.04.5 LTS
The text was updated successfully, but these errors were encountered: