Skip to content

Commit

Permalink
ci: πŸ”¨ allow duplicate dependencies
Browse files Browse the repository at this point in the history
addresses this error linting our dependency tree:

```
error[duplicate]: found 2 duplicate entries for crate 'heck'
   β”Œβ”€ /home/katie/work/tonic/Cargo.lock:58:1
   β”‚
58 β”‚ β•­ heck 0.4.1 registry+https://github.com/rust-lang/crates.io-index
59 β”‚ β”‚ heck 0.5.0 registry+https://github.com/rust-lang/crates.io-index
   β”‚ ╰────────────────────────────────────────────────────────────────^ lock entries
   β”‚
   = heck v0.4.1
     └── strum_macros v0.25.3
         └── strum v0.25.0
             └── interop v0.1.0
   = heck v0.5.0
     └── prost-build v0.12.6
         β”œβ”€β”€ (build) disable-comments v0.1.0
         β”œβ”€β”€ tonic-build v0.10.2
         β”‚   β”œβ”€β”€ (build) ambiguous_methods v0.1.0
         β”‚   β”œβ”€β”€ codegen v0.1.0
         β”‚   β”œβ”€β”€ (build) compression v0.1.0
         β”‚   β”œβ”€β”€ (build) default_stubs v0.1.0
         β”‚   β”œβ”€β”€ (build) disable-comments v0.1.0 (*)
         β”‚   β”œβ”€β”€ (build) examples v0.1.0
         β”‚   β”œβ”€β”€ (build) included_service v0.1.0
         β”‚   β”œβ”€β”€ (build) integration v0.1.0
         β”‚   β”œβ”€β”€ (build) integration-tests v0.1.0
         β”‚   β”œβ”€β”€ (build) interop v0.1.0
         β”‚   β”œβ”€β”€ (build) my_application v0.1.0
         β”‚   β”œβ”€β”€ (build) root-crate-path v0.1.0
         β”‚   β”œβ”€β”€ (build) same_name v0.1.0
         β”‚   β”œβ”€β”€ (build) service_named_result v0.1.0
         β”‚   β”œβ”€β”€ (build) service_named_service v0.1.0
         β”‚   β”œβ”€β”€ (build) stream_conflict v0.1.0
         β”‚   β”œβ”€β”€ (build) use_arc_self v0.1.0
         β”‚   β”œβ”€β”€ (build) wellknown v0.1.0
         β”‚   └── (build) wellknown-compiled v0.1.0
         β”œβ”€β”€ (build) uuid1 v0.1.0
         β”‚   └── my_application v0.1.0 (*)
         └── (build) wellknown-compiled v0.1.0 (*)

advisories ok, bans FAILED, licenses ok, sources ok
```
  • Loading branch information
cratelyn committed May 20, 2024
1 parent 6792783 commit 9677d70
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,29 @@ jobs:
- run: cargo fmt --all --check

deny-check:
# NOTE(kate): this allows for duplicate dependencies of a single crate.
# Since 0.10.2 was released, releases have drifted and `prost-build` and
# `strum-macros` depend on different versions of `heck`.
#
# rather than changing v0.10.2, we pass `--allow duplicate` for now, until
# we upgrade to [email protected].
#
# ```
# error[duplicate]: found 2 duplicate entries for crate 'heck'
# β”Œβ”€ /home/katie/work/tonic/Cargo.lock:58:1
# β”‚
# 58 β”‚ β•­ heck 0.4.1 registry+https://github.com/rust-lang/crates.io-index
# 59 β”‚ β”‚ heck 0.5.0 registry+https://github.com/rust-lang/crates.io-index
# β”‚ ╰────────────────────────────────────────────────────────────────^ lock entries
# ```
name: cargo-deny check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: EmbarkStudios/cargo-deny-action@v1
with:
- command: check
- arguments: --allow duplicate

codegen:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 9677d70

Please sign in to comment.