mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 17:09:03 +00:00
Deprecated quiet option
This commit is contained in:
parent
767dc23d7f
commit
d2617e1d13
@ -161,7 +161,6 @@ def _run(cmd,
|
|||||||
stdout=subprocess.PIPE,
|
stdout=subprocess.PIPE,
|
||||||
stderr=subprocess.PIPE,
|
stderr=subprocess.PIPE,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
runas=None,
|
runas=None,
|
||||||
shell=DEFAULT_SHELL,
|
shell=DEFAULT_SHELL,
|
||||||
python_shell=True,
|
python_shell=True,
|
||||||
@ -178,14 +177,6 @@ def _run(cmd,
|
|||||||
'''
|
'''
|
||||||
Do the DRY thing and only call subprocess.Popen() once
|
Do the DRY thing and only call subprocess.Popen() once
|
||||||
'''
|
'''
|
||||||
if salt.utils.is_true(quiet):
|
|
||||||
salt.utils.warn_until(
|
|
||||||
'Lithium',
|
|
||||||
'The \'quiet\' option is deprecated and will be removed in the '
|
|
||||||
'\'Lithium\' Salt release. Please use output_loglevel=quiet '
|
|
||||||
'instead.'
|
|
||||||
)
|
|
||||||
|
|
||||||
if _is_valid_shell(shell) is False:
|
if _is_valid_shell(shell) is False:
|
||||||
log.warning(
|
log.warning(
|
||||||
'Attempt to run a shell command with what may be an invalid shell! '
|
'Attempt to run a shell command with what may be an invalid shell! '
|
||||||
@ -294,7 +285,7 @@ def _run(cmd,
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
if _check_loglevel(output_loglevel, quiet) is not None:
|
if _check_loglevel(output_loglevel) is not None:
|
||||||
# Always log the shell commands at INFO unless quiet logging is
|
# Always log the shell commands at INFO unless quiet logging is
|
||||||
# requested. The command output is what will be controlled by the
|
# requested. The command output is what will be controlled by the
|
||||||
# 'loglevel' parameter.
|
# 'loglevel' parameter.
|
||||||
@ -549,7 +540,6 @@ def run(cmd,
|
|||||||
rstrip=True,
|
rstrip=True,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -612,7 +602,6 @@ def run(cmd,
|
|||||||
rstrip=rstrip,
|
rstrip=rstrip,
|
||||||
umask=umask,
|
umask=umask,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
timeout=timeout,
|
timeout=timeout,
|
||||||
reset_system_locale=reset_system_locale,
|
reset_system_locale=reset_system_locale,
|
||||||
saltenv=saltenv,
|
saltenv=saltenv,
|
||||||
@ -635,7 +624,7 @@ def run(cmd,
|
|||||||
with salt.utils.fopen(jid_file, 'w+b') as fn_:
|
with salt.utils.fopen(jid_file, 'w+b') as fn_:
|
||||||
fn_.write(serial.dumps(jid_dict))
|
fn_.write(serial.dumps(jid_dict))
|
||||||
|
|
||||||
lvl = _check_loglevel(output_loglevel, quiet)
|
lvl = _check_loglevel(output_loglevel)
|
||||||
if lvl is not None:
|
if lvl is not None:
|
||||||
if not ignore_retcode and ret['retcode'] != 0:
|
if not ignore_retcode and ret['retcode'] != 0:
|
||||||
if lvl < LOG_LEVELS['error']:
|
if lvl < LOG_LEVELS['error']:
|
||||||
@ -660,7 +649,6 @@ def run_stdout(cmd,
|
|||||||
rstrip=True,
|
rstrip=True,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -707,13 +695,12 @@ def run_stdout(cmd,
|
|||||||
rstrip=rstrip,
|
rstrip=rstrip,
|
||||||
umask=umask,
|
umask=umask,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
timeout=timeout,
|
timeout=timeout,
|
||||||
reset_system_locale=reset_system_locale,
|
reset_system_locale=reset_system_locale,
|
||||||
saltenv=saltenv,
|
saltenv=saltenv,
|
||||||
use_vt=use_vt)
|
use_vt=use_vt)
|
||||||
|
|
||||||
lvl = _check_loglevel(output_loglevel, quiet)
|
lvl = _check_loglevel(output_loglevel)
|
||||||
if lvl is not None:
|
if lvl is not None:
|
||||||
if not ignore_retcode and ret['retcode'] != 0:
|
if not ignore_retcode and ret['retcode'] != 0:
|
||||||
if lvl < LOG_LEVELS['error']:
|
if lvl < LOG_LEVELS['error']:
|
||||||
@ -743,7 +730,6 @@ def run_stderr(cmd,
|
|||||||
rstrip=True,
|
rstrip=True,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -790,13 +776,12 @@ def run_stderr(cmd,
|
|||||||
rstrip=rstrip,
|
rstrip=rstrip,
|
||||||
umask=umask,
|
umask=umask,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
timeout=timeout,
|
timeout=timeout,
|
||||||
reset_system_locale=reset_system_locale,
|
reset_system_locale=reset_system_locale,
|
||||||
use_vt=use_vt,
|
use_vt=use_vt,
|
||||||
saltenv=saltenv)
|
saltenv=saltenv)
|
||||||
|
|
||||||
lvl = _check_loglevel(output_loglevel, quiet)
|
lvl = _check_loglevel(output_loglevel)
|
||||||
if lvl is not None:
|
if lvl is not None:
|
||||||
if not ignore_retcode and ret['retcode'] != 0:
|
if not ignore_retcode and ret['retcode'] != 0:
|
||||||
if lvl < LOG_LEVELS['error']:
|
if lvl < LOG_LEVELS['error']:
|
||||||
@ -826,7 +811,6 @@ def run_all(cmd,
|
|||||||
rstrip=True,
|
rstrip=True,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -873,13 +857,12 @@ def run_all(cmd,
|
|||||||
rstrip=rstrip,
|
rstrip=rstrip,
|
||||||
umask=umask,
|
umask=umask,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
timeout=timeout,
|
timeout=timeout,
|
||||||
reset_system_locale=reset_system_locale,
|
reset_system_locale=reset_system_locale,
|
||||||
saltenv=saltenv,
|
saltenv=saltenv,
|
||||||
use_vt=use_vt)
|
use_vt=use_vt)
|
||||||
|
|
||||||
lvl = _check_loglevel(output_loglevel, quiet)
|
lvl = _check_loglevel(output_loglevel)
|
||||||
if lvl is not None:
|
if lvl is not None:
|
||||||
if not ignore_retcode and ret['retcode'] != 0:
|
if not ignore_retcode and ret['retcode'] != 0:
|
||||||
if lvl < LOG_LEVELS['error']:
|
if lvl < LOG_LEVELS['error']:
|
||||||
@ -908,7 +891,6 @@ def retcode(cmd,
|
|||||||
template=None,
|
template=None,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='debug',
|
output_loglevel='debug',
|
||||||
quiet=False,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -959,13 +941,12 @@ def retcode(cmd,
|
|||||||
template=template,
|
template=template,
|
||||||
umask=umask,
|
umask=umask,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
timeout=timeout,
|
timeout=timeout,
|
||||||
reset_system_locale=reset_system_locale,
|
reset_system_locale=reset_system_locale,
|
||||||
saltenv=saltenv,
|
saltenv=saltenv,
|
||||||
use_vt=use_vt)
|
use_vt=use_vt)
|
||||||
|
|
||||||
lvl = _check_loglevel(output_loglevel, quiet)
|
lvl = _check_loglevel(output_loglevel)
|
||||||
if lvl is not None:
|
if lvl is not None:
|
||||||
if not ignore_retcode and ret['retcode'] != 0:
|
if not ignore_retcode and ret['retcode'] != 0:
|
||||||
if lvl < LOG_LEVELS['error']:
|
if lvl < LOG_LEVELS['error']:
|
||||||
@ -989,7 +970,6 @@ def _retcode_quiet(cmd,
|
|||||||
template=None,
|
template=None,
|
||||||
umask=None,
|
umask=None,
|
||||||
output_loglevel='quiet',
|
output_loglevel='quiet',
|
||||||
quiet=True,
|
|
||||||
timeout=None,
|
timeout=None,
|
||||||
reset_system_locale=True,
|
reset_system_locale=True,
|
||||||
ignore_retcode=False,
|
ignore_retcode=False,
|
||||||
@ -1112,7 +1092,6 @@ def script(source,
|
|||||||
cwd=cwd,
|
cwd=cwd,
|
||||||
stdin=stdin,
|
stdin=stdin,
|
||||||
output_loglevel=output_loglevel,
|
output_loglevel=output_loglevel,
|
||||||
quiet=quiet,
|
|
||||||
runas=runas,
|
runas=runas,
|
||||||
shell=shell,
|
shell=shell,
|
||||||
python_shell=python_shell,
|
python_shell=python_shell,
|
||||||
|
Loading…
Reference in New Issue
Block a user