mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 01:18:58 +00:00
Merge pull request #32005 from Ashald/bugfix/netapi-runner-client-kwargs-yamlify
Bugfix: `RunnerClient` keyword argument values processing
This commit is contained in:
commit
2f808d8762
@ -65,9 +65,11 @@ class RunnerClient(mixins.SyncClientMixin, mixins.AsyncClientMixin, object):
|
||||
# Support old style calls where arguments could be specified in 'low' top level
|
||||
if not low.get('args') and not low.get('kwargs'): # not specified or empty
|
||||
verify_fun(self.functions, fun)
|
||||
merged_args_kwargs = salt.utils.args.condition_input([], low)
|
||||
parsed_input = salt.utils.args.parse_input(merged_args_kwargs)
|
||||
args, kwargs = salt.minion.load_args_and_kwargs(
|
||||
self.functions[fun],
|
||||
salt.utils.args.condition_input([], low),
|
||||
parsed_input,
|
||||
self.opts,
|
||||
ignore_invalid=True
|
||||
)
|
||||
|
@ -60,7 +60,8 @@ def parse_input(args, condition=True):
|
||||
# condition_input is called below, but this is the only way to
|
||||
# gracefully handle both CLI and API input.
|
||||
if arg.pop('__kwarg__', False) is True:
|
||||
_kwargs.update(arg)
|
||||
for key, val in six.iteritems(arg):
|
||||
_kwargs[key] = yamlify_arg(val)
|
||||
else:
|
||||
_args.append(arg)
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user