From 9b8a55032dd19a0a185f8c687d3f095b774083ff Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Sun, 14 Dec 2014 19:27:17 +0100 Subject: [PATCH] Do not use the variable name as a key for the result of the module Using the variable name can interfere with various systems used to communicate between modules and ansible ( as reported in #7732 , where ansible_facts is a reserved key for updating the fact cache, for example ). --- lib/ansible/runner/action_plugins/debug.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/runner/action_plugins/debug.py b/lib/ansible/runner/action_plugins/debug.py index 75613b9919..eaf1364c3f 100644 --- a/lib/ansible/runner/action_plugins/debug.py +++ b/lib/ansible/runner/action_plugins/debug.py @@ -52,7 +52,7 @@ class ActionModule(object): result = dict(msg=args['msg']) elif 'var' in args and not utils.LOOKUP_REGEX.search(args['var']): results = template.template(self.basedir, args['var'], inject, convert_bare=True) - result[args['var']] = results + result['var'] = { args['var']: results } # force flag to make debug output module always verbose result['verbose_always'] = True