From: Zack Cerza Date: Thu, 27 Jul 2023 17:49:16 +0000 (-0600) Subject: supervisor.reimage: Report failures to Sentry X-Git-Tag: 1.2.0~83^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F1875%2Fhead;p=teuthology.git supervisor.reimage: Report failures to Sentry Signed-off-by: Zack Cerza --- diff --git a/teuthology/dispatcher/supervisor.py b/teuthology/dispatcher/supervisor.py index b197f1c8..98bbb3f6 100644 --- a/teuthology/dispatcher/supervisor.py +++ b/teuthology/dispatcher/supervisor.py @@ -19,6 +19,7 @@ from teuthology.lock import ops as lock_ops from teuthology.task import internal from teuthology.misc import decanonicalize_hostname as shortname from teuthology.lock import query +from teuthology.util import sentry log = logging.getLogger(__name__) @@ -232,6 +233,7 @@ def reimage(job_config): ctx.config, dict(status='dead', failure_reason='Error reimaging machines: ' + str(e)) ) + ctx.summary['sentry_event'] = sentry.report_error(job_config, e) nuke.nuke(ctx, True) # Machine that fails to reimage after 10 times will be marked down check_for_reimage_failures_and_mark_down(targets)