Skip to content

Commit

Permalink
Adding all exceptions
Browse files Browse the repository at this point in the history
  • Loading branch information
sweta committed Oct 7, 2020
1 parent cd7e618 commit 2781f99
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/source/guide/secrets-manager.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,10 @@ Example
print("The request was invalid due to:", e)
elif e.response['Error']['Code'] == 'InvalidParameterException':
print("The request had invalid params:", e)
elif e.response['Error']['Code'] == 'DecryptionFailure':
print("The requested secret can't be decrypted using the provided KMS key:", e)
elif e.response['Error']['Code'] == 'InternalServiceError':
print("An error occurred on service side:", e)
else:
# Secrets Manager decrypts the secret value using the associated KMS CMK
# Depending on whether the secret was a string or binary, only one of these fields will be populated
Expand Down

0 comments on commit 2781f99

Please sign in to comment.