From 4a75d99c80a1e89ce9dd185d970f0bec28f5015f Mon Sep 17 00:00:00 2001 From: Matthew Beale Date: Thu, 9 Dec 2021 16:46:40 -0500 Subject: [PATCH] 4 retries on CI, 1s sleep (#352) --- bin/run-tests-with-retry.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/run-tests-with-retry.sh b/bin/run-tests-with-retry.sh index c749e2e2..ffcd31b1 100755 --- a/bin/run-tests-with-retry.sh +++ b/bin/run-tests-with-retry.sh @@ -4,7 +4,7 @@ function retry { command="$*" retval=1 attempt=1 - until [[ $retval -eq 0 ]] || [[ $attempt -gt 3 ]]; do + until [[ $retval -eq 0 ]] || [[ $attempt -gt 4 ]]; do # Execute inside of a subshell in case parent # script is running with "set -e" ( @@ -15,10 +15,10 @@ function retry { attempt=$(( $attempt + 1 )) if [[ $retval -ne 0 ]]; then # If there was an error wait 10 seconds - sleep 10 + sleep 1 fi done - if [[ $retval -ne 0 ]] && [[ $attempt -gt 3 ]]; then + if [[ $retval -ne 0 ]] && [[ $attempt -gt 4 ]]; then # Something is fubar, go ahead and exit exit $retval fi