Repository: CosmWasm/cosmwasm (rust)

Issue:
Replace `serde-json-wasm` with `serde_json`
`serde-json-wasm` was originally created to remove floating point instructions from smart contracts to allow for JSON de-/serialization inside of contracts.

Since we fixed that with v1.5, there is no real need for `serde-json-wasm` anymore. It pretty much only adds a maintenance burden. Therefore we agreed to replace `serde-json-wasm` inside the CosmWasm project with `serde_json`.

Pull request description:
Remove serde-json-wasm dependency
Closes #2195

Patch:
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 1c267ae87..336c8c38e 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -604,7 +604,7 @@ jobs:
           keys:
             - cargocache-v2-contract_burner-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -632,7 +632,7 @@ jobs:
           keys:
             - cargocache-v2-contract_replier-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -829,7 +829,7 @@ jobs:
           keys:
             - cargocache-v2-contract_ibc_reflect_send-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -857,7 +857,7 @@ jobs:
           keys:
             - cargocache-v2-contract_floaty-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -885,7 +885,7 @@ jobs:
           keys:
             - cargocache-v2-contract_nested_contracts-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -913,7 +913,7 @@ jobs:
           keys:
             - cargocache-v2-contract_queue-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -969,7 +969,7 @@ jobs:
           keys:
             - cargocache-v2-contract_staking-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
@@ -997,7 +997,7 @@ jobs:
           keys:
             - cargocache-v2-contract_virus-rust:1.81-{{ checksum "Cargo.lock" }}
       - check_contract:
-          min_version: "1.4"
+          min_version: "1.5"
       - save_cache:
           paths:
             - /usr/local/cargo/registry
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 305bace2c..6b6de2c5b 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -58,6 +58,8 @@ and this project adheres to
 - cosmwasm-std: Remove previously deprecated `cosmwast_std::testing::mock_info`.
   Use `cosmwasm_std::testing::message_info` instead. ([#2393])
 - cosmwasm-std: Remove abort feature. ([#2141])
+- cosmwasm-std: Replace dependency `serde-json-wasm` with `serde_json`.
+  ([#2195])
 
 ## Fixed
 
@@ -68,6 +70,7 @@ and this project adheres to
 [#2141]: https://github.com/CosmWasm/cosmwasm/issues/2141
 [#2155]: https://github.com/CosmWasm/cosmwasm/issues/2155
 [#2156]: https://github.com/CosmWasm/cosmwasm/issues/2156
+[#2195]: https://github.com/CosmWasm/cosmwasm/issues/2195
 [#2201]: https://github.com/CosmWasm/cosmwasm/issues/2201
 [#2237]: https://github.com/CosmWasm/cosmwasm/issues/2237
 [#2262]: https://github.com/CosmWasm/cosmwasm/issues/2262
diff --git a/Cargo.lock b/Cargo.lock
index 763ad4215..ceca13e9a 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -778,7 +778,6 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
  "serde_json",
  "sha2",
  "static_assertions",
@@ -2806,15 +2805,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2850,9 +2840,9 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.138"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
  "memchr",
diff --git a/contracts/burner/Cargo.lock b/contracts/burner/Cargo.lock
index 411493f0a..d72f786ea 100644
--- a/contracts/burner/Cargo.lock
+++ b/contracts/burner/Cargo.lock
@@ -540,7 +540,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2194,15 +2194,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2238,11 +2229,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/crypto-verify/Cargo.lock b/contracts/crypto-verify/Cargo.lock
index c9735e55a..baf0d3b8d 100644
--- a/contracts/crypto-verify/Cargo.lock
+++ b/contracts/crypto-verify/Cargo.lock
@@ -535,7 +535,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2251,15 +2251,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2295,11 +2286,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/cyberpunk/Cargo.lock b/contracts/cyberpunk/Cargo.lock
index ea1426ad7..24cab3358 100644
--- a/contracts/cyberpunk/Cargo.lock
+++ b/contracts/cyberpunk/Cargo.lock
@@ -558,7 +558,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2241,15 +2241,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2285,11 +2276,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/empty/Cargo.lock b/contracts/empty/Cargo.lock
index c4a9d2f46..05c2b9dc0 100644
--- a/contracts/empty/Cargo.lock
+++ b/contracts/empty/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2193,15 +2193,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2237,11 +2228,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/floaty/Cargo.lock b/contracts/floaty/Cargo.lock
index 3ccbfa44e..9494d1227 100644
--- a/contracts/floaty/Cargo.lock
+++ b/contracts/floaty/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2195,15 +2195,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2239,11 +2230,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/hackatom/Cargo.lock b/contracts/hackatom/Cargo.lock
index 248a11c60..0e30350e3 100644
--- a/contracts/hackatom/Cargo.lock
+++ b/contracts/hackatom/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2196,15 +2196,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2240,11 +2231,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/ibc-callbacks/Cargo.lock b/contracts/ibc-callbacks/Cargo.lock
index 2c0172d50..5303b28f9 100644
--- a/contracts/ibc-callbacks/Cargo.lock
+++ b/contracts/ibc-callbacks/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2179,15 +2179,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2223,11 +2214,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/ibc-reflect-send/Cargo.lock b/contracts/ibc-reflect-send/Cargo.lock
index ce6aa54e7..63debb6c3 100644
--- a/contracts/ibc-reflect-send/Cargo.lock
+++ b/contracts/ibc-reflect-send/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2194,15 +2194,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2238,11 +2229,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/ibc-reflect/Cargo.lock b/contracts/ibc-reflect/Cargo.lock
index ec01ce0fd..c467079b2 100644
--- a/contracts/ibc-reflect/Cargo.lock
+++ b/contracts/ibc-reflect/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2194,15 +2194,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2238,11 +2229,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/ibc-reflect/src/contract.rs b/contracts/ibc-reflect/src/contract.rs
index 60d4b85db..db25bff7f 100644
--- a/contracts/ibc-reflect/src/contract.rs
+++ b/contracts/ibc-reflect/src/contract.rs
@@ -638,7 +638,7 @@ mod tests {
         // acknowledgement is an error
         let ack: AcknowledgementMsg<DispatchResponse> =
             from_json(res.acknowledgement.unwrap()).unwrap();
-        assert_eq!(ack.unwrap_err(), "invalid packet: Error parsing into type ibc_reflect::msg::PacketMsg: unknown variant `reflect_code_id`, expected one of `dispatch`, `who_am_i`, `balances`, `panic`, `return_err`, `return_msgs`, `no_ack`");
+        assert_eq!(ack.unwrap_err(), "invalid packet: Error parsing into type ibc_reflect::msg::PacketMsg: unknown variant `reflect_code_id`, expected one of `dispatch`, `who_am_i`, `balances`, `panic`, `return_err`, `return_msgs`, `no_ack` at line 1 column 18");
     }
 
     #[test]
diff --git a/contracts/ibc2/Cargo.lock b/contracts/ibc2/Cargo.lock
index d8bf00be6..45452211f 100644
--- a/contracts/ibc2/Cargo.lock
+++ b/contracts/ibc2/Cargo.lock
@@ -270,7 +270,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror",
@@ -855,15 +855,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde_derive"
 version = "1.0.217"
@@ -888,9 +879,9 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.138"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
  "memchr",
diff --git a/contracts/queue/Cargo.lock b/contracts/queue/Cargo.lock
index 72b7a73ed..24fdbec23 100644
--- a/contracts/queue/Cargo.lock
+++ b/contracts/queue/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2194,15 +2194,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2238,11 +2229,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/reflect/Cargo.lock b/contracts/reflect/Cargo.lock
index 5af9d0204..1109c9758 100644
--- a/contracts/reflect/Cargo.lock
+++ b/contracts/reflect/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2195,15 +2195,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2239,11 +2230,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/replier/Cargo.lock b/contracts/replier/Cargo.lock
index 4a3135aa3..88b2335e9 100644
--- a/contracts/replier/Cargo.lock
+++ b/contracts/replier/Cargo.lock
@@ -270,7 +270,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror",
@@ -602,6 +602,12 @@ version = "0.2.155"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c"
 
+[[package]]
+name = "memchr"
+version = "2.7.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3"
+
 [[package]]
 name = "num-bigint"
 version = "0.4.5"
@@ -845,15 +851,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde_derive"
 version = "1.0.203"
@@ -878,11 +875,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/staking/Cargo.lock b/contracts/staking/Cargo.lock
index eba3fb1b6..ea128bb56 100644
--- a/contracts/staking/Cargo.lock
+++ b/contracts/staking/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2183,15 +2183,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2227,11 +2218,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/contracts/virus/Cargo.lock b/contracts/virus/Cargo.lock
index 0732a3298..58da70e4e 100644
--- a/contracts/virus/Cargo.lock
+++ b/contracts/virus/Cargo.lock
@@ -529,7 +529,7 @@ dependencies = [
  "rmp-serde",
  "schemars",
  "serde",
- "serde-json-wasm",
+ "serde_json",
  "sha2",
  "static_assertions",
  "thiserror 1.0.61",
@@ -2183,15 +2183,6 @@ dependencies = [
  "serde_derive",
 ]
 
-[[package]]
-name = "serde-json-wasm"
-version = "1.0.1"
-source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f05da0d153dd4595bdffd5099dc0e9ce425b205ee648eb93437ff7302af8c9a5"
-dependencies = [
- "serde",
-]
-
 [[package]]
 name = "serde-wasm-bindgen"
 version = "0.4.5"
@@ -2227,11 +2218,12 @@ dependencies = [
 
 [[package]]
 name = "serde_json"
-version = "1.0.117"
+version = "1.0.140"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3"
+checksum = "20068b6e96dc6c9bd23e01df8827e6c7e1f2fddd43c21810382803c136b99373"
 dependencies = [
  "itoa",
+ "memchr",
  "ryu",
  "serde",
 ]
diff --git a/packages/crypto/Cargo.toml b/packages/crypto/Cargo.toml
index 87cae0dd1..f44527c45 100644
--- a/packages/crypto/Cargo.toml
+++ b/packages/crypto/Cargo.toml
@@ -40,7 +40,7 @@ serde = { version = "1.0.103", default-features = false, features = [
     "alloc",
     "derive",
 ] }
-serde_json = "1.0.40"
+serde_json = "1.0.140"
 sha2 = "0.10"
 sha3 = "0.10"
 hex = { version = "0.4", features = ["serde"] }
diff --git a/packages/schema/Cargo.toml b/packages/schema/Cargo.toml
index 54844b3c4..c7cc13a0a 100644
--- a/packages/schema/Cargo.toml
+++ b/packages/schema/Cargo.toml
@@ -14,7 +14,7 @@ license = "Apache-2.0"
 cosmwasm-schema-derive = { version = "=2.2.0-rc.1", path = "../schema-derive" }
 schemars = { workspace = true }
 serde = { workspace = true }
-serde_json = "1.0.40"
+serde_json = "1.0.140"
 thiserror = "1.0.26"
 
 [dev-dependencies]
diff --git a/packages/std/Cargo.toml b/packages/std/Cargo.toml
index f793d8c95..242956653 100644
--- a/packages/std/Cargo.toml
+++ b/packages/std/Cargo.toml
@@ -65,9 +65,7 @@ hex = "0.4"
 schemars = { workspace = true }
 sha2 = "0.10.3"
 serde = { workspace = true, features = ["std"] }
-serde-json-wasm = { version = "1.0.1", default-features = false, features = [
-    "std",
-] }
+serde_json = "1.0.140"
 static_assertions = "1.1.0"
 thiserror = "1.0.26"
 rmp-serde = "1.3.0"
@@ -93,4 +91,3 @@ proptest = { version = "1.5.0", default-features = false, features = [
     "attr-macro",
     "std",
 ] }
-serde_json = "1.0.81"
diff --git a/packages/std/src/ibc.rs b/packages/std/src/ibc.rs
index 5612cf5eb..58505db62 100644
--- a/packages/std/src/ibc.rs
+++ b/packages/std/src/ibc.rs
@@ -896,7 +896,7 @@ impl<T> IbcReceiveResponse<T> {
 #[cfg(test)]
 mod tests {
     use super::*;
-    use serde_json_wasm::to_string;
+    use crate::to_json_string;
 
     #[test]
     // added this to check json format for go compat, as I was unsure how some messages are snake encoded
@@ -908,7 +908,7 @@ mod tests {
             timeout: IbcTimeout::with_timestamp(Timestamp::from_nanos(1234567890)),
             memo: None,
         };
-        let encoded = to_string(&msg).unwrap();
+        let encoded = to_json_string(&msg).unwrap();
         let expected = r#"{"transfer":{"channel_id":"channel-123","to_address":"my-special-addr","amount":{"denom":"uatom","amount":"12345678"},"timeout":{"block":null,"timestamp":"1234567890"},"memo":null}}"#;
         assert_eq!(encoded.as_str(), expected);
     }
@@ -917,14 +917,14 @@ mod tests {
     fn ibc_timeout_serialize() {
         let timestamp = IbcTimeout::with_timestamp(Timestamp::from_nanos(684816844));
         let expected = r#"{"block":null,"timestamp":"684816844"}"#;
-        assert_eq!(to_string(&timestamp).unwrap(), expected);
+        assert_eq!(to_json_string(&timestamp).unwrap(), expected);
 
         let block = IbcTimeout::with_block(IbcTimeoutBlock {
             revision: 12,
             height: 129,
         });
         let expected = r#"{"block":{"revision":12,"height":129},"timestamp":null}"#;
-        assert_eq!(to_string(&block).unwrap(), expected);
+        assert_eq!(to_json_string(&block).unwrap(), expected);
 
         let both = IbcTimeout::with_both(
             IbcTimeoutBlock {
@@ -934,7 +934,7 @@ mod tests {
             Timestamp::from_nanos(684816844),
         );
         let expected = r#"{"block":{"revision":12,"height":129},"timestamp":"684816844"}"#;
-        assert_eq!(to_string(&both).unwrap(), expected);
+        assert_eq!(to_json_string(&both).unwrap(), expected);
     }
 
     #[test]
@@ -998,7 +998,7 @@ mod tests {
             ),
         };
         let expected = r#"{"data":"Zm9v","src":{"port_id":"their-port","channel_id":"channel-1234"},"dest":{"port_id":"our-port","channel_id":"chan33"},"sequence":27,"timeout":{"block":{"revision":1,"height":12345678},"timestamp":"4611686018427387904"}}"#;
-        assert_eq!(to_string(&packet).unwrap(), expected);
+        assert_eq!(to_json_string(&packet).unwrap(), expected);
 
         let no_timestamp = IbcPacket {
             data: b"foo".into(),
@@ -1017,6 +1017,6 @@ mod tests {
             }),
         };
         let expected = r#"{"data":"Zm9v","src":{"port_id":"their-port","channel_id":"channel-1234"},"dest":{"port_id":"our-port","channel_id":"chan33"},"sequence":27,"timeout":{"block":{"revision":1,"height":12345678},"timestamp":null}}"#;
-        assert_eq!(to_string(&no_timestamp).unwrap(), expected);
+        assert_eq!(to_json_string(&no_timestamp).unwrap(), expected);
     }
 }
diff --git a/packages/std/src/serde.rs b/packages/std/src/serde.rs
index 3e412cf16..93cbe17e7 100644
--- a/packages/std/src/serde.rs
+++ b/packages/std/src/serde.rs
@@ -13,8 +13,7 @@ use crate::{StdError, StdResult};
 ///
 /// Errors if the input is not valid JSON or cannot be deserialized to the given type.
 pub fn from_json<T: DeserializeOwned>(value: impl AsRef<[u8]>) -> StdResult<T> {
-    serde_json_wasm::from_slice(value.as_ref())
-        .map_err(|e| StdError::parse_err(type_name::<T>(), e))
+    serde_json::from_slice(value.as_ref()).map_err(|e| StdError::parse_err(type_name::<T>(), e))
 }
 
 /// Serializes the given data structure as a JSON byte vector.
@@ -22,7 +21,7 @@ pub fn to_json_vec<T>(data: &T) -> StdResult<Vec<u8>>
 where
     T: Serialize + ?Sized,
 {
-    serde_json_wasm::to_vec(data).map_err(|e| StdError::serialize_err(type_name::<T>(), e))
+    serde_json::to_vec(data).map_err(|e| StdError::serialize_err(type_name::<T>(), e))
 }
 
 /// Serializes the given data structure as a JSON string.
@@ -30,7 +29,7 @@ pub fn to_json_string<T>(data: &T) -> StdResult<String>
 where
     T: Serialize + ?Sized,
 {
-    serde_json_wasm::to_string(data).map_err(|e| StdError::serialize_err(type_name::<T>(), e))
+    serde_json::to_string(data).map_err(|e| StdError::serialize_err(type_name::<T>(), e))
 }
 
 /// Serializes the given data structure as JSON bytes.
diff --git a/packages/vm/Cargo.toml b/packages/vm/Cargo.toml
index aa3296190..ef7ab2be4 100644
--- a/packages/vm/Cargo.toml
+++ b/packages/vm/Cargo.toml
@@ -56,7 +56,7 @@ derive_more = { version = "=1.0.0-beta.6", default-features = false, features =
 hex = "0.4"
 rand_core = { version = "0.6", features = ["getrandom"] }
 serde = { workspace = true }
-serde_json = "1.0.40"
+serde_json = "1.0.140"
 sha2 = "0.10.3"
 thiserror = "1.0.26"
 # We pin wasmer to a specific version because the layout of cached modules can change between patch versions.


Test patch:
diff --git a/contracts/hackatom/tests/integration.rs b/contracts/hackatom/tests/integration.rs
index e6abc0272..a1298c9e1 100644
--- a/contracts/hackatom/tests/integration.rs
+++ b/contracts/hackatom/tests/integration.rs
@@ -435,9 +435,7 @@ fn execute_allocate_large_memory() {
     // Gas consumption is relatively small
     // Note: the exact gas usage depends on the Rust version used to compile Wasm,
     // which we only fix when using rust-optimizer, not integration tests.
-    let expected = 12162675; // +/- 20%
-    assert!(gas_used > expected * 80 / 100, "Gas used: {gas_used}");
-    assert!(gas_used < expected * 120 / 100, "Gas used: {gas_used}");
+    assert_approx_eq!(gas_used, 8623090, "0.2");
     let used = deps.memory_pages();
     assert_eq!(used, pages_before, "Memory used: {used} pages");
 }
diff --git a/contracts/ibc-reflect/tests/integration.rs b/contracts/ibc-reflect/tests/integration.rs
index ec43cda3c..3c845acce 100644
--- a/contracts/ibc-reflect/tests/integration.rs
+++ b/contracts/ibc-reflect/tests/integration.rs
@@ -298,5 +298,5 @@ fn handle_dispatch_packet() {
     // acknowledgement is an error
     let ack: AcknowledgementMsg<DispatchResponse> =
         from_slice(&res.acknowledgement.unwrap(), DESERIALIZATION_LIMIT).unwrap();
-    assert_eq!(ack.unwrap_err(), "invalid packet: Error parsing into type ibc_reflect::msg::PacketMsg: unknown variant `reflect_code_id`, expected one of `dispatch`, `who_am_i`, `balances`, `panic`, `return_err`, `return_msgs`, `no_ack`");
+    assert_eq!(ack.unwrap_err(), "invalid packet: Error parsing into type ibc_reflect::msg::PacketMsg: unknown variant `reflect_code_id`, expected one of `dispatch`, `who_am_i`, `balances`, `panic`, `return_err`, `return_msgs`, `no_ack` at line 1 column 18");
 }
diff --git a/packages/std/src/testing/mock.rs b/packages/std/src/testing/mock.rs
index f4797a599..e9500956b 100644
--- a/packages/std/src/testing/mock.rs
+++ b/packages/std/src/testing/mock.rs
@@ -2637,7 +2637,7 @@ mod tests {
         });
         match result {
             SystemResult::Ok(ContractResult::Err(err)) => {
-                assert_eq!(err, "Error parsing into type cosmwasm_std::testing::mock::tests::wasm_querier_works::{{closure}}::MyMsg: Invalid type")
+                assert_eq!(err, "Error parsing into type cosmwasm_std::testing::mock::tests::wasm_querier_works::{{closure}}::MyMsg: expected value at line 1 column 1")
             }
             res => panic!("Unexpected result: {res:?}"),
         }