diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 70a2d25fac..7dbec868e5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,8 +40,8 @@ jobs: build: needs: set-nightly - # `always` *must* be used to continue even after a dependency has been skipped - if: always() && (github.event_name != 'schedule' || github.repository == 'leanprover/lean4') + # `failure` to continue even after a dependency was skipped + if: (success() || failure()) && (github.event_name != 'schedule' || github.repository == 'leanprover/lean4') runs-on: ${{ matrix.os }} defaults: run: @@ -236,8 +236,8 @@ jobs: # When GitHub says "If a job fails, all jobs that need it are skipped unless # the jobs use a conditional expression that causes the job to continue.", don't believe # their lies. It's actually the entire closure (i.e. including `set-nightly`) that - # must succeed for subsequent to be run without `always()`. - if: always() && needs.build.result == 'success' && startsWith(github.ref, 'refs/tags/v') + # must succeed for subsequent to be run without the conditional. + if: (success() || failure()) && needs.build.result == 'success' && startsWith(github.ref, 'refs/tags/v') runs-on: ubuntu-latest needs: build steps: