Add a temporary workaround to try to retry integration tests which fail
quite often due to races, etc. on failure.
This saves us a bunch of time manually re-running the whole workflow.
@@ -465,8 +465,22 @@ jobs:
./scripts/ci/print-versions.sh
- name: make
# use: script -e -c to print colors
+ env:
+ MAX_ATTEMPTS: 3
run: |
- script -e -c "make ${TASK}"
+ # There is a race in some orequesta integration tests so they tend to fail quite often.
+ # To avoid needed to re-run whole workflow in such case, we should try to retry this
+ # specific step. This saves us a bunch of time manually re-running the whole workflow.
+ set +e
+ for i in $(seq 1 ${MAX_ATTEMPTS}); do
+ echo "Attempt: ${i}"
+ script -e -c "make ${TASK}" && exit 0
+ sleep 5
+ done
+
+ set -e
+ echo "Failed after ${MAX_ATTEMPTS} attempts"
+ exit 1
- name: Codecov
# NOTE: We only generate and submit coverage report for master and version branches and only when the build succeeds (default on GitHub Actions, this was not the case on Travis so we had to explicitly check success)
if: "${{ success() && env.ENABLE_COVERAGE == 'yes' && env.TASK == 'ci-integration' }}"
