From 3840119bc75e74b721dd15828db128d1a8186309 Mon Sep 17 00:00:00 2001 From: Adrian Likins Date: Fri, 5 May 2017 11:07:50 -0400 Subject: [PATCH] Fix vaulted vars templating (#24312) Use the default repr of AnsibleVaultEncryptedUnicode.data instead of a custom one, since jinja templating ends up using the repr() results. Fixes #23846, #24175 --- lib/ansible/parsing/yaml/objects.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/parsing/yaml/objects.py b/lib/ansible/parsing/yaml/objects.py index 7c2726c445..41df711a81 100644 --- a/lib/ansible/parsing/yaml/objects.py +++ b/lib/ansible/parsing/yaml/objects.py @@ -111,7 +111,7 @@ class AnsibleVaultEncryptedUnicode(yaml.YAMLObject, AnsibleUnicode): self._ciphertext = value def __repr__(self): - return 'AnsibleVaultEncryptedUnicode(%s)' % self._ciphertext + return repr(self.data) # Compare a regular str/text_type with the decrypted hypertext def __eq__(self, other):