diff --git a/rust-runtime/Cargo.lock b/rust-runtime/Cargo.lock index 128c841667d..d31ec1652bb 100644 --- a/rust-runtime/Cargo.lock +++ b/rust-runtime/Cargo.lock @@ -55,11 +55,10 @@ checksum = "dde20b3d026af13f561bdd0f15edf01fc734f0dafcedbaf42bba506a9517f223" [[package]] name = "assert-json-diff" -version = "1.1.0" +version = "2.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4259cbe96513d2f1073027a259fc2ca917feb3026a5a8d984e3628e490255cc0" +checksum = "47e4f2b81832e72834d7518d8487a0396a28cc408186a2e8854c0f98011faf12" dependencies = [ - "extend", "serde", "serde_json", ] @@ -424,7 +423,7 @@ version = "0.60.3" [[package]] name = "aws-smithy-http-client" -version = "1.0.2" +version = "1.0.3" dependencies = [ "aws-smithy-async", "aws-smithy-protocol-test", @@ -482,7 +481,7 @@ dependencies = [ "pretty_assertions", "regex", "serde_urlencoded", - "thiserror", + "thiserror 2.0.12", "tokio", "tower 0.4.13", "tower-http", @@ -516,7 +515,7 @@ dependencies = [ "rustls-pemfile 1.0.4", "signal-hook", "socket2", - "thiserror", + "thiserror 2.0.12", "tls-listener", "tokio", "tokio-rustls 0.24.1", @@ -601,7 +600,7 @@ dependencies = [ "regex-lite", "roxmltree", "serde_json", - "thiserror", + "thiserror 2.0.12", ] [[package]] @@ -1332,18 +1331,6 @@ dependencies = [ "pin-project-lite", ] -[[package]] -name = "extend" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f47da3a72ec598d9c8937a7ebca8962a5c7a1f28444e38c2b33c771ba3f55f05" -dependencies = [ - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - [[package]] name = "fastrand" version = "2.3.0" @@ -2384,7 +2371,7 @@ dependencies = [ "js-sys", "once_cell", "pin-project-lite", - "thiserror", + "thiserror 1.0.69", ] [[package]] @@ -2404,7 +2391,7 @@ dependencies = [ "percent-encoding", "rand 0.8.5", "serde_json", - "thiserror", + "thiserror 1.0.69", "tokio", "tokio-stream", ] @@ -2601,30 +2588,6 @@ dependencies = [ "syn 2.0.101", ] -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - [[package]] name = "proc-macro2" version = "1.0.95" @@ -3541,7 +3504,16 @@ version = "1.0.69" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" dependencies = [ - "thiserror-impl", + "thiserror-impl 1.0.69", +] + +[[package]] +name = "thiserror" +version = "2.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567b8a2dae586314f7be2a752ec7474332959c6460e02bde30d702a66d488708" +dependencies = [ + "thiserror-impl 2.0.12", ] [[package]] @@ -3555,6 +3527,17 @@ dependencies = [ "syn 2.0.101", ] +[[package]] +name = "thiserror-impl" +version = "2.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f7cf42b4507d8ea322120659672cf1b9dbb93f8f2d4ecfd6e51350ff5b17a1d" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.101", +] + [[package]] name = "thread_local" version = "1.1.8" @@ -3640,7 +3623,7 @@ dependencies = [ "futures-util", "hyper 0.14.32", "pin-project-lite", - "thiserror", + "thiserror 1.0.69", "tokio", "tokio-rustls 0.24.1", ] @@ -3820,7 +3803,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3566e8ce28cc0a3fe42519fc80e6b4c943cc4c8cef275620eb8dac2d3d4e06cf" dependencies = [ "crossbeam-channel", - "thiserror", + "thiserror 1.0.69", "time", "tracing-subscriber", ] diff --git a/rust-runtime/aws-smithy-http-server-python/Cargo.toml b/rust-runtime/aws-smithy-http-server-python/Cargo.toml index 779772dddb4..50f79810dce 100644 --- a/rust-runtime/aws-smithy-http-server-python/Cargo.toml +++ b/rust-runtime/aws-smithy-http-server-python/Cargo.toml @@ -33,7 +33,7 @@ pyo3 = "0.18.2" pyo3-asyncio = { version = "0.18.0", features = ["tokio-runtime"] } signal-hook = { version = "0.3.14", features = ["extended-siginfo"] } socket2 = { version = "0.5.5", features = ["all"] } -thiserror = "1.0.40" +thiserror = "2" tokio = { version = "1.40.0", features = ["full"] } tokio-stream = "0.1.2" tower = { version = "0.4.13", features = ["util"] } diff --git a/rust-runtime/aws-smithy-http-server/Cargo.toml b/rust-runtime/aws-smithy-http-server/Cargo.toml index 62dc33c9977..d300371ec78 100644 --- a/rust-runtime/aws-smithy-http-server/Cargo.toml +++ b/rust-runtime/aws-smithy-http-server/Cargo.toml @@ -35,7 +35,7 @@ nom = "7.1.3" pin-project-lite = "0.2.14" regex = "1.11.1" serde_urlencoded = "0.7" -thiserror = "1.0.40" +thiserror = "2" tokio = { version = "1.40.0", features = ["full"] } tower = { version = "0.4.13", features = ["util", "make"], default-features = false } tower-http = { version = "0.3", features = ["add-extension", "map-response-body"] } diff --git a/rust-runtime/aws-smithy-protocol-test/Cargo.toml b/rust-runtime/aws-smithy-protocol-test/Cargo.toml index 195b7e77562..31ca0460eca 100644 --- a/rust-runtime/aws-smithy-protocol-test/Cargo.toml +++ b/rust-runtime/aws-smithy-protocol-test/Cargo.toml @@ -9,7 +9,7 @@ repository = "https://github.com/smithy-lang/smithy-rs" [dependencies] # Not perfect for our needs, but good for now -assert-json-diff = "1.1" +assert-json-diff = "2" base64-simd = "0.8" cbor-diag = "0.1.12" ciborium = "0.2" @@ -18,7 +18,7 @@ pretty_assertions = "1.3" regex-lite = "0.1.5" roxmltree = "0.14.1" serde_json = "1.0.128" -thiserror = "1.0.40" +thiserror = "2" aws-smithy-runtime-api = { path = "../aws-smithy-runtime-api", features = ["client"] } [package.metadata.docs.rs] diff --git a/rust-runtime/aws-smithy-protocol-test/src/lib.rs b/rust-runtime/aws-smithy-protocol-test/src/lib.rs index 4d5d00029f2..f5cb250448d 100644 --- a/rust-runtime/aws-smithy-protocol-test/src/lib.rs +++ b/rust-runtime/aws-smithy-protocol-test/src/lib.rs @@ -18,7 +18,7 @@ mod xml; use crate::sealed::GetNormalizedHeader; use crate::xml::try_xml_equivalent; -use assert_json_diff::assert_json_eq_no_panic; +use assert_json_diff::assert_json_matches_no_panic; use aws_smithy_runtime_api::client::orchestrator::HttpRequest; use aws_smithy_runtime_api::http::Headers; use http::{HeaderMap, Uri}; @@ -406,7 +406,8 @@ fn try_json_eq(expected: &str, actual: &str) -> Result<(), ProtocolTestFailure> expected: "json".to_owned(), found: e.to_string() + actual, })?; - match assert_json_eq_no_panic(&actual_json, &expected_json) { + let config = assert_json_diff::Config::new(assert_json_diff::CompareMode::Strict); + match assert_json_matches_no_panic(&actual_json, &expected_json, config) { Ok(()) => Ok(()), Err(message) => Err(ProtocolTestFailure::BodyDidNotMatch { comparison: pretty_comparison(expected, actual),