[yocto-autobuilder-helper][dunfell 04/23] scripts/generate-testresult-index.py: Ensure we're not always rerunning resulttool


Steve Sakoman
 

From: Richard Purdie <richard.purdie@linuxfoundation.org>

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit 098de71cbdfcb9d0cd24f604cf049a7a596b8513)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
---
scripts/generate-testresult-index.py | 3 +++
1 file changed, 3 insertions(+)

diff --git a/scripts/generate-testresult-index.py b/scripts/generate-testresult-index.py
index 7839cc0..52be26b 100755
--- a/scripts/generate-testresult-index.py
+++ b/scripts/generate-testresult-index.py
@@ -121,6 +121,9 @@ for build in sorted(os.listdir(path), key=keygen, reverse=True):
if logs:
continue
subprocess.check_call(["resulttool", "log", f, "--dump-ptest", f])
+ # Ensure we don't rerun every time with a dummy log
+ with open(f + "/resulttool-done.log", "a+") as tf:
+ tf.write("\n")

t = Template(index_templpate)
with open(os.path.join(path, "index.html"), 'w') as f:
--
2.25.1