From efee87ff8a1044d4ec828d5d097830779dc9f7b3 Mon Sep 17 00:00:00 2001 From: Cathal Mullan Date: Fri, 6 Sep 2024 13:32:41 +0100 Subject: [PATCH] Update to Rust v1.81.0. Bump dependencies. --- Cargo.lock | 40 +++++++++---------- Cargo.toml | 18 ++++----- README.md | 32 +++++++-------- benches/matchit_criterion.rs | 2 +- benches/matchit_divan.rs | 2 +- flake.lock | 12 +++--- flake.nix | 11 ++--- nix/pkgs/cargo-codspeed/default.nix | 12 +++--- nix/pkgs/cargo-insta/default.nix | 12 +++--- .../default.nix | 4 +- tests/matchit_delete.rs | 2 +- tests/matchit_matches.rs | 2 +- 12 files changed, 76 insertions(+), 73 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d63aac35..61c4bceb 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -180,18 +180,18 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.16" +version = "4.5.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019" +checksum = "3e5a21b8495e732f1b3c364c9949b201ca7bae518c502c80256c96ad79eaf6ac" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.5.15" +version = "4.5.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" +checksum = "8cf2dd12af7a047ad9d6da2b6b249759a22a7abc0f474c1dae1777afa4b21a73" dependencies = [ "anstyle", "clap_lex", @@ -206,9 +206,9 @@ checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "codspeed" -version = "2.6.0" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a104ac948e0188b921eb3fcbdd55dcf62e542df4c7ab7e660623f6288302089" +checksum = "b0c6f324a032703f286b0fbbdb390971f914b41f3410e1615c59730e4b24ebc2" dependencies = [ "colored", "libc", @@ -217,9 +217,9 @@ dependencies = [ [[package]] name = "codspeed-criterion-compat" -version = "2.6.0" +version = "2.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "722c36bdc62d9436d027256ce2627af81ac7a596dfc7d13d849d0d212448d7fe" +checksum = "0ae52f6f2545ffcd2ac1308f34043eb6ab81e4c741af419b348b2325574f48ee" dependencies = [ "codspeed", "colored", @@ -256,9 +256,9 @@ dependencies = [ [[package]] name = "cpufeatures" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" +checksum = "608697df725056feaccfa42cffdaeeec3fccc4ffc38358ecd19b243e716a78e0" dependencies = [ "libc", ] @@ -342,9 +342,9 @@ dependencies = [ [[package]] name = "dashmap" -version = "6.0.1" +version = "6.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "804c8821570c3f8b70230c2ba75ffa5c0f9a4189b9a432b6656c536712acae28" +checksum = "5041cc499144891f3790297212f32a74fb938e5136a14943f338ef9e0ae276cf" dependencies = [ "cfg-if", "crossbeam-utils", @@ -640,9 +640,9 @@ dependencies = [ [[package]] name = "insta" -version = "1.39.0" +version = "1.40.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "810ae6042d48e2c9e9215043563a58a80b877bc863228a74cf10c49d4620a6f5" +checksum = "6593a41c7a73841868772495db7dc1e8ecab43bb5c0b6da2059246c4b506ab60" dependencies = [ "console", "lazy_static", @@ -1023,9 +1023,9 @@ checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustix" -version = "0.38.35" +version = "0.38.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a85d50532239da68e9addb745ba38ff4612a242c1c7ceea689c4bc7c2f43c36f" +checksum = "3f55e80d50763938498dd5ebb18647174e0c76dc38c5505294bb224624f30f36" dependencies = [ "bitflags", "errno", @@ -1077,9 +1077,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.127" +version = "1.0.128" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" +checksum = "6ff5456707a1de34e7e37f2a6fd3d3f808c318259cbd01ab6377795054b483d8" dependencies = [ "itoa", "memchr", @@ -1260,9 +1260,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.11" +version = "0.7.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +checksum = "61e7c3654c13bcd040d4a03abee2c75b1d14a37b423cf5a813ceae1cc903ec6a" dependencies = [ "bytes", "futures-core", diff --git a/Cargo.toml b/Cargo.toml index fbe56395..9fcb84be 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -76,7 +76,7 @@ workspace = true [dev-dependencies] # Snapshots # NOTE: Keep in sync with `cargo-insta` Nix package. -insta = "1.39.0" +insta = "=1.40.0" # Encoding percent-encoding = "2.3" @@ -85,16 +85,16 @@ percent-encoding = "2.3" divan = "0.1" criterion = { version = "0.5", features = ["html_reports"] } # NOTE: Keep in sync with `cargo-codspeed` Nix package. -codspeed-criterion-compat = "2.6.0" +codspeed-criterion-compat = "=2.7.1" # Routers -actix-router = "0.5.3" -matchit = "0.8.3" -ntex-router = "0.5.3" -path-tree = "0.8.1" -route-recognizer = "0.3.1" -routefinder = "0.5.4" -xitca-router = "0.3.0" +actix-router = "=0.5.3" +matchit = "=0.8.4" +ntex-router = "=0.5.3" +path-tree = "=0.8.1" +route-recognizer = "=0.3.1" +routefinder = "=0.5.4" +xitca-router = "=0.3.0" [[bench]] name = "matchit_criterion" diff --git a/README.md b/README.md index a4428392..56232260 100644 --- a/README.md +++ b/README.md @@ -341,14 +341,14 @@ In a router of 130 routes, benchmark matching 4 paths. | Library | Time | Alloc Count | Alloc Size | Dealloc Count | Dealloc Size | |:-----------------|----------:|------------:|-----------:|--------------:|-------------:| -| matchit | 452.82 ns | 4 | 416 B | 4 | 448 B | -| wayfind | 494.10 ns | 7 | 649 B | 7 | 649 B | -| xitca-router | 563.31 ns | 7 | 800 B | 7 | 832 B | -| path-tree | 576.16 ns | 4 | 416 B | 4 | 448 B | -| ntex-router | 1.8631 µs | 18 | 1.248 KB | 18 | 1.28 KB | -| route-recognizer | 4.5737 µs | 160 | 8.515 KB | 160 | 8.547 KB | -| routefinder | 6.4739 µs | 67 | 5.024 KB | 67 | 5.056 KB | -| actix-router | 21.096 µs | 214 | 13.93 KB | 214 | 13.96 KB | +| matchit | 462.33 ns | 4 | 416 B | 4 | 448 B | +| wayfind | 483.07 ns | 7 | 649 B | 7 | 649 B | +| xitca-router | 562.71 ns | 7 | 800 B | 7 | 832 B | +| path-tree | 572.69 ns | 4 | 416 B | 4 | 448 B | +| ntex-router | 1.7347 µs | 18 | 1.248 KB | 18 | 1.28 KB | +| route-recognizer | 4.6183 µs | 160 | 8.515 KB | 160 | 8.547 KB | +| routefinder | 6.5185 µs | 67 | 5.024 KB | 67 | 5.056 KB | +| actix-router | 21.268 µs | 214 | 13.93 KB | 214 | 13.96 KB | #### `path-tree` inspired benches @@ -356,14 +356,14 @@ In a router of 320 routes, benchmark matching 80 paths. | Library | Time | Alloc Count | Alloc Size | Dealloc Count | Dealloc Size | |:-----------------|----------:|------------:|-----------:|--------------:|-------------:| -| wayfind | 7.1797 µs | 117 | 9.991 KB | 117 | 9.991 KB | -| matchit | 8.9181 µs | 140 | 17.81 KB | 140 | 17.83 KB | -| path-tree | 9.5520 µs | 59 | 7.447 KB | 59 | 7.47 KB | -| xitca-router | 10.901 µs | 209 | 25.51 KB | 209 | 25.53 KB | -| ntex-router | 30.615 µs | 201 | 19.54 KB | 201 | 19.56 KB | -| route-recognizer | 91.274 µs | 2872 | 191.8 KB | 2872 | 205 KB | -| routefinder | 98.439 µs | 525 | 48.4 KB | 525 | 48.43 KB | -| actix-router | 177.68 µs | 2201 | 128.8 KB | 2201 | 128.8 KB | +| wayfind | 7.0411 µs | 117 | 9.991 KB | 117 | 9.991 KB | +| matchit | 8.8426 µs | 140 | 17.81 KB | 140 | 17.83 KB | +| path-tree | 9.2876 µs | 59 | 7.447 KB | 59 | 7.47 KB | +| xitca-router | 10.888 µs | 209 | 25.51 KB | 209 | 25.53 KB | +| ntex-router | 30.283 µs | 201 | 19.54 KB | 201 | 19.56 KB | +| routefinder | 99.873 µs | 525 | 48.4 KB | 525 | 48.43 KB | +| route-recognizer | 107.16 µs | 2872 | 191.8 KB | 2872 | 205 KB | +| actix-router | 192.44 µs | 2201 | 128.8 KB | 2201 | 128.8 KB | ## License diff --git a/benches/matchit_criterion.rs b/benches/matchit_criterion.rs index 1fd12651..3c9b5dbe 100644 --- a/benches/matchit_criterion.rs +++ b/benches/matchit_criterion.rs @@ -1,7 +1,7 @@ #![allow(clippy::too_many_lines)] //! Benches sourced from `matchit` (MIT AND BSD-3-Clause) -//! +//! use codspeed_criterion_compat::{criterion_group, criterion_main, Criterion}; use matchit_routes::paths; diff --git a/benches/matchit_divan.rs b/benches/matchit_divan.rs index 0ad43c59..09217b82 100644 --- a/benches/matchit_divan.rs +++ b/benches/matchit_divan.rs @@ -1,7 +1,7 @@ #![allow(clippy::too_many_lines)] //! Benches sourced from `matchit` (MIT AND BSD-3-Clause) -//! +//! use divan::AllocProfiler; use matchit_routes::paths; diff --git a/flake.lock b/flake.lock index 35b39eaa..4335ba10 100644 --- a/flake.lock +++ b/flake.lock @@ -20,11 +20,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1725194671, - "narHash": "sha256-tLGCFEFTB5TaOKkpfw3iYT9dnk4awTP/q4w+ROpMfuw=", + "lastModified": 1725534445, + "narHash": "sha256-Yd0FK9SkWy+ZPuNqUgmVPXokxDgMJoGuNpMEtkfcf84=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "b833ff01a0d694b910daca6e2ff4a3f26dee478c", + "rev": "9bb1e7571aadf31ddb4af77fc64b2d59580f9a39", "type": "github" }, "original": { @@ -48,11 +48,11 @@ ] }, "locked": { - "lastModified": 1725416653, - "narHash": "sha256-iNBv7ILlZI6ubhW0ExYy8YgiLKUerudxY7n8R5UQK2E=", + "lastModified": 1725589472, + "narHash": "sha256-+OB00N6Yql/ZRQQkQ0PNnxfW2tH89DHnv29hBS7tXMM=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "e5d3f9c2f24d852cddc79716daf0f65ce8468b28", + "rev": "2b00881d2ff72174cffdc007238cb6bedd6e1d8e", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index db49fcc7..cb5caf4b 100644 --- a/flake.nix +++ b/flake.nix @@ -69,7 +69,7 @@ buildInputs = with pkgs; [ # Rust - (rust-bin.stable."1.80.1".minimal.override { + (rust-bin.stable."1.81.0".minimal.override { extensions = [ "clippy" "rust-analyzer" @@ -80,6 +80,7 @@ }) sccache cargo-insta + cargo-outdated cargo-watch # Benchmarking @@ -106,7 +107,7 @@ CARGO_INCREMENTAL = "0"; buildInputs = with pkgs; [ - (rust-bin.stable."1.80.1".minimal) + (rust-bin.stable."1.81.0".minimal) sccache cargo-codspeed ]; @@ -120,7 +121,7 @@ CARGO_INCREMENTAL = "0"; buildInputs = with pkgs; [ - (rust-bin.stable."1.80.1".minimal.override { + (rust-bin.stable."1.81.0".minimal.override { extensions = [ "clippy" "rustfmt" @@ -152,7 +153,7 @@ CARGO_INCREMENTAL = "0"; buildInputs = with pkgs; [ - (rust-bin.stable."1.80.1".minimal) + (rust-bin.stable."1.81.0".minimal) sccache ]; }; @@ -204,7 +205,7 @@ OCI_HIDE_SKIPPED_WORKFLOWS = 1; buildInputs = with pkgs; [ - (rust-bin.stable."1.80.1".minimal) + (rust-bin.stable."1.81.0".minimal) sccache oci-distribution-spec-conformance ]; diff --git a/nix/pkgs/cargo-codspeed/default.nix b/nix/pkgs/cargo-codspeed/default.nix index 6b270d07..1f4f4738 100644 --- a/nix/pkgs/cargo-codspeed/default.nix +++ b/nix/pkgs/cargo-codspeed/default.nix @@ -11,14 +11,14 @@ rustPlatform.buildRustPackage rec { pname = "cargo-codspeed"; # NOTE: Keep in sync with `codspeed-criterion-compat` Rust package. - version = "2.6.0"; + version = "2.7.1"; src = fetchCrate { inherit pname version; - hash = "sha256-e4cDZ+sbylS3gaJpl6FLYPUVedBeAOGqtxDw8YbU9U8="; + hash = "sha256-crucisC3wCiEX5eXufricyBY/UuueJNDXQoyGY2+RF0="; }; - cargoHash = "sha256-ihkmD48EG1fWJ38AAt4Hy6dpATIgnEb6kApDfsTKxwA="; + cargoHash = "sha256-47aJR4ZXax39fjhSu/0eVOtnCmmGw+S/8ea/I7/RAg0="; nativeBuildInputs = [ pkg-config ]; buildInputs = @@ -31,14 +31,14 @@ rustPlatform.buildRustPackage rec { doCheck = false; meta = with lib; { - description = "A cargo subcommand for running CodSpeed on your project."; - mainProgram = "cargo-codspeed"; homepage = "https://github.com/CodSpeedHQ/codspeed-rust"; - changelog = "https://github.com/CodSpeedHQ/codspeed-rust/releases/tag/v${version}"; + description = "A cargo subcommand for running CodSpeed on your project."; + changelog = "https://github.com/CodSpeedHQ/codspeed-rust/releases"; license = [ licenses.mit licenses.asl20 ]; platforms = platforms.all; + mainProgram = "cargo-codspeed"; }; } diff --git a/nix/pkgs/cargo-insta/default.nix b/nix/pkgs/cargo-insta/default.nix index 0a48baed..40134c84 100644 --- a/nix/pkgs/cargo-insta/default.nix +++ b/nix/pkgs/cargo-insta/default.nix @@ -7,21 +7,23 @@ rustPlatform.buildRustPackage rec { pname = "cargo-insta"; # NOTE: Keep in sync with `cargo-insta` Rust package. - version = "1.39.0"; + version = "1.40.0"; src = fetchCrate { inherit pname version; - hash = "sha256-LUgiTIVWjxPTCQ1gZq5zL2UMxnEfC09w9xudn/9AUwM="; + hash = "sha256-rdfFriv3ghjqoPvRD7+TcdHehHE8ZGW4n0UT38+rRXc="; }; - cargoHash = "sha256-FH1d8sub8oqUnEr7oO6vofdLoL6KIHgOuF3Exar75t0="; + cargoHash = "sha256-ogIPR1dronvBMyEfSkXfOsrtXYpeWGZ5a/j9ks6m4sQ="; + + doCheck = false; meta = with lib; { - description = "A Cargo subcommand for snapshot testing."; - mainProgram = "cargo-insta"; homepage = "https://github.com/mitsuhiko/insta"; + description = "A Cargo subcommand for snapshot testing."; changelog = "https://github.com/mitsuhiko/insta/releases"; license = licenses.asl20; platforms = platforms.all; + mainProgram = "cargo-insta"; }; } diff --git a/nix/pkgs/oci-distribution-spec-conformance/default.nix b/nix/pkgs/oci-distribution-spec-conformance/default.nix index a96a2bb4..c2ac12ae 100644 --- a/nix/pkgs/oci-distribution-spec-conformance/default.nix +++ b/nix/pkgs/oci-distribution-spec-conformance/default.nix @@ -28,11 +28,11 @@ buildGoModule rec { doCheck = false; meta = with lib; { - description = " OCI Distribution Specification Conformance Tests"; - mainProgram = "oci-distribution-spec-conformance"; homepage = "https://opencontainers.org"; + description = " OCI Distribution Specification Conformance Tests"; changelog = "https://github.com/opencontainers/distribution-spec/releases"; license = licenses.asl20; platforms = platforms.all; + mainProgram = "oci-distribution-spec-conformance"; }; } diff --git a/tests/matchit_delete.rs b/tests/matchit_delete.rs index b9361271..96a1aa7d 100644 --- a/tests/matchit_delete.rs +++ b/tests/matchit_delete.rs @@ -1,5 +1,5 @@ //! Tests sourced from `matchit` (MIT AND BSD-3-Clause) -//! +//! #![allow(clippy::too_many_lines, clippy::cognitive_complexity)] diff --git a/tests/matchit_matches.rs b/tests/matchit_matches.rs index d21897c6..2a5b191a 100644 --- a/tests/matchit_matches.rs +++ b/tests/matchit_matches.rs @@ -1,5 +1,5 @@ //! Tests sourced from `matchit` (MIT AND BSD-3-Clause) -//! +//! #![allow(clippy::too_many_lines)]