Exception classes should all extend a common botocore exception
See original GitHub issueRight now, if I want to handle all classes of botocore exceptions, I can’t easily do so. For example, ClientError extends Exception directly. If they all extended from BotoCoreError or something, then I could easily handle any botocore exception.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:2
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Error handling — Boto3 Docs 1.26.35 documentation - AWS
Any Boto3 clients you create will use these same statically defined exception classes. The most common botocore exception you'll encounter is ClientError ....
Read more >How to handle errors with boto3? - Stack Overflow
Looking for exception types in module: boto3 boto3.BotoCoreError is an exception type boto3.DataNotFoundError is an exception type boto3.
Read more >Handling Errors in Boto3 & Botocore - Trek10
You can import botocore.exceptions and handle this error by the class ( ClientError in this case) but that information isn't enough. We have...
Read more >Troubleshoot common errors with API calls in Amazon ECS
The Amazon ECS APIs might fail with one of the following errors: AccessDeniedException; ClientException; ClusterNotFoundException ...
Read more >How to use the botocore.exceptions function in ... - Snyk
exceptions.BotoCoreError, botocore.exceptions.ClientError) as e: module.fail_json_aws(e, msg="Failed to create cluster") ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

hopefully changes for this could incorporate issue raised by https://github.com/boto/botocore/issues/834
The exceptions in botocore/models.py also extend
Exceptiondirectly.