From 7e51ca158758b93cc1a5c70eb7a6316224d3d0d3 Mon Sep 17 00:00:00 2001 From: Zack Cerza Date: Thu, 23 Mar 2023 12:22:15 -0600 Subject: [PATCH] sueprvisor: Do not instrument certain job times This should only really include first/last-in-suite jobs. Signed-off-by: Zack Cerza --- teuthology/dispatcher/supervisor.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/teuthology/dispatcher/supervisor.py b/teuthology/dispatcher/supervisor.py index 595193c85..874f0ce75 100644 --- a/teuthology/dispatcher/supervisor.py +++ b/teuthology/dispatcher/supervisor.py @@ -60,7 +60,16 @@ def main(args): yaml.safe_dump(job_config, f, default_flow_style=False) try: - with exporter.JobTime.labels(job_config["suite"]).time(): + suite = job_config.get("suite") + if suite: + with exporter.JobTime.labels(suite).time(): + return run_job( + job_config, + teuth_bin_path, + archive_dir, + verbose + ) + else: return run_job( job_config, teuth_bin_path, -- 2.47.3