diff --git a/lib/ansible/module_utils/ec2.py b/lib/ansible/module_utils/ec2.py index 74b61ee007a..4186128579f 100644 --- a/lib/ansible/module_utils/ec2.py +++ b/lib/ansible/module_utils/ec2.py @@ -30,6 +30,7 @@ import os import re from time import sleep +from ansible.module_utils._text import to_native from ansible.module_utils.cloud import CloudRetry try: @@ -495,7 +496,7 @@ def ansible_dict_to_boto3_tag_list(tags_dict, tag_name_key_name='Key', tag_value tags_list = [] for k, v in tags_dict.items(): - tags_list.append({tag_name_key_name: k, tag_value_key_name: v}) + tags_list.append({tag_name_key_name: k, tag_value_key_name: to_native(v)}) return tags_list