add logging

This commit is contained in:
Usman Nasir
2021-08-12 19:43:47 +05:00
parent 4911411aa9
commit 97ab0ab579

View File

@@ -106,7 +106,7 @@ class Upgrade:
FNULL = open(os.devnull, 'w') FNULL = open(os.devnull, 'w')
count = 0 count = 0
while True: while True:
res = subprocess.call(shlex.split(command), stdout=FNULL, stderr=subprocess.STDOUT) res = subprocess.call(shlex.split(command), stderr=subprocess.STDOUT)
if res != 0: if res != 0:
count = count + 1 count = count + 1
Upgrade.stdOut(component + ' failed, trying again, try number: ' + str(count), 0) Upgrade.stdOut(component + ' failed, trying again, try number: ' + str(count), 0)