From b1d0da8a45a414f2afb0260828d901620c982f24 Mon Sep 17 00:00:00 2001 From: Junho Choi Date: Fri, 12 Jul 2024 11:03:30 +0900 Subject: [PATCH 1/2] ci: add cargo-machete in the workflow Run cargo-machete for unused dependency check, only on a default ssl target. --- .github/workflows/stable.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/stable.yml b/.github/workflows/stable.yml index fad84316b7..bef6186fac 100644 --- a/.github/workflows/stable.yml +++ b/.github/workflows/stable.yml @@ -30,6 +30,10 @@ jobs: toolchain: ${{ env.RUSTTOOLCHAIN }} components: clippy + - name: Unused dependency check + if: ${{ matrix.tls-feature == '' }} + uses: bnjbvr/cargo-machete@main + - name: Build OpenSSL if: ${{ matrix.tls-feature == 'openssl' }} run: | From 475ce3e1913f527db4f7e1a6216181bc44ba1f59 Mon Sep 17 00:00:00 2001 From: Junho Choi Date: Fri, 12 Jul 2024 11:05:45 +0900 Subject: [PATCH 2/2] Remove unused dependencies Recommended by cargo-machete --- qlog/Cargo.toml | 1 - tools/http3_test/Cargo.toml | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/qlog/Cargo.toml b/qlog/Cargo.toml index 1472a83b19..7008121551 100644 --- a/qlog/Cargo.toml +++ b/qlog/Cargo.toml @@ -13,6 +13,5 @@ license = "BSD-2-Clause" [dependencies] serde = { version = "1.0.139", features = ["derive"] } serde_json = { version = "1.0", features = ["preserve_order"] } -serde_derive = "1.0" serde_with = { version = "3.0.0", default-features = false, features = ["macros"] } smallvec = { version = "1.10", features = ["serde"] } diff --git a/tools/http3_test/Cargo.toml b/tools/http3_test/Cargo.toml index f6e71103cb..f312dee6d0 100644 --- a/tools/http3_test/Cargo.toml +++ b/tools/http3_test/Cargo.toml @@ -9,13 +9,11 @@ publish = false test_resets = [] [dependencies] -docopt = "1" env_logger = "0.10" mio = { version = "0.8", features = ["net", "os-poll"] } url = "1" log = "0.4" ring = "0.17" -serde = "1.0" +serde = { version = "1.0", features = ["derive"] } serde_json = "1.0" -serde_derive = "1.0" quiche = { path = "../../quiche"}