Skip to content
This repository has been archived by the owner on Aug 31, 2021. It is now read-only.

Better BadRequestException for Non Support Resources #26

Open
jfuss opened this issue Jun 15, 2019 · 1 comment
Open

Better BadRequestException for Non Support Resources #26

jfuss opened this issue Jun 15, 2019 · 1 comment

Comments

@jfuss
Copy link
Contributor

jfuss commented Jun 15, 2019

SAM CLI was cut this issue, which outputs a stack trace when Unsupported Resources are within the template that is being published.

I think it makes sense to include some additional error handling within this library that provides a better error that the boto3 error that gets returned. This is similar to wrapping of the Botocore ClientError that this library already wraps.

Proposal

Add a UnsupportedResourcesError in exceptions.py. We can then catch botocore.errorfactory.BadRequestException in this try: except: block and wrap it in the UnsupportedResourcesError with a message of "The template contains unsupported resource types. [XX::XX::XX]", which can be parsed out of the exception.

@gruebel
Copy link
Contributor

gruebel commented Aug 21, 2019

Is there actually a reason, why not all resources are supported?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants