[cloud] cast tag values to strings in ansible_dict_to_boto3_tag_list utility (#27396)

* ansible_dict_to_boto3_tag_list cast tag values to string

* ansible_dict_to_boto3_tag_list cast with to_native
This commit is contained in:
mzizzi 2017-07-27 16:15:05 -04:00 committed by Ryan Brown
parent 81151ef02c
commit 9817ec84a0

View file

@ -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