Skip to content

Commit

Permalink
ci: always checkout the repo, even if we don't need the change detect…
Browse files Browse the repository at this point in the history
…ion (#887)

The change detection job is failing for non-pull-request checks, because
we need to explicitly checkout the repo on those cases.

See https://github.com/CQCL/hugr/actions/runs/8342261546/job/22830024125

I'm also adding `changes` as a requirement to the required check, so it
fails on errors like this.
  • Loading branch information
aborgna-q authored Mar 19, 2024
1 parent c10bad0 commit 555b8c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci-py.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
outputs:
python: ${{ github.ref_name == github.event.repository.default_branch || steps.filter.outputs.python }}
steps:
# For pull requests it's not necessary to checkout the code
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v3
id: filter
with:
Expand Down Expand Up @@ -78,7 +78,7 @@ jobs:
# even if they are skipped due to no changes in the relevant files.
required-checks:
name: Required checks 🐍
needs: [check]
needs: [changes, check]
if: always()
runs-on: ubuntu-latest
steps:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci-rs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
outputs:
rust: ${{ github.ref_name == github.event.repository.default_branch || steps.filter.outputs.rust }}
steps:
# For pull requests it's not necessary to checkout the code
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v3
id: filter
with:
Expand Down Expand Up @@ -133,7 +133,7 @@ jobs:
# even if they are skipped due to no changes in the relevant files.
required-checks:
name: Required checks 🦀
needs: [check, tests-stable]
needs: [changes, check, tests-stable]
if: always()
runs-on: ubuntu-latest
steps:
Expand Down

0 comments on commit 555b8c0

Please sign in to comment.