|
|
@ -15,7 +15,7 @@ from jinja2.runtime import StrictUndefined
|
|
|
|
from ansible.module_utils._text import to_text
|
|
|
|
from ansible.module_utils._text import to_text
|
|
|
|
from ansible.module_utils.common.collections import is_sequence, Mapping
|
|
|
|
from ansible.module_utils.common.collections import is_sequence, Mapping
|
|
|
|
from ansible.module_utils.common.text.converters import container_to_text
|
|
|
|
from ansible.module_utils.common.text.converters import container_to_text
|
|
|
|
from ansible.module_utils.six import PY2, text_type
|
|
|
|
from ansible.module_utils.six import PY2, text_type, string_types
|
|
|
|
from ansible.parsing.yaml.objects import AnsibleVaultEncryptedUnicode
|
|
|
|
from ansible.parsing.yaml.objects import AnsibleVaultEncryptedUnicode
|
|
|
|
from ansible.utils.native_jinja import NativeJinjaText
|
|
|
|
from ansible.utils.native_jinja import NativeJinjaText
|
|
|
|
|
|
|
|
|
|
|
@ -73,6 +73,10 @@ def ansible_native_concat(nodes):
|
|
|
|
# https://github.com/pallets/jinja/issues/1200
|
|
|
|
# https://github.com/pallets/jinja/issues/1200
|
|
|
|
# https://github.com/ansible/ansible/issues/70831#issuecomment-664190894
|
|
|
|
# https://github.com/ansible/ansible/issues/70831#issuecomment-664190894
|
|
|
|
return out
|
|
|
|
return out
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# short-circuit literal_eval for anything other than strings
|
|
|
|
|
|
|
|
if not isinstance(out, string_types):
|
|
|
|
|
|
|
|
return out
|
|
|
|
else:
|
|
|
|
else:
|
|
|
|
if isinstance(nodes, types.GeneratorType):
|
|
|
|
if isinstance(nodes, types.GeneratorType):
|
|
|
|
nodes = chain(head, nodes)
|
|
|
|
nodes = chain(head, nodes)
|
|
|
|