From: Zack Cerza Date: Tue, 24 May 2016 23:33:21 +0000 (-0600) Subject: When bootstrap/fetch fails, mark the job as dead X-Git-Tag: 1.1.0~609^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=7b461117295e947323df66d479e3bbbb644c4990;p=teuthology.git When bootstrap/fetch fails, mark the job as dead Note that this will only happen *after* all retries have failed. http://tracker.ceph.com/issues/13925 Fixes: 13925 Signed-off-by: Zack Cerza --- diff --git a/teuthology/worker.py b/teuthology/worker.py index a6982049ba..6a1e16fd5a 100644 --- a/teuthology/worker.py +++ b/teuthology/worker.py @@ -14,7 +14,7 @@ from . import report from . import safepath from .config import config as teuth_config from .config import set_config_attr -from .exceptions import BranchNotFoundError, SkipJob +from .exceptions import BranchNotFoundError, SkipJob, MaxWhileTries from .kill import kill_job from .repo_utils import fetch_qa_suite, fetch_teuthology @@ -159,6 +159,13 @@ def prep_job(job_config, log_file_path, archive_dir): dict(status='dead', failure_reason=str(exc)) ) raise SkipJob() + except MaxWhileTries as exc: + log.exception("Failed to fetch or bootstrap; marking job as dead") + report.try_push_job_info( + job_config, + dict(status='dead', failure_reason=str(exc)) + ) + raise SkipJob() teuth_bin_path = os.path.join(teuth_path, 'virtualenv', 'bin') if not os.path.isdir(teuth_bin_path):