mirror of https://github.com/zulip/zulip.git
ruff: Fix S605 Starting a process with a shell.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
parent
a1a341f0ae
commit
eb622bae0a
|
@ -275,11 +275,16 @@ def install_yum_deps(deps_to_install: List[str]) -> None:
|
|||
# Requires: perl(IPC::Run)
|
||||
yum_extra_flags: List[str] = []
|
||||
if vendor == "rhel":
|
||||
exitcode, subs_status = subprocess.getstatusoutput("sudo subscription-manager status")
|
||||
if exitcode == 1:
|
||||
proc = subprocess.run(
|
||||
["sudo", "subscription-manager", "status"],
|
||||
stdout=subprocess.PIPE,
|
||||
text=True,
|
||||
check=False,
|
||||
)
|
||||
if proc.returncode == 1:
|
||||
# TODO this might overkill since `subscription-manager` is already
|
||||
# called in setup-yum-repo
|
||||
if "Status" in subs_status:
|
||||
if "Status" in proc.stdout:
|
||||
# The output is well-formed
|
||||
yum_extra_flags = ["--skip-broken"]
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue