Skip to content

Commit

Permalink
Enable AWSRetry on aws_region_info (ansible-collections#422)
Browse files Browse the repository at this point in the history
* Enable AWSRetry on aws_region_info

* changelog
  • Loading branch information
tremble authored Feb 18, 2021
1 parent 9aab5be commit 4982d14
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion aws_region_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@
'''

from ansible_collections.amazon.aws.plugins.module_utils.core import AnsibleAWSModule
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import AWSRetry, ansible_dict_to_boto3_filter_list, camel_dict_to_snake_dict
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import AWSRetry
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import ansible_dict_to_boto3_filter_list
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import camel_dict_to_snake_dict

try:
from botocore.exceptions import ClientError, BotoCoreError
Expand Down Expand Up @@ -86,6 +88,7 @@ def main():

try:
regions = connection.describe_regions(
aws_retry=True,
Filters=ansible_dict_to_boto3_filter_list(sanitized_filters)
)
except (BotoCoreError, ClientError) as e:
Expand Down

0 comments on commit 4982d14

Please sign in to comment.