Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[wip] feat: provider alloy migration #7106

Merged
merged 71 commits into from
Apr 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
16aebe2
chore: make cast use an alloy provider
Evalir Feb 13, 2024
08a9cca
move initial methods to alloy
Evalir Feb 13, 2024
3de8241
feat(`foundry-common`): NameOrAddress ENS util (#7122)
Evalir Feb 14, 2024
f9d6c99
feat(`cast`): Move non `tx` methods to alloy (#7129)
Evalir Feb 16, 2024
0f98e03
Merge branch 'master' into evalir/cast-provider-mig
Evalir Feb 19, 2024
c983f50
Merge branch 'master' into evalir/cast-provider-mig
klkvr Mar 18, 2024
e482bee
DocumentMut
klkvr Mar 18, 2024
953f915
wip
klkvr Mar 18, 2024
435be40
wip
klkvr Mar 18, 2024
d286ae0
wip: bump alloy
klkvr Mar 18, 2024
04ca105
wip
klkvr Mar 18, 2024
f9fcfd4
wip
klkvr Mar 19, 2024
d1ace73
wip
klkvr Mar 20, 2024
2a723a4
[wip] migrate to alloy providers and signers (#7425)
klkvr Mar 20, 2024
20ce388
fix wallets after alloy bump
klkvr Mar 20, 2024
12fee31
clean up deps
klkvr Mar 21, 2024
7b4e7a5
use serde on consensus types
klkvr Mar 21, 2024
13144ef
update TypedTransaction for anvil
klkvr Mar 22, 2024
3077ad8
make anvil compile
klkvr Mar 22, 2024
2867eac
wip: make script compile
klkvr Mar 22, 2024
dc1df12
fix script
klkvr Mar 22, 2024
9fac722
make forge compile
klkvr Mar 22, 2024
7827988
fix: anvil tests
klkvr Mar 22, 2024
67107c3
bump alloy
klkvr Mar 23, 2024
09ee81f
fix tests
klkvr Mar 23, 2024
1539d37
fix tx builder
klkvr Mar 24, 2024
7889a57
fix cargo.toml
klkvr Mar 24, 2024
b479fa8
fix cargo.toml
klkvr Mar 24, 2024
2d67791
fix script gas price logic
klkvr Mar 25, 2024
323ca27
merge
klkvr Mar 25, 2024
43d19b1
remove ethers from anvil
klkvr Mar 25, 2024
f0a6243
clippy
klkvr Mar 25, 2024
203712e
rm all_derives
klkvr Mar 25, 2024
25276b8
deps
klkvr Mar 27, 2024
a61f4a6
fmt
klkvr Mar 27, 2024
e6e3b57
fix tests
klkvr Mar 27, 2024
aa8fb46
Merge branch 'master' into evalir/cast-provider-mig
klkvr Mar 27, 2024
24f746a
configure clippy
klkvr Mar 27, 2024
5d72ea9
clippy
klkvr Mar 27, 2024
1b762d8
add feature
klkvr Mar 27, 2024
852fa11
fix cargo deny
klkvr Mar 27, 2024
c8781e5
fix persist
klkvr Mar 27, 2024
9760679
fix doctests
klkvr Mar 27, 2024
f93a140
fmt
klkvr Mar 27, 2024
7740eb1
fix clap
klkvr Mar 28, 2024
2800a41
review fixes
klkvr Mar 28, 2024
dc1ce6e
Merge branch 'master' into evalir/cast-provider-mig
klkvr Mar 28, 2024
3ccde5b
fmt
klkvr Mar 28, 2024
3d4373d
bump alloy
klkvr Apr 4, 2024
5204f61
Update cargo.toml
klkvr Apr 4, 2024
c2b404b
Merge branch 'master' into evalir/cast-provider-mig
klkvr Apr 4, 2024
879153a
fmt
klkvr Apr 4, 2024
0431bb3
fixes
klkvr Apr 4, 2024
472d4ff
ethers clean-up
klkvr Apr 5, 2024
ecfcca0
fix(fmt): fix indent closing parenthesis enclosed in { } (#7557)
grandizzy Apr 4, 2024
5efa20e
feat(test): only compile files needed for tests (#7334)
klkvr Apr 4, 2024
398ff1f
fix: do not flood dictionary with data dependent on fuzz inputs (#7552)
klkvr Apr 4, 2024
ec8f6de
Feat: Index cheatcode for Strings (#7539)
kamuik16 Apr 4, 2024
1b846d9
chore: reduce logs in tests (#7566)
DaniPopes Apr 5, 2024
03d900a
fix(script): decode custom error in script fail message (#7563)
grandizzy Apr 5, 2024
3ebf3ab
clippy
klkvr Apr 6, 2024
c734de4
bump alloy
klkvr Apr 6, 2024
1165de0
Merge branch 'master' into evalir/cast-provider-mig
klkvr Apr 6, 2024
26bf989
AnyNetwork
klkvr Apr 7, 2024
50b3bc1
bump alloy
klkvr Apr 7, 2024
4ae360b
add comment
klkvr Apr 7, 2024
6900bef
clippy
klkvr Apr 7, 2024
e8ccb7d
bump alloy
klkvr Apr 9, 2024
f1a95d5
Merge branch 'master' into evalir/cast-provider-mig
klkvr Apr 9, 2024
abd79cf
fixes
klkvr Apr 9, 2024
144dc19
refactor cast logs to use alloy (#7594)
bernard-wagner Apr 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,108 changes: 721 additions & 387 deletions Cargo.lock

Large diffs are not rendered by default.

65 changes: 33 additions & 32 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,6 @@ codegen-units = 1
[profile.release.package]
mdbook.opt-level = 1
protobuf.opt-level = 1
rusoto_core.opt-level = 1
rusoto_credential.opt-level = 1
rusoto_kms.opt-level = 1
toml_edit.opt-level = 1
trezor-client.opt-level = 1

Expand Down Expand Up @@ -140,16 +137,16 @@ foundry-wallets = { path = "crates/wallets" }
foundry-linking = { path = "crates/linking" }

# solc & compilation utilities
foundry-block-explorers = { version = "0.2.4", default-features = false }
foundry-compilers = { version = "0.3.13", default-features = false }
foundry-block-explorers = { version = "0.2.5", default-features = false }
foundry-compilers = { version = "0.3.14", default-features = false }

## revm
# no default features to avoid c-kzg
revm = { version = "7.1", default-features = false, features = ["std"] }
revm-primitives = { version = "3", default-features = false, features = ["std"] }
revm-inspectors = { git = "https://github.com/paradigmxyz/evm-inspectors", rev = "ba0b6ab", features = [
revm = { version = "8", default-features = false }
revm-primitives = { version = "3", default-features = false }
revm-inspectors = { git = "https://github.com/paradigmxyz/evm-inspectors", rev = "510d4d0", features = [
"serde",
] }
] }

## ethers
ethers = { version = "2.0.14", default-features = false }
Expand All @@ -161,30 +158,34 @@ ethers-signers = { version = "2.0.14", default-features = false }
ethers-middleware = { version = "2.0.14", default-features = false }

## alloy
alloy-consensus = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-eips = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-genesis = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-json-rpc = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-network = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-node-bindings = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-providers = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-pubsub = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-rpc-client = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-rpc-trace-types = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-rpc-types = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-signer = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-transport = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-transport-http = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-transport-ipc = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-transport-ws = { git = "https://github.com/alloy-rs/alloy", rev = "9ac2c90", default-features = false }
alloy-primitives = { version = "0.6.3", features = ["getrandom"] }
alloy-dyn-abi = "0.6.3"
alloy-json-abi = "0.6.3"
alloy-sol-types = "0.6.3"
syn-solidity = "0.6.3"
alloy-consensus = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-contract = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-eips = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-genesis = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-json-rpc = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-network = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-node-bindings = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-provider = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-pubsub = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-rpc-client = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-rpc-types-trace = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-rpc-types = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-signer = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-signer-wallet = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-signer-aws = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-signer-ledger = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-signer-trezor = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-transport = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-transport-http = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-transport-ipc = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-transport-ws = { git = "https://github.com/alloy-rs/alloy", rev = "5f74d4e", default-features = false }
alloy-primitives = { version = "0.7.0", features = ["getrandom"] }
alloy-dyn-abi = "0.7.0"
alloy-json-abi = "0.7.0"
alloy-sol-types = "0.7.0"
syn-solidity = "0.7.0"
alloy-chains = "0.1"
alloy-trie = "0.3"

alloy-trie = "0.3.1"
alloy-rlp = "0.3.3"
solang-parser = "=0.3.3"

Expand Down
3 changes: 3 additions & 0 deletions clippy.toml
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
msrv = "1.76"
# bytes::Bytes is included by default and alloy_primitives::Bytes is a wrapper around it,
# so it is safe to ignore it as well
ignore-interior-mutability = ["bytes::Bytes", "alloy_primitives::Bytes"]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is this used? You should use static instead of const to silence this warning

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is needed to get rid of a mutable_key_type lint for pub type ExpectedCallTracker = HashMap<Address, HashMap<Bytes, (ExpectedCallData, u64)>>

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be allowed in clippy, please use Vec instead then

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually this is fine, bytes::Bytes is ignored by default as internal mutability is not exposed. Please add a note for this

21 changes: 15 additions & 6 deletions crates/anvil/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ path = "src/anvil.rs"
required-features = ["cli"]

[build-dependencies]
vergen = { workspace = true, default-features = false, features = ["build", "git", "gitcl"] }
vergen = { workspace = true, default-features = false, features = [
"build",
"git",
"gitcl",
] }

[dependencies]
# foundry internal
Expand All @@ -36,12 +40,13 @@ alloy-primitives = { workspace = true, features = ["serde"] }
alloy-consensus = { workspace = true, features = ["k256", "kzg"] }
alloy-network.workspace = true
alloy-rlp.workspace = true
alloy-signer = { workspace = true, features = ["eip712", "mnemonic"] }
alloy-signer = { workspace = true, features = ["eip712"] }
alloy-signer-wallet = { workspace = true, features = ["mnemonic"] }
alloy-sol-types = { workspace = true, features = ["std"] }
alloy-dyn-abi = { workspace = true, features = ["std", "eip712"] }
alloy-rpc-types.workspace = true
alloy-rpc-trace-types.workspace = true
alloy-providers.workspace = true
alloy-rpc-types-trace.workspace = true
alloy-provider = { workspace = true, features = ["pubsub"] }
alloy-transport.workspace = true
alloy-chains.workspace = true
alloy-genesis.workspace = true
Expand Down Expand Up @@ -75,7 +80,11 @@ rand = "0.8"
eyre.workspace = true

# cli
clap = { version = "4", features = ["derive", "env", "wrap_help"], optional = true }
clap = { version = "4", features = [
"derive",
"env",
"wrap_help",
], optional = true }
clap_complete = { version = "4", optional = true }
chrono.workspace = true
auto_impl = "1"
Expand All @@ -89,7 +98,7 @@ tikv-jemallocator = { workspace = true, optional = true }

[dev-dependencies]
alloy-json-abi.workspace = true
ethers = { workspace = true, features = ["abigen"] }
ethers = { workspace = true, features = ["abigen", "optimism"] }
ethers-core = { workspace = true, features = ["optimism"] }
foundry-compilers = { workspace = true, features = ["project-util", "full"] }

Expand Down
10 changes: 7 additions & 3 deletions crates/anvil/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,15 @@ repository.workspace = true
[dependencies]
foundry-common.workspace = true
foundry-evm.workspace = true
revm = { workspace = true, default-features = false, features = ["std", "serde", "memory_limit"] }
revm = { workspace = true, default-features = false, features = [
"std",
"serde",
"memory_limit",
] }

alloy-primitives = { workspace = true, features = ["serde"] }
alloy-rpc-types = { workspace = true }
alloy-rpc-trace-types.workspace = true
alloy-rpc-types-trace.workspace = true
alloy-rlp.workspace = true
alloy-eips.workspace = true
alloy-network = { workspace = true, features = ["k256"] }
Expand All @@ -27,7 +31,7 @@ alloy-trie.workspace = true
serde = { workspace = true, optional = true }
serde_json.workspace = true
bytes = "1.4"
c-kzg = { version = "0.4.2", features = ["serde"] }
c-kzg = { version = "1", features = ["serde"] }

# misc
rand = "0.8"
Expand Down
37 changes: 18 additions & 19 deletions crates/anvil/core/src/eth/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use super::{
trie,
};
use alloy_consensus::Header;
use alloy_primitives::{Address, Bloom, Bytes, B256, U256};
use alloy_primitives::{Address, Bloom, Bytes, B256, B64, U256};
use alloy_rlp::{RlpDecodable, RlpEncodable};

// Type alias to optionally support impersonated transactions
Expand Down Expand Up @@ -88,13 +88,13 @@ pub struct PartialHeader {
pub logs_bloom: Bloom,
pub difficulty: U256,
pub number: u64,
pub gas_limit: u64,
pub gas_used: u64,
pub gas_limit: u128,
pub gas_used: u128,
pub timestamp: u64,
pub extra_data: Bytes,
pub mix_hash: B256,
pub nonce: u64,
pub base_fee: Option<u64>,
pub nonce: B64,
pub base_fee: Option<u128>,
}

impl From<Header> for PartialHeader {
Expand All @@ -120,7 +120,6 @@ impl From<Header> for PartialHeader {

#[cfg(test)]
mod tests {
use alloy_network::Sealable;
use alloy_primitives::{
b256,
hex::{self, FromHex},
Expand All @@ -143,11 +142,11 @@ mod tests {
difficulty: Default::default(),
number: 124u64,
gas_limit: Default::default(),
gas_used: 1337u64,
gas_used: 1337u128,
timestamp: 0,
extra_data: Default::default(),
mix_hash: Default::default(),
nonce: 99u64,
nonce: B64::with_last_byte(99),
withdrawals_root: Default::default(),
blob_gas_used: Default::default(),
excess_blob_gas: Default::default(),
Expand All @@ -159,7 +158,7 @@ mod tests {
let decoded: Header = Header::decode(&mut encoded.as_ref()).unwrap();
assert_eq!(header, decoded);

header.base_fee_per_gas = Some(12345u64);
header.base_fee_per_gas = Some(12345u128);

let encoded = alloy_rlp::encode(&header);
let decoded: Header = Header::decode(&mut encoded.as_ref()).unwrap();
Expand All @@ -182,16 +181,16 @@ mod tests {
logs_bloom: Bloom::from_hex("00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000").unwrap(),
difficulty: U256::from(2222),
number: 0xd05u64,
gas_limit: 0x115cu64,
gas_used: 0x15b3u64,
gas_limit: 0x115cu128,
gas_used: 0x15b3u128,
timestamp: 0x1a0au64,
extra_data: hex::decode("7788").unwrap().into(),
mix_hash: B256::from_str("0000000000000000000000000000000000000000000000000000000000000000").unwrap(),
withdrawals_root: None,
blob_gas_used: None,
excess_blob_gas: None,
parent_beacon_block_root: None,
nonce: 0,
nonce: B64::ZERO,
base_fee_per_gas: None,
};

Expand All @@ -214,12 +213,12 @@ mod tests {
logs_bloom: <[u8; 256]>::from_hex("00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000").unwrap().into(),
difficulty: U256::from(2222),
number: 0xd05u64,
gas_limit: 0x115cu64,
gas_used: 0x15b3u64,
gas_limit: 0x115cu128,
gas_used: 0x15b3u128,
timestamp: 0x1a0au64,
extra_data: hex::decode("7788").unwrap().into(),
mix_hash: B256::from_str("0000000000000000000000000000000000000000000000000000000000000000").unwrap(),
nonce: 0,
nonce: B64::ZERO,
withdrawals_root: None,
blob_gas_used: None,
excess_blob_gas: None,
Expand All @@ -245,19 +244,19 @@ mod tests {
logs_bloom: Bloom::from_hex("00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000").unwrap(),
difficulty: U256::from(0x020000),
number: 1u64,
gas_limit: U256::from(0x016345785d8a0000u128).to::<u64>(),
gas_used: U256::from(0x015534).to::<u64>(),
gas_limit: U256::from(0x016345785d8a0000u128).to::<u128>(),
gas_used: U256::from(0x015534).to::<u128>(),
timestamp: 0x079e,
extra_data: hex::decode("42").unwrap().into(),
mix_hash: B256::from_str("0000000000000000000000000000000000000000000000000000000000000000").unwrap(),
nonce: 0,
nonce: B64::ZERO,
base_fee_per_gas: Some(875),
withdrawals_root: None,
blob_gas_used: None,
excess_blob_gas: None,
parent_beacon_block_root: None,
};
assert_eq!(header.hash(), expected_hash);
assert_eq!(header.hash_slow(), expected_hash);
}

#[test]
Expand Down
18 changes: 9 additions & 9 deletions crates/anvil/core/src/eth/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ use crate::{
types::{EvmMineOptions, Forking, Index},
};
use alloy_primitives::{Address, Bytes, TxHash, B256, B64, U256};
use alloy_rpc_trace_types::geth::{GethDebugTracingOptions, GethDefaultTracingOptions};
use alloy_rpc_types::{
pubsub::{Params as SubscriptionParams, SubscriptionKind},
request::TransactionRequest,
state::StateOverride,
BlockId, BlockNumberOrTag as BlockNumber, Filter,
BlockId, BlockNumberOrTag as BlockNumber, Filter, WithOtherFields,
};
use alloy_rpc_types_trace::geth::{GethDebugTracingOptions, GethDefaultTracingOptions};

pub mod block;
pub mod proof;
Expand Down Expand Up @@ -143,7 +143,7 @@ pub enum EthRequest {
EthSign(Address, Bytes),

#[cfg_attr(feature = "serde", serde(rename = "eth_signTransaction"))]
EthSignTransaction(Box<TransactionRequest>),
EthSignTransaction(Box<WithOtherFields<TransactionRequest>>),

/// Signs data via [EIP-712](https://github.com/ethereum/EIPs/blob/master/EIPS/eip-712.md).
#[cfg_attr(feature = "serde", serde(rename = "eth_signTypedData"))]
Expand All @@ -158,27 +158,27 @@ pub enum EthRequest {
EthSignTypedDataV4(Address, alloy_dyn_abi::TypedData),

#[cfg_attr(feature = "serde", serde(rename = "eth_sendTransaction", with = "sequence"))]
EthSendTransaction(Box<TransactionRequest>),
EthSendTransaction(Box<WithOtherFields<TransactionRequest>>),

#[cfg_attr(feature = "serde", serde(rename = "eth_sendRawTransaction", with = "sequence"))]
EthSendRawTransaction(Bytes),

#[cfg_attr(feature = "serde", serde(rename = "eth_call"))]
EthCall(
TransactionRequest,
WithOtherFields<TransactionRequest>,
#[cfg_attr(feature = "serde", serde(default))] Option<BlockId>,
#[cfg_attr(feature = "serde", serde(default))] Option<StateOverride>,
),

#[cfg_attr(feature = "serde", serde(rename = "eth_createAccessList"))]
EthCreateAccessList(
TransactionRequest,
WithOtherFields<TransactionRequest>,
#[cfg_attr(feature = "serde", serde(default))] Option<BlockId>,
),

#[cfg_attr(feature = "serde", serde(rename = "eth_estimateGas"))]
EthEstimateGas(
TransactionRequest,
WithOtherFields<TransactionRequest>,
#[cfg_attr(feature = "serde", serde(default))] Option<BlockId>,
#[cfg_attr(feature = "serde", serde(default))] Option<StateOverride>,
),
Expand Down Expand Up @@ -272,7 +272,7 @@ pub enum EthRequest {
/// geth's `debug_traceCall` endpoint
#[cfg_attr(feature = "serde", serde(rename = "debug_traceCall"))]
DebugTraceCall(
TransactionRequest,
WithOtherFields<TransactionRequest>,
#[cfg_attr(feature = "serde", serde(default))] Option<BlockId>,
#[cfg_attr(feature = "serde", serde(default))] GethDefaultTracingOptions,
),
Expand Down Expand Up @@ -597,7 +597,7 @@ pub enum EthRequest {
feature = "serde",
serde(rename = "eth_sendUnsignedTransaction", with = "sequence")
)]
EthSendUnsignedTransaction(Box<TransactionRequest>),
EthSendUnsignedTransaction(Box<WithOtherFields<TransactionRequest>>),

/// Turn on call traces for transactions that are returned to the user when they execute a
/// transaction (instead of just txhash/receipt)
Expand Down
Loading
Loading