Add module_stdout/stderr fields to list in 'debug' callback plugin

This commit is contained in:
Andrew Gaffney 2017-12-05 23:34:41 -07:00 committed by Toshio Kuratomi
parent 395566746e
commit 6a84772290

View file

@ -38,13 +38,13 @@ class CallbackModule(CallbackModule_default): # pylint: disable=too-few-public-
result['_ansible_verbose_always'] = True
save = {}
for key in ['stdout', 'stdout_lines', 'stderr', 'stderr_lines', 'msg']:
for key in ['stdout', 'stdout_lines', 'stderr', 'stderr_lines', 'msg', 'module_stdout', 'module_stderr']:
if key in result:
save[key] = result.pop(key)
output = CallbackModule_default._dump_results(self, result)
for key in ['stdout', 'stderr', 'msg']:
for key in ['stdout', 'stderr', 'msg', 'module_stdout', 'module_stderr']:
if key in save and save[key]:
output += '\n\n%s:\n\n%s\n' % (key.upper(), save[key])