Skip to content

Commit

Permalink
ci: test latest stable (instead of nightly), fix #1587 (#1607)
Browse files Browse the repository at this point in the history
stable tests will fail for now
  • Loading branch information
MingweiSamuel authored Dec 12, 2024
1 parent 251b103 commit 1058b51
Showing 1 changed file with 22 additions and 23 deletions.
45 changes: 22 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
rust_release: [pinned-nightly, latest-nightly]
rust_release: [pinned-nightly, latest-stable]
exclude:
# For non-pull requests, event_name != 'pull_request' will be true, and 'nothing' is
# truthy, so the entire && operator will resolve to 'nothing'. Then the || operator will
# resolve to 'nothing' so we will exclude 'nothing'. https://stackoverflow.com/a/73822998
- rust_release: ${{ (needs.pre_job.outputs.should_skip != 'true' && 'nothing') || 'pinned-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-stable' }}

env:
CARGO_TERM_COLOR: always
Expand All @@ -55,12 +55,12 @@ jobs:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install nightly toolchain
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: ${{ matrix.rust_release == 'latest-nightly' }}
toolchain: stable
override: ${{ matrix.rust_release == 'latest-stable' }}
components: rustfmt, clippy

- name: Run sccache-cache
Expand Down Expand Up @@ -96,25 +96,25 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
rust_release: [pinned-nightly, latest-nightly]
rust_release: [pinned-nightly, latest-stable]
exclude:
# For non-pull requests, event_name != 'pull_request' will be true, and 'nothing' is
# truthy, so the entire && operator will resolve to 'nothing'. Then the || operator will
# resolve to 'nothing' so we will exclude 'nothing'. https://stackoverflow.com/a/73822998
- rust_release: ${{ (needs.pre_job.outputs.should_skip != 'true' && 'nothing') || 'pinned-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-stable' }}

steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install nightly toolchain
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
target: wasm32-unknown-unknown
override: ${{ matrix.rust_release == 'latest-nightly' }}
override: ${{ matrix.rust_release == 'latest-stable' }}

- name: Check hydroflow_lang
uses: actions-rs/cargo@v1
Expand All @@ -132,13 +132,13 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
rust_release: [pinned-nightly, latest-nightly]
rust_release: [pinned-nightly, latest-stable]
exclude:
# For non-pull requests, event_name != 'pull_request' will be true, and 'nothing' is
# truthy, so the entire && operator will resolve to 'nothing'. Then the || operator will
# resolve to 'nothing' so we will exclude 'nothing'. https://stackoverflow.com/a/73822998
- rust_release: ${{ (needs.pre_job.outputs.should_skip != 'true' && 'nothing') || 'pinned-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-stable' }}
- os: ${{ (github.event_name != 'pull_request' && 'nothing') || 'windows-latest' }}

env:
Expand All @@ -152,12 +152,12 @@ jobs:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install nightly toolchain
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: ${{ matrix.rust_release == 'latest-nightly' }}
toolchain: stable
override: ${{ matrix.rust_release == 'latest-stable' }}

- name: Run sccache-cache
if: matrix.rust_release == 'pinned-nightly'
Expand Down Expand Up @@ -217,7 +217,7 @@ jobs:
cd python_tests
pip install -r requirements.txt
RUST_BACKTRACE=1 pytest
- name: Run Python tests (Windows)
if: ${{ matrix.os == 'windows-latest' }}
run: |
Expand All @@ -235,25 +235,25 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
rust_release: [pinned-nightly, latest-nightly]
rust_release: [pinned-nightly, latest-stable]
exclude:
# For non-pull requests, event_name != 'pull_request' will be true, and 'nothing' is
# truthy, so the entire && operator will resolve to 'nothing'. Then the || operator will
# resolve to 'nothing' so we will exclude 'nothing'. https://stackoverflow.com/a/73822998
- rust_release: ${{ (needs.pre_job.outputs.should_skip != 'true' && 'nothing') || 'pinned-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-nightly' }}
- rust_release: ${{ (github.event_name != 'pull_request' && 'nothing') || 'latest-stable' }}

steps:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install nightly toolchain
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
toolchain: stable
target: wasm32-unknown-unknown
override: ${{ matrix.rust_release == 'latest-nightly' }}
override: ${{ matrix.rust_release == 'latest-stable' }}

- name: Get wasm-bindgen version
id: wasm-bindgen-version
Expand Down Expand Up @@ -366,11 +366,10 @@ jobs:
- name: Checkout sources
uses: actions/checkout@v3

- name: Install nightly toolchain
- name: Install toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly

- name: Checkout gh-pages
shell: bash
Expand Down

0 comments on commit 1058b51

Please sign in to comment.