From 7b97fe206bc3c782612eb1be5b86cce99227fc6b Mon Sep 17 00:00:00 2001 From: Scott Wittenburg Date: Wed, 10 Mar 2021 12:11:30 -0700 Subject: Pipelines: Fix issue that allowed failing jobs to pass (#22199) This is a workaround for an issue with how "spack install" is invoked from within "spack ci rebuild". The fact that we don't get an exception or even the actual returncode when using the object returned by spack.util.executable.which('spack') to install the target spec means we get no indication of failures about the install command itself. Instead we rely on the subsequent buildcache creation failure to fail the job. --- lib/spack/spack/ci.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/spack/spack/ci.py b/lib/spack/spack/ci.py index b0e0b25191..ac79fb642e 100644 --- a/lib/spack/spack/ci.py +++ b/lib/spack/spack/ci.py @@ -1291,7 +1291,9 @@ def push_mirror_contents(env, spec, yaml_path, mirror_url, build_id, if 'Access Denied' in err_msg: tty.msg('Permission problem writing to {0}'.format( mirror_url)) - tty.msg(err_msg) + tty.msg(err_msg) + else: + raise inst def copy_stage_logs_to_artifacts(job_spec, job_log_dir): -- cgit v1.2.3-70-g09d2