Skip to content

Commit

Permalink
Remove serde feature from rpc-types-any
Browse files Browse the repository at this point in the history
  • Loading branch information
moricho committed Nov 14, 2024
1 parent da79415 commit ea7e1f3
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 11 deletions.
2 changes: 1 addition & 1 deletion crates/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ alloy-eips = { workspace = true, features = ["serde"] }
alloy-json-rpc.workspace = true
alloy-network-primitives.workspace = true
alloy-primitives = { workspace = true, features = ["map"] }
alloy-rpc-types-any = { workspace = true, features = ["serde"] }
alloy-rpc-types-any.workspace = true
alloy-rpc-types-eth = { workspace = true, features = ["std", "serde"] }
alloy-signer.workspace = true
alloy-serde.workspace = true
Expand Down
7 changes: 2 additions & 5 deletions crates/rpc-types-any/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,12 @@ rustdoc-args = ["--cfg", "docsrs"]
workspace = true

[dependencies]
alloy-consensus-any = { workspace = true, optional = true }
alloy-consensus-any = { workspace = true, features = ["serde"] }
alloy-rpc-types-eth.workspace = true
alloy-serde = { workspace = true, optional = true }
alloy-serde.workspace = true

[dev-dependencies]
alloy-primitives.workspace = true

serde.workspace = true
serde_json.workspace = true

[features]
serde = ["dep:alloy-serde", "alloy-consensus-any/serde"]
1 change: 0 additions & 1 deletion crates/rpc-types-any/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]

mod transaction;
#[cfg(feature = "serde")]
pub use transaction::AnyTransactionReceipt;

mod block;
Expand Down
1 change: 0 additions & 1 deletion crates/rpc-types-any/src/transaction/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
mod receipt;
#[cfg(feature = "serde")]
pub use receipt::AnyTransactionReceipt;
3 changes: 0 additions & 3 deletions crates/rpc-types-any/src/transaction/receipt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ use alloy_rpc_types_eth::{Log, TransactionReceipt};

/// Alias for a catch-all receipt type.
#[doc(alias = "AnyTxReceipt")]
#[cfg(feature = "serde")]
pub type AnyTransactionReceipt =
alloy_serde::WithOtherFields<TransactionReceipt<alloy_consensus_any::AnyReceiptEnvelope<Log>>>;

Expand All @@ -12,7 +11,6 @@ mod test {
use alloy_primitives::b256;

#[test]
#[cfg(feature = "serde")]
fn deserialize_tx_receipt_op() {
// OtherFields for Optimism
#[derive(Debug, serde::Deserialize)]
Expand Down Expand Up @@ -88,7 +86,6 @@ mod test {
}

#[test]
#[cfg(feature = "serde")]
fn deserialize_tx_receipt_arb() {
// OtherFields for Arbitrum
#[derive(Debug, serde::Deserialize)]
Expand Down

0 comments on commit ea7e1f3

Please sign in to comment.