Add stderr contents to parse errors

parent 19f3cf45
...@@ -236,7 +236,10 @@ class Runner(object): ...@@ -236,7 +236,10 @@ class Runner(object):
if tmp.find("tmp") != -1 and C.DEFAULT_KEEP_REMOTE_FILES != '1': if tmp.find("tmp") != -1 and C.DEFAULT_KEEP_REMOTE_FILES != '1':
cmd = cmd + "; rm -rf %s >/dev/null 2>&1" % tmp cmd = cmd + "; rm -rf %s >/dev/null 2>&1" % tmp
res = self._low_level_exec_command(conn, cmd, tmp, sudoable=True) res = self._low_level_exec_command(conn, cmd, tmp, sudoable=True)
return ReturnData(conn=conn, result=res['stdout']) data = utils.parse_json(res['stdout'])
if 'parsed' in data and data['parsed'] == False:
data['msg'] += res['stderr']
return ReturnData(conn=conn, result=data)
# ***************************************************** # *****************************************************
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment