mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Collect all error data from the wfuncs call
This commit is contained in:
parent
11864c31b7
commit
8a5b47b5d7
1 changed files with 6 additions and 6 deletions
|
@ -792,6 +792,12 @@ class Single(object):
|
|||
minion_opts=self.minion_opts,
|
||||
**self.target)
|
||||
opts_pkg = pre_wrapper['test.opts_pkg']() # pylint: disable=E1102
|
||||
if '_error' in opts_pkg:
|
||||
#Refresh failed
|
||||
retcode = opts_pkg['retcode']
|
||||
ret = json.dumps({'local': opts_pkg})
|
||||
return ret, retcode
|
||||
|
||||
opts_pkg['file_roots'] = self.opts['file_roots']
|
||||
opts_pkg['pillar_roots'] = self.opts['pillar_roots']
|
||||
opts_pkg['ext_pillar'] = self.opts['ext_pillar']
|
||||
|
@ -807,12 +813,6 @@ class Single(object):
|
|||
|
||||
retcode = 0
|
||||
|
||||
if '_error' in opts_pkg:
|
||||
#Refresh failed
|
||||
retcode = opts_pkg['retcode']
|
||||
ret = json.dumps({'local': opts_pkg['_error']})
|
||||
return ret, retcode
|
||||
|
||||
pillar = salt.pillar.Pillar(
|
||||
opts_pkg,
|
||||
opts_pkg['grains'],
|
||||
|
|
Loading…
Add table
Reference in a new issue