From b3b675157c03a7c412d1d7f5b4696dc4d3a618a7 Mon Sep 17 00:00:00 2001 From: Scott Wittenburg Date: Mon, 7 Nov 2022 16:11:04 -0700 Subject: gitlab ci: Add "script_failure" as a reason for retrying service jobs (#33420) Somehow a network error when cloning the repo for ci gets categorized by gitlab as a script failure. To make sure we retry jobs that failed for that reason or a similar one, include "script_failure" as one of the reasons for retrying service jobs (which include "no specs to rebuild" jobs, update buildcache index jobs, and temp storage cleanup jobs. --- lib/spack/spack/ci.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lib/spack/spack/ci.py b/lib/spack/spack/ci.py index 56b3b249ac..aa54b71b3d 100644 --- a/lib/spack/spack/ci.py +++ b/lib/spack/spack/ci.py @@ -1167,7 +1167,14 @@ def generate_gitlab_ci_yaml( "after_script", ] - service_job_retries = {"max": 2, "when": ["runner_system_failure", "stuck_or_timeout_failure"]} + service_job_retries = { + "max": 2, + "when": [ + "runner_system_failure", + "stuck_or_timeout_failure", + "script_failure", + ], + } if job_id > 0: if temp_storage_url_prefix: -- cgit v1.2.3-70-g09d2