Skip to content

Commit

Permalink
Issue #422: Intentionally fail every build attempt
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewmogan committed Jan 23, 2025
1 parent 1ad3ea9 commit e522798
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions scripts/spack/build-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,10 +109,9 @@ while true; do
echo " --- Build attempt number $attempt of $max_attempts --- "
spack install --reuse ${DET}daq@${RELEASE_TAG}%gcc@${GCC_VERSION} build_type=RelWithDebInfo arch=linux-${OS}-x86_64 | tee dunedaq_build_spack_install.log || true
spack_install_exit_code=${PIPESTATUS[0]}
if [[ $attempt -eq 1 ]]; then
bash -c "echo '==> Error: FetchError: All fetchers failed'; exit 42" 2>&1 | tee dunedaq_build_spack_install.log
spack_install_exit_code=${PIPESTATUS[0]}
fi
# Intentional failure on each attempt
bash -c "echo '==> Error: FetchError: All fetchers failed'; exit 42" 2>&1 | tee dunedaq_build_spack_install.log
spack_install_exit_code=${PIPESTATUS[0]}
if [[ $spack_install_exit_code -eq 0 ]]; then
echo "Build succeeded on attempt number $attempt"
break
Expand Down

0 comments on commit e522798

Please sign in to comment.