mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 22:02:50 +00:00
Fixing up some output stuff
This commit is contained in:
@@ -235,4 +235,4 @@ DEFAULT_SUBSET = None
|
||||
DEFAULT_SU_PASS = None
|
||||
VAULT_VERSION_MIN = 1.0
|
||||
VAULT_VERSION_MAX = 1.0
|
||||
RESULT_SANITIZE = frozenset(['invocation','warnings'])
|
||||
RESULT_SANITIZE = frozenset(['warnings'])
|
||||
|
||||
@@ -23,7 +23,7 @@ from six.moves import StringIO
|
||||
import json
|
||||
import os
|
||||
import random
|
||||
import sys # FIXME: probably not needed
|
||||
import sys
|
||||
import tempfile
|
||||
import time
|
||||
|
||||
@@ -404,10 +404,11 @@ class ActionBase:
|
||||
data['stdout_lines'] = data.get('stdout', '').splitlines()
|
||||
|
||||
# store the module invocation details back into the result
|
||||
data['invocation'] = dict(
|
||||
module_args = module_args,
|
||||
module_name = module_name,
|
||||
)
|
||||
if self._task.async is not None:
|
||||
data['invocation'] = dict(
|
||||
module_args = module_args,
|
||||
module_name = module_name,
|
||||
)
|
||||
|
||||
debug("done with _execute_module (%s, %s)" % (module_name, module_args))
|
||||
return data
|
||||
|
||||
@@ -49,7 +49,7 @@ class CallbackBase:
|
||||
if sanitize:
|
||||
res = self._sanitize_result(result)
|
||||
else:
|
||||
res = results
|
||||
res = result
|
||||
return json.dumps(res, indent=indent, ensure_ascii=False, sort_keys=sort_keys)
|
||||
|
||||
def _sanitize_result(self, result):
|
||||
|
||||
Reference in New Issue
Block a user