summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <daniel.friesel@uos.de>2019-10-02 16:50:05 +0200
committerDaniel Friesel <daniel.friesel@uos.de>2019-10-02 16:50:05 +0200
commitc03c396dd96db1a839fd4cc4d15519719e2c5705 (patch)
tree5eee07906bfd6a4c7c4be7ddc094c0c6e987c8c5
parent2f097a9cc8e64f644364051c1d12001f7186ef17 (diff)
runner: re-try mimosactl call if it failed
-rw-r--r--lib/runner.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/runner.py b/lib/runner.py
index 25e3519..3fa104b 100644
--- a/lib/runner.py
+++ b/lib/runner.py
@@ -143,7 +143,9 @@ class MIMOSAMonitor(SerialMonitor):
cmd.append(subcommand)
res = subprocess.run(cmd)
if res.returncode != 0:
- raise RuntimeError('{} returned {}'.format(' '.join(cmd), res.returncode))
+ res = subprocess.run(cmd)
+ if res.returncode != 0:
+ raise RuntimeError('{} returned {}'.format(' '.join(cmd), res.returncode))
def _mimosacmd(self, opts):
cmd = ['MimosaCMD']