Skip to content

Commit

Permalink
chore: correct the MSRV check (#934)
Browse files Browse the repository at this point in the history
## Motivation

The current MSRV check is lazybones, it's meaningless unless we override
toolchain. Actually, we cannot compile tracing crates with 1.39.0, it
should work with 1.44.0 or later because of the `protobuf` crate and
others. 
 
## Solution

This enforces to override toolchain and updates MSRV to 1.40.0, this
should compile all the crates fine. And replaces
`actions/checkout@master` with `main` as they've renamed the default
branch name to `main`.
  • Loading branch information
JohnTitor authored Aug 18, 2020
1 parent b358201 commit 1e086e8
Showing 1 changed file with 20 additions and 12 deletions.
32 changes: 20 additions & 12 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,14 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
rust: [stable, 1.39.0]
rust: [stable, 1.40.0]
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
profile: minimal
override: true
- name: Check
uses: actions-rs/cargo@v1
with:
Expand Down Expand Up @@ -66,11 +67,12 @@ jobs:
#- tracing
#- tracing-subscriber
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: Fetch latest release version of cargo-hack
run: |
mkdir -p .github/caching
Expand Down Expand Up @@ -102,11 +104,12 @@ jobs:
- std log-always
- std
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: cargo check
working-directory: tracing
run: cargo check --no-default-features --features "${{ matrix.featureset }}"
Expand All @@ -126,11 +129,12 @@ jobs:
- registry
- env-filter
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: cargo check
working-directory: tracing-subscriber
run: cargo check --no-default-features --features "${{ matrix.featureset }}"
Expand All @@ -141,13 +145,14 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
rust: [stable, beta, nightly, 1.39.0]
rust: [stable, beta, nightly, 1.40.0]
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
profile: minimal
override: true
- name: Run tests
uses: actions-rs/cargo@v1
with:
Expand All @@ -162,11 +167,12 @@ jobs:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: Run tests
uses: actions-rs/cargo@v1
with:
Expand All @@ -178,11 +184,12 @@ jobs:
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
profile: minimal
override: true
- name: "Test log support"
run: (cd tracing/test-log-support && cargo test)
- name: "Test static max level"
Expand All @@ -196,12 +203,13 @@ jobs:
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: rustfmt
profile: minimal
override: true
- name: rustfmt
uses: actions-rs/cargo@v1
with:
Expand All @@ -212,7 +220,7 @@ jobs:
# Check for any warnings. This is informational and thus is allowed to fail.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand All @@ -227,7 +235,7 @@ jobs:
cargo-audit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@main
- name: Fetch latest release version of cargo-audit
run: |
mkdir -p .github/caching
Expand Down

0 comments on commit 1e086e8

Please sign in to comment.