Skip to content

Commit

Permalink
ci: Fix MSRV build by precisely specifying some deps. (#731)
Browse files Browse the repository at this point in the history
* ci: Fix MSRV build by precisely specifying some deps.

* ci: Don't fail fast if one Rust version fails.

* clippy: Fix `unwrap_or_default` lint.
  • Loading branch information
waywardmonkeys committed Oct 15, 2023
1 parent 180f4b4 commit e2de721
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
ci:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
rust:
- stable
Expand All @@ -33,6 +34,14 @@ jobs:
- uses: Swatinem/rust-cache@v2
name: Load dependencies from cache

- name: Fix dep versions for MSRV
if: ${{ matrix.rust == '1.64.0' }}
run: |
cargo update -p clap --precise 4.3.24 # 4.4 moves to msrv 1.70
cargo update -p clap_lex --precise 0.5.0 # 0.5.1 moves to msrv 1.70 in a patch release
cargo update -p anstyle --precise 1.0.2 # 1.0.3 moves to msrv 1.70 in a patch release
cargo update -p regex --precise 1.9.6 # 1.10 moves to msrv 1.65
- name: Build with stable features
run: cargo build --features stable

Expand Down
5 changes: 1 addition & 4 deletions src/html/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -530,10 +530,7 @@ impl Report for Html {
// Group IDs by group id
let mut id_groups: HashMap<&str, Vec<&BenchmarkId>> = HashMap::new();
for id in found_ids.iter() {
id_groups
.entry(&id.group_id)
.or_insert_with(Vec::new)
.push(id);
id_groups.entry(&id.group_id).or_default().push(id);
}

let mut groups = id_groups
Expand Down

0 comments on commit e2de721

Please sign in to comment.