| |
@@ -10,6 +10,7 @@
|
| |
import sys
|
| |
import time
|
| |
import utils
|
| |
+ import uuid
|
| |
|
| |
import fedora_messaging.api
|
| |
import fedora_messaging.exceptions
|
| |
@@ -59,25 +60,36 @@
|
| |
delay_when_failing = conf["delay_when_failing"]
|
| |
blocker_tags = conf["blocker_tags"]
|
| |
print("Tests started:", datetime.datetime.utcnow(), flush=True)
|
| |
+ runid = f"{datetime.datetime.utcnow().year}-{uuid.uuid4()}"
|
| |
try:
|
| |
# Single Build Gating
|
| |
single_args = conf["workflow_single_gating_args"].split()
|
| |
- notify(topic=f"single-build.start", message={"arguments": single_args,})
|
| |
+ notify(
|
| |
+ topic=f"single-build.start",
|
| |
+ message={"arguments": single_args, "runid": runid,},
|
| |
+ )
|
| |
output = monitor_gating_single_build.main(single_args)
|
| |
output_text = "\n".join(output)
|
| |
- output_text = "\n".join(output)
|
| |
if "[FAILED]" not in output_text:
|
| |
result = "succeeded"
|
| |
else:
|
| |
result = "failed"
|
| |
notify(
|
| |
topic=f"single-build.end.{result}",
|
| |
- message={"output": output, "output_text": output_text, "result": result,},
|
| |
+ message={
|
| |
+ "output": output,
|
| |
+ "output_text": output_text,
|
| |
+ "result": result,
|
| |
+ "runid": runid,
|
| |
+ },
|
| |
)
|
| |
|
| |
# Multi Build Gating
|
| |
multi_args = conf["workflow_multi_gating_args"].split()
|
| |
- notify(topic=f"multi-build.start", message={"arguments": multi_args,})
|
| |
+ notify(
|
| |
+ topic=f"multi-build.start",
|
| |
+ message={"arguments": multi_args, "runid": runid,},
|
| |
+ )
|
| |
output = monitor_gating_multi_builds.main(multi_args)
|
| |
output_text = "\n".join(output)
|
| |
if "[FAILED]" not in output_text:
|
| |
@@ -86,7 +98,12 @@
|
| |
result = "failed"
|
| |
notify(
|
| |
topic=f"multi-build.end.{result}",
|
| |
- message={"output": output, "output_text": output_text, "result": result,},
|
| |
+ message={
|
| |
+ "output": output,
|
| |
+ "output_text": output_text,
|
| |
+ "result": result,
|
| |
+ "runid": runid,
|
| |
+ },
|
| |
)
|
| |
|
| |
print("Tests finished:", datetime.datetime.utcnow(), flush=True)
|
| |
This way when going to back through the history of the runs, we can
tie the start messages with the end messages.
Signed-off-by: Pierre-Yves Chibon pingou@pingoured.fr