Skip to content

Commit

Permalink
CI: use checked-in Cargo.lock for MSRV test
Browse files Browse the repository at this point in the history
the transient dependency `log` requires a newer MSRV starting with
0.4.18. this way we force it to 0.4.17 which is compatible with our
MSRV. the same is the case for `chrono` which changed with 0.4.27 and
which we accordingly force to 0.4.26 for the MSRV check.
this is only used with the MSRV check, for all other tests we let
cargo test against the latest version.

note also that the cargo team has recently published an article on their
[change in guidance on commiting lockfiles][blog] which also suggests
providing a `Cargo.lock` for the MSRV build.

[blog]: https://blog.rust-lang.org/2023/08/29/committing-lockfiles.html
  • Loading branch information
rursprung committed Sep 23, 2023
1 parent c00b35b commit 7cf05f4
Showing 2 changed files with 516 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -24,6 +24,9 @@ jobs:
with:
toolchain: ${{ matrix.rust }}
components: rustfmt clippy
- name: use MSRV-compatible dependencies for MSRV check
if: ${{ matrix.os != 'stable' }}
run: cp Cargo.lock.rust-msrv Cargo.lock
- name: build
run: cargo build ${{ matrix.features }}
- name: check
Loading

0 comments on commit 7cf05f4

Please sign in to comment.