Skip to content

Commit

Permalink
narrow exception type
Browse files Browse the repository at this point in the history
  • Loading branch information
Sofia Sazonova committed Oct 2, 2024
1 parent 7396718 commit 5f6122e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests_new/integration_tests/aws_clients/iam.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def get_role(self, role_name):
try:
role = self._client.get_role(RoleName=role_name)
return role
except Exception as e:
except self._client.exceptions.NoSuchEntityException as e:
log.info(f'Error occurred: {e}')
return None

Expand Down

0 comments on commit 5f6122e

Please sign in to comment.