From e9d5a3014fb16558e0799c4c991eb0cb4efce399 Mon Sep 17 00:00:00 2001 From: Thomas Eizinger Date: Sat, 17 Dec 2022 08:25:19 +1100 Subject: [PATCH] ci(cache): override rust version in cache factory for MSRV cache (#3248) Previously, we forgot to override the default Rust version used to the newly installed one for the MSRV cache. This caused `swatinem/rust-cache` to compute the wrong cache key. See https://github.com/libp2p/rust-libp2p/actions/runs/3697491863/jobs/6262555434#step:5:21 for example. This caused all pull-requests to not actually find this cache and rebuild everything from scratch: https://github.com/libp2p/rust-libp2p/actions/runs/3699757580/jobs/6267459677#step:6:21 With this patch, we are now considering the correct Rust version: https://github.com/thomaseizinger/rust-libp2p/actions/runs/3699821930/jobs/6267596081#step:5:21 --- .github/workflows/cache-factory.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/cache-factory.yml b/.github/workflows/cache-factory.yml index f63e8ad7..d332a547 100644 --- a/.github/workflows/cache-factory.yml +++ b/.github/workflows/cache-factory.yml @@ -41,6 +41,7 @@ jobs: - uses: actions-rs/toolchain@16499b5e05bf2e26879000db0c1d13f7e13fa3af # v1.0.7 with: toolchain: ${{ matrix.rust }} + override: true - uses: Swatinem/rust-cache@359a70e43a0bb8a13953b04a90f76428b4959bb6 # v2.2.0 with: @@ -63,6 +64,7 @@ jobs: - uses: actions-rs/toolchain@16499b5e05bf2e26879000db0c1d13f7e13fa3af # v1.0.7 with: toolchain: stable + override: true - uses: Swatinem/rust-cache@359a70e43a0bb8a13953b04a90f76428b4959bb6 # v2.2.0 with: