mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
rpc: rm useless reexports in reth-rpc-types (#11113)
This commit is contained in:
17
Cargo.lock
generated
17
Cargo.lock
generated
@ -6902,6 +6902,7 @@ dependencies = [
|
|||||||
"futures-util",
|
"futures-util",
|
||||||
"jsonrpsee",
|
"jsonrpsee",
|
||||||
"jsonrpsee-types",
|
"jsonrpsee-types",
|
||||||
|
"op-alloy-rpc-types-engine",
|
||||||
"reth",
|
"reth",
|
||||||
"reth-chainspec",
|
"reth-chainspec",
|
||||||
"reth-db",
|
"reth-db",
|
||||||
@ -7934,6 +7935,7 @@ dependencies = [
|
|||||||
"eyre",
|
"eyre",
|
||||||
"jsonrpsee",
|
"jsonrpsee",
|
||||||
"jsonrpsee-types",
|
"jsonrpsee-types",
|
||||||
|
"op-alloy-rpc-types-engine",
|
||||||
"parking_lot 0.12.3",
|
"parking_lot 0.12.3",
|
||||||
"reqwest",
|
"reqwest",
|
||||||
"reth",
|
"reth",
|
||||||
@ -8074,6 +8076,7 @@ version = "1.0.7"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rlp",
|
"alloy-rlp",
|
||||||
|
"op-alloy-rpc-types-engine",
|
||||||
"reth-basic-payload-builder",
|
"reth-basic-payload-builder",
|
||||||
"reth-chain-state",
|
"reth-chain-state",
|
||||||
"reth-chainspec",
|
"reth-chainspec",
|
||||||
@ -8386,11 +8389,13 @@ dependencies = [
|
|||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rlp",
|
"alloy-rlp",
|
||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
|
"alloy-rpc-types-admin",
|
||||||
"alloy-rpc-types-debug",
|
"alloy-rpc-types-debug",
|
||||||
"alloy-rpc-types-eth",
|
"alloy-rpc-types-eth",
|
||||||
"alloy-rpc-types-mev",
|
"alloy-rpc-types-mev",
|
||||||
"alloy-rpc-types-trace",
|
"alloy-rpc-types-trace",
|
||||||
"alloy-rpc-types-txpool",
|
"alloy-rpc-types-txpool",
|
||||||
|
"alloy-serde",
|
||||||
"async-trait",
|
"async-trait",
|
||||||
"derive_more",
|
"derive_more",
|
||||||
"futures",
|
"futures",
|
||||||
@ -8448,12 +8453,15 @@ dependencies = [
|
|||||||
"alloy-json-rpc",
|
"alloy-json-rpc",
|
||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
|
"alloy-rpc-types-admin",
|
||||||
"alloy-rpc-types-anvil",
|
"alloy-rpc-types-anvil",
|
||||||
|
"alloy-rpc-types-beacon",
|
||||||
"alloy-rpc-types-debug",
|
"alloy-rpc-types-debug",
|
||||||
"alloy-rpc-types-eth",
|
"alloy-rpc-types-eth",
|
||||||
"alloy-rpc-types-mev",
|
"alloy-rpc-types-mev",
|
||||||
"alloy-rpc-types-trace",
|
"alloy-rpc-types-trace",
|
||||||
"alloy-rpc-types-txpool",
|
"alloy-rpc-types-txpool",
|
||||||
|
"alloy-serde",
|
||||||
"jsonrpsee",
|
"jsonrpsee",
|
||||||
"reth-engine-primitives",
|
"reth-engine-primitives",
|
||||||
"reth-network-peers",
|
"reth-network-peers",
|
||||||
@ -8491,6 +8499,7 @@ dependencies = [
|
|||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
"alloy-rpc-types-eth",
|
"alloy-rpc-types-eth",
|
||||||
"alloy-rpc-types-trace",
|
"alloy-rpc-types-trace",
|
||||||
|
"alloy-serde",
|
||||||
"clap",
|
"clap",
|
||||||
"http",
|
"http",
|
||||||
"jsonrpsee",
|
"jsonrpsee",
|
||||||
@ -8617,6 +8626,7 @@ dependencies = [
|
|||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
"alloy-rpc-types-eth",
|
"alloy-rpc-types-eth",
|
||||||
|
"alloy-serde",
|
||||||
"alloy-sol-types",
|
"alloy-sol-types",
|
||||||
"derive_more",
|
"derive_more",
|
||||||
"futures",
|
"futures",
|
||||||
@ -8687,14 +8697,9 @@ version = "1.0.7"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
"alloy-rpc-types-admin",
|
|
||||||
"alloy-rpc-types-beacon",
|
|
||||||
"alloy-rpc-types-engine",
|
"alloy-rpc-types-engine",
|
||||||
"alloy-serde",
|
|
||||||
"arbitrary",
|
"arbitrary",
|
||||||
"jsonrpsee-types",
|
"jsonrpsee-types",
|
||||||
"op-alloy-rpc-types",
|
|
||||||
"op-alloy-rpc-types-engine",
|
|
||||||
"rand 0.8.5",
|
"rand 0.8.5",
|
||||||
]
|
]
|
||||||
|
|
||||||
@ -8705,6 +8710,8 @@ dependencies = [
|
|||||||
"alloy-primitives",
|
"alloy-primitives",
|
||||||
"alloy-rlp",
|
"alloy-rlp",
|
||||||
"alloy-rpc-types",
|
"alloy-rpc-types",
|
||||||
|
"alloy-rpc-types-eth",
|
||||||
|
"alloy-serde",
|
||||||
"reth-primitives",
|
"reth-primitives",
|
||||||
"reth-rpc-types",
|
"reth-rpc-types",
|
||||||
"reth-trie-common",
|
"reth-trie-common",
|
||||||
|
|||||||
@ -35,6 +35,7 @@ jsonrpsee.workspace = true
|
|||||||
|
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
|
op-alloy-rpc-types-engine.workspace = true
|
||||||
|
|
||||||
futures-util.workspace = true
|
futures-util.workspace = true
|
||||||
eyre.workspace = true
|
eyre.workspace = true
|
||||||
|
|||||||
@ -1,7 +1,5 @@
|
|||||||
use reth::rpc::types::{
|
use op_alloy_rpc_types_engine::OptimismExecutionPayloadEnvelopeV3;
|
||||||
engine::ExecutionPayloadEnvelopeV3, optimism::OptimismExecutionPayloadEnvelopeV3,
|
use reth::rpc::types::{engine::ExecutionPayloadEnvelopeV3, ExecutionPayloadV3};
|
||||||
ExecutionPayloadV3,
|
|
||||||
};
|
|
||||||
|
|
||||||
/// The execution payload envelope type.
|
/// The execution payload envelope type.
|
||||||
pub trait PayloadEnvelopeExt: Send + Sync + std::fmt::Debug {
|
pub trait PayloadEnvelopeExt: Send + Sync + std::fmt::Debug {
|
||||||
|
|||||||
@ -44,6 +44,7 @@ reth-optimism-forks.workspace = true
|
|||||||
|
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
|
op-alloy-rpc-types-engine.workspace = true
|
||||||
|
|
||||||
# async
|
# async
|
||||||
async-trait.workspace = true
|
async-trait.workspace = true
|
||||||
|
|||||||
@ -1,3 +1,7 @@
|
|||||||
|
use op_alloy_rpc_types_engine::{
|
||||||
|
OptimismExecutionPayloadEnvelopeV3, OptimismExecutionPayloadEnvelopeV4,
|
||||||
|
OptimismPayloadAttributes,
|
||||||
|
};
|
||||||
use reth_chainspec::ChainSpec;
|
use reth_chainspec::ChainSpec;
|
||||||
use reth_node_api::{
|
use reth_node_api::{
|
||||||
payload::{
|
payload::{
|
||||||
@ -9,14 +13,7 @@ use reth_node_api::{
|
|||||||
};
|
};
|
||||||
use reth_optimism_forks::OptimismHardfork;
|
use reth_optimism_forks::OptimismHardfork;
|
||||||
use reth_optimism_payload_builder::{OptimismBuiltPayload, OptimismPayloadBuilderAttributes};
|
use reth_optimism_payload_builder::{OptimismBuiltPayload, OptimismPayloadBuilderAttributes};
|
||||||
use reth_rpc_types::{
|
use reth_rpc_types::{engine::ExecutionPayloadEnvelopeV2, ExecutionPayloadV1};
|
||||||
engine::ExecutionPayloadEnvelopeV2,
|
|
||||||
optimism::{
|
|
||||||
OptimismExecutionPayloadEnvelopeV3, OptimismExecutionPayloadEnvelopeV4,
|
|
||||||
OptimismPayloadAttributes,
|
|
||||||
},
|
|
||||||
ExecutionPayloadV1,
|
|
||||||
};
|
|
||||||
|
|
||||||
/// The types used in the optimism beacon consensus engine.
|
/// The types used in the optimism beacon consensus engine.
|
||||||
#[derive(Debug, Default, Clone, serde::Deserialize, serde::Serialize)]
|
#[derive(Debug, Default, Clone, serde::Deserialize, serde::Serialize)]
|
||||||
|
|||||||
@ -36,6 +36,7 @@ reth-optimism-forks.workspace = true
|
|||||||
revm.workspace = true
|
revm.workspace = true
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
alloy-rlp.workspace = true
|
alloy-rlp.workspace = true
|
||||||
|
op-alloy-rpc-types-engine.workspace = true
|
||||||
|
|
||||||
# misc
|
# misc
|
||||||
tracing.workspace = true
|
tracing.workspace = true
|
||||||
|
|||||||
@ -4,6 +4,11 @@
|
|||||||
|
|
||||||
use alloy_primitives::{Address, B256, U256};
|
use alloy_primitives::{Address, B256, U256};
|
||||||
use alloy_rlp::Encodable;
|
use alloy_rlp::Encodable;
|
||||||
|
/// Re-export for use in downstream arguments.
|
||||||
|
pub use op_alloy_rpc_types_engine::OptimismPayloadAttributes;
|
||||||
|
use op_alloy_rpc_types_engine::{
|
||||||
|
OptimismExecutionPayloadEnvelopeV3, OptimismExecutionPayloadEnvelopeV4,
|
||||||
|
};
|
||||||
use reth_chain_state::ExecutedBlock;
|
use reth_chain_state::ExecutedBlock;
|
||||||
use reth_chainspec::{ChainSpec, EthereumHardforks};
|
use reth_chainspec::{ChainSpec, EthereumHardforks};
|
||||||
use reth_payload_builder::EthPayloadBuilderAttributes;
|
use reth_payload_builder::EthPayloadBuilderAttributes;
|
||||||
@ -11,12 +16,7 @@ use reth_payload_primitives::{BuiltPayload, PayloadBuilderAttributes};
|
|||||||
use reth_primitives::{
|
use reth_primitives::{
|
||||||
transaction::WithEncoded, BlobTransactionSidecar, SealedBlock, TransactionSigned, Withdrawals,
|
transaction::WithEncoded, BlobTransactionSidecar, SealedBlock, TransactionSigned, Withdrawals,
|
||||||
};
|
};
|
||||||
/// Re-export for use in downstream arguments.
|
use reth_rpc_types::engine::{ExecutionPayloadEnvelopeV2, ExecutionPayloadV1, PayloadId};
|
||||||
pub use reth_rpc_types::optimism::OptimismPayloadAttributes;
|
|
||||||
use reth_rpc_types::{
|
|
||||||
engine::{ExecutionPayloadEnvelopeV2, ExecutionPayloadV1, PayloadId},
|
|
||||||
optimism::{OptimismExecutionPayloadEnvelopeV3, OptimismExecutionPayloadEnvelopeV4},
|
|
||||||
};
|
|
||||||
use reth_rpc_types_compat::engine::payload::{
|
use reth_rpc_types_compat::engine::payload::{
|
||||||
block_to_payload_v1, block_to_payload_v3, block_to_payload_v4,
|
block_to_payload_v1, block_to_payload_v3, block_to_payload_v4,
|
||||||
convert_block_to_payload_field_v2,
|
convert_block_to_payload_field_v2,
|
||||||
|
|||||||
@ -30,6 +30,9 @@ alloy-rpc-types-trace.workspace = true
|
|||||||
alloy-rpc-types-anvil.workspace = true
|
alloy-rpc-types-anvil.workspace = true
|
||||||
alloy-rpc-types-mev.workspace = true
|
alloy-rpc-types-mev.workspace = true
|
||||||
alloy-rpc-types-txpool.workspace = true
|
alloy-rpc-types-txpool.workspace = true
|
||||||
|
alloy-rpc-types-admin.workspace = true
|
||||||
|
alloy-serde.workspace = true
|
||||||
|
alloy-rpc-types-beacon.workspace = true
|
||||||
|
|
||||||
# misc
|
# misc
|
||||||
jsonrpsee = { workspace = true, features = ["server", "macros"] }
|
jsonrpsee = { workspace = true, features = ["server", "macros"] }
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
|
use alloy_rpc_types_admin::{NodeInfo, PeerInfo};
|
||||||
use jsonrpsee::{core::RpcResult, proc_macros::rpc};
|
use jsonrpsee::{core::RpcResult, proc_macros::rpc};
|
||||||
use reth_network_peers::{AnyNode, NodeRecord};
|
use reth_network_peers::{AnyNode, NodeRecord};
|
||||||
use reth_rpc_types::admin::{NodeInfo, PeerInfo};
|
|
||||||
|
|
||||||
/// Admin namespace rpc interface that gives access to several non-standard RPC methods.
|
/// Admin namespace rpc interface that gives access to several non-standard RPC methods.
|
||||||
#[cfg_attr(not(feature = "client"), rpc(server, namespace = "admin"))]
|
#[cfg_attr(not(feature = "client"), rpc(server, namespace = "admin"))]
|
||||||
|
|||||||
@ -10,15 +10,13 @@ use alloy_rpc_types::{
|
|||||||
state::StateOverride, BlockOverrides, EIP1186AccountProofResponse, Filter, Log, SyncStatus,
|
state::StateOverride, BlockOverrides, EIP1186AccountProofResponse, Filter, Log, SyncStatus,
|
||||||
};
|
};
|
||||||
use alloy_rpc_types_eth::transaction::TransactionRequest;
|
use alloy_rpc_types_eth::transaction::TransactionRequest;
|
||||||
|
use alloy_serde::JsonStorageKey;
|
||||||
use jsonrpsee::{core::RpcResult, proc_macros::rpc};
|
use jsonrpsee::{core::RpcResult, proc_macros::rpc};
|
||||||
use reth_engine_primitives::EngineTypes;
|
use reth_engine_primitives::EngineTypes;
|
||||||
use reth_rpc_types::{
|
use reth_rpc_types::engine::{
|
||||||
engine::{
|
ClientVersionV1, ExecutionPayloadBodiesV1, ExecutionPayloadBodiesV2, ExecutionPayloadInputV2,
|
||||||
ClientVersionV1, ExecutionPayloadBodiesV1, ExecutionPayloadBodiesV2,
|
ExecutionPayloadV1, ExecutionPayloadV3, ExecutionPayloadV4, ForkchoiceState, ForkchoiceUpdated,
|
||||||
ExecutionPayloadInputV2, ExecutionPayloadV1, ExecutionPayloadV3, ExecutionPayloadV4,
|
PayloadId, PayloadStatus, TransitionConfiguration,
|
||||||
ForkchoiceState, ForkchoiceUpdated, PayloadId, PayloadStatus, TransitionConfiguration,
|
|
||||||
},
|
|
||||||
JsonStorageKey,
|
|
||||||
};
|
};
|
||||||
// NOTE: We can't use associated types in the `EngineApi` trait because of jsonrpsee, so we use a
|
// NOTE: We can't use associated types in the `EngineApi` trait because of jsonrpsee, so we use a
|
||||||
// generic here. It would be nice if the rpc macro would understand which types need to have serde.
|
// generic here. It would be nice if the rpc macro would understand which types need to have serde.
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
//! API for block submission validation.
|
//! API for block submission validation.
|
||||||
|
|
||||||
use jsonrpsee::proc_macros::rpc;
|
use alloy_rpc_types_beacon::relay::{
|
||||||
use reth_rpc_types::beacon::relay::{
|
|
||||||
BuilderBlockValidationRequest, BuilderBlockValidationRequestV2,
|
BuilderBlockValidationRequest, BuilderBlockValidationRequestV2,
|
||||||
};
|
};
|
||||||
|
use jsonrpsee::proc_macros::rpc;
|
||||||
|
|
||||||
/// Block validation rpc interface.
|
/// Block validation rpc interface.
|
||||||
#[cfg_attr(not(feature = "client"), rpc(server, namespace = "flashbots"))]
|
#[cfg_attr(not(feature = "client"), rpc(server, namespace = "flashbots"))]
|
||||||
|
|||||||
@ -28,12 +28,12 @@ reth-tasks = { workspace = true, features = ["rayon"] }
|
|||||||
reth-transaction-pool.workspace = true
|
reth-transaction-pool.workspace = true
|
||||||
reth-evm.workspace = true
|
reth-evm.workspace = true
|
||||||
reth-engine-primitives.workspace = true
|
reth-engine-primitives.workspace = true
|
||||||
reth-rpc-types.workspace = true
|
|
||||||
reth-primitives.workspace = true
|
reth-primitives.workspace = true
|
||||||
|
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-network.workspace = true
|
alloy-network.workspace = true
|
||||||
alloy-rpc-types.workspace = true
|
alloy-rpc-types.workspace = true
|
||||||
|
alloy-serde.workspace = true
|
||||||
|
|
||||||
# rpc/net
|
# rpc/net
|
||||||
jsonrpsee = { workspace = true, features = ["server"] }
|
jsonrpsee = { workspace = true, features = ["server"] }
|
||||||
|
|||||||
@ -815,7 +815,7 @@ where
|
|||||||
EthApi: TraceExt
|
EthApi: TraceExt
|
||||||
+ EthTransactions<
|
+ EthTransactions<
|
||||||
NetworkTypes: alloy_network::Network<
|
NetworkTypes: alloy_network::Network<
|
||||||
TransactionResponse = reth_rpc_types::WithOtherFields<
|
TransactionResponse = alloy_serde::WithOtherFields<
|
||||||
alloy_rpc_types::Transaction,
|
alloy_rpc_types::Transaction,
|
||||||
>,
|
>,
|
||||||
>,
|
>,
|
||||||
|
|||||||
@ -37,6 +37,7 @@ revm.workspace = true
|
|||||||
revm-inspectors.workspace = true
|
revm-inspectors.workspace = true
|
||||||
revm-primitives = { workspace = true, features = ["dev"] }
|
revm-primitives = { workspace = true, features = ["dev"] }
|
||||||
alloy-rpc-types.workspace = true
|
alloy-rpc-types.workspace = true
|
||||||
|
alloy-serde.workspace = true
|
||||||
|
|
||||||
# rpc
|
# rpc
|
||||||
jsonrpsee-core.workspace = true
|
jsonrpsee-core.workspace = true
|
||||||
|
|||||||
@ -4,8 +4,8 @@ use alloy_primitives::{Address, TxKind};
|
|||||||
use alloy_rpc_types::{
|
use alloy_rpc_types::{
|
||||||
AnyReceiptEnvelope, AnyTransactionReceipt, Log, ReceiptWithBloom, TransactionReceipt,
|
AnyReceiptEnvelope, AnyTransactionReceipt, Log, ReceiptWithBloom, TransactionReceipt,
|
||||||
};
|
};
|
||||||
|
use alloy_serde::{OtherFields, WithOtherFields};
|
||||||
use reth_primitives::{Receipt, TransactionMeta, TransactionSigned};
|
use reth_primitives::{Receipt, TransactionMeta, TransactionSigned};
|
||||||
use reth_rpc_types::{OtherFields, WithOtherFields};
|
|
||||||
use revm_primitives::calc_blob_gasprice;
|
use revm_primitives::calc_blob_gasprice;
|
||||||
|
|
||||||
use super::{EthApiError, EthResult};
|
use super::{EthApiError, EthResult};
|
||||||
|
|||||||
@ -21,6 +21,8 @@ reth-trie-common.workspace = true
|
|||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
alloy-rlp.workspace = true
|
alloy-rlp.workspace = true
|
||||||
alloy-rpc-types.workspace = true
|
alloy-rpc-types.workspace = true
|
||||||
|
alloy-rpc-types-eth = { workspace = true, default-features = false, features = ["serde"] }
|
||||||
|
alloy-serde.workspace = true
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
serde_json.workspace = true
|
serde_json.workspace = true
|
||||||
|
|||||||
@ -1,8 +1,7 @@
|
|||||||
//! Compatibility functions for rpc proof related types.
|
//! Compatibility functions for rpc proof related types.
|
||||||
|
|
||||||
use alloy_rpc_types::{
|
use alloy_rpc_types::serde_helpers::JsonStorageKey;
|
||||||
serde_helpers::JsonStorageKey, EIP1186AccountProofResponse, EIP1186StorageProof,
|
use alloy_rpc_types_eth::{EIP1186AccountProofResponse, EIP1186StorageProof};
|
||||||
};
|
|
||||||
use reth_trie_common::{AccountProof, StorageProof};
|
use reth_trie_common::{AccountProof, StorageProof};
|
||||||
|
|
||||||
/// Creates a new rpc storage proof from a primitive storage proof type.
|
/// Creates a new rpc storage proof from a primitive storage proof type.
|
||||||
|
|||||||
@ -12,8 +12,8 @@ use alloy_rpc_types::{
|
|||||||
request::{TransactionInput, TransactionRequest},
|
request::{TransactionInput, TransactionRequest},
|
||||||
Transaction, TransactionInfo,
|
Transaction, TransactionInfo,
|
||||||
};
|
};
|
||||||
|
use alloy_serde::WithOtherFields;
|
||||||
use reth_primitives::{TransactionSigned, TransactionSignedEcRecovered, TxType};
|
use reth_primitives::{TransactionSigned, TransactionSignedEcRecovered, TxType};
|
||||||
use reth_rpc_types::WithOtherFields;
|
|
||||||
|
|
||||||
/// Create a new rpc transaction result for a mined transaction, using the given block hash,
|
/// Create a new rpc transaction result for a mined transaction, using the given block hash,
|
||||||
/// number, and tx index fields to populate the corresponding fields in the rpc result.
|
/// number, and tx index fields to populate the corresponding fields in the rpc result.
|
||||||
|
|||||||
@ -16,15 +16,8 @@ workspace = true
|
|||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives = { workspace = true, features = ["rand", "rlp", "serde"] }
|
alloy-primitives = { workspace = true, features = ["rand", "rlp", "serde"] }
|
||||||
alloy-rpc-types.workspace = true
|
alloy-rpc-types.workspace = true
|
||||||
alloy-rpc-types-admin.workspace = true
|
|
||||||
alloy-rpc-types-beacon = { workspace = true, optional = true }
|
|
||||||
alloy-serde.workspace = true
|
|
||||||
alloy-rpc-types-engine = { workspace = true, features = ["std", "serde", "jsonrpsee-types"], optional = true }
|
alloy-rpc-types-engine = { workspace = true, features = ["std", "serde", "jsonrpsee-types"], optional = true }
|
||||||
|
|
||||||
# optimism
|
|
||||||
op-alloy-rpc-types.workspace = true
|
|
||||||
op-alloy-rpc-types-engine.workspace = true
|
|
||||||
|
|
||||||
# misc
|
# misc
|
||||||
jsonrpsee-types = { workspace = true, optional = true }
|
jsonrpsee-types = { workspace = true, optional = true }
|
||||||
|
|
||||||
@ -38,7 +31,6 @@ rand.workspace = true
|
|||||||
default = ["jsonrpsee-types"]
|
default = ["jsonrpsee-types"]
|
||||||
jsonrpsee-types = [
|
jsonrpsee-types = [
|
||||||
"dep:jsonrpsee-types",
|
"dep:jsonrpsee-types",
|
||||||
"dep:alloy-rpc-types-beacon",
|
|
||||||
"dep:alloy-rpc-types-engine",
|
"dep:alloy-rpc-types-engine",
|
||||||
"alloy-rpc-types/jsonrpsee-types",
|
"alloy-rpc-types/jsonrpsee-types",
|
||||||
"alloy-rpc-types-engine/jsonrpsee-types",
|
"alloy-rpc-types-engine/jsonrpsee-types",
|
||||||
|
|||||||
@ -13,19 +13,7 @@
|
|||||||
mod eth;
|
mod eth;
|
||||||
|
|
||||||
/// Alias for a peer identifier
|
/// Alias for a peer identifier
|
||||||
pub type PeerId = B512;
|
pub type PeerId = alloy_primitives::B512;
|
||||||
|
|
||||||
use alloy_primitives::B512;
|
|
||||||
|
|
||||||
// Ethereum specific serde types coming from alloy.
|
|
||||||
pub use alloy_serde::*;
|
|
||||||
|
|
||||||
// re-export admin
|
|
||||||
pub use alloy_rpc_types_admin as admin;
|
|
||||||
|
|
||||||
// re-export beacon
|
|
||||||
#[cfg(feature = "jsonrpsee-types")]
|
|
||||||
pub use alloy_rpc_types_beacon as beacon;
|
|
||||||
|
|
||||||
// Ethereum specific rpc types related to typed transaction requests and the engine API.
|
// Ethereum specific rpc types related to typed transaction requests and the engine API.
|
||||||
#[cfg(feature = "jsonrpsee-types")]
|
#[cfg(feature = "jsonrpsee-types")]
|
||||||
@ -38,9 +26,3 @@ pub use eth::{
|
|||||||
ExecutionPayload, ExecutionPayloadV1, ExecutionPayloadV2, ExecutionPayloadV3, PayloadError,
|
ExecutionPayload, ExecutionPayloadV1, ExecutionPayloadV2, ExecutionPayloadV3, PayloadError,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
/// Optimism specific rpc types.
|
|
||||||
pub mod optimism {
|
|
||||||
pub use op_alloy_rpc_types::*;
|
|
||||||
pub use op_alloy_rpc_types_engine::*;
|
|
||||||
}
|
|
||||||
|
|||||||
@ -48,6 +48,8 @@ alloy-rpc-types-debug.workspace = true
|
|||||||
alloy-rpc-types-trace.workspace = true
|
alloy-rpc-types-trace.workspace = true
|
||||||
alloy-rpc-types-mev.workspace = true
|
alloy-rpc-types-mev.workspace = true
|
||||||
alloy-rpc-types-txpool.workspace = true
|
alloy-rpc-types-txpool.workspace = true
|
||||||
|
alloy-rpc-types-admin.workspace = true
|
||||||
|
alloy-serde.workspace = true
|
||||||
revm = { workspace = true, features = [
|
revm = { workspace = true, features = [
|
||||||
"optional_block_gas_limit",
|
"optional_block_gas_limit",
|
||||||
"optional_eip3607",
|
"optional_eip3607",
|
||||||
|
|||||||
@ -1,6 +1,10 @@
|
|||||||
use std::sync::Arc;
|
use std::sync::Arc;
|
||||||
|
|
||||||
use alloy_genesis::ChainConfig;
|
use alloy_genesis::ChainConfig;
|
||||||
|
use alloy_rpc_types_admin::{
|
||||||
|
EthInfo, EthPeerInfo, EthProtocolInfo, NodeInfo, PeerInfo, PeerNetworkInfo, PeerProtocolInfo,
|
||||||
|
Ports, ProtocolInfo,
|
||||||
|
};
|
||||||
use async_trait::async_trait;
|
use async_trait::async_trait;
|
||||||
use jsonrpsee::core::RpcResult;
|
use jsonrpsee::core::RpcResult;
|
||||||
use reth_chainspec::ChainSpec;
|
use reth_chainspec::ChainSpec;
|
||||||
@ -10,10 +14,6 @@ use reth_network_types::PeerKind;
|
|||||||
use reth_primitives::EthereumHardfork;
|
use reth_primitives::EthereumHardfork;
|
||||||
use reth_rpc_api::AdminApiServer;
|
use reth_rpc_api::AdminApiServer;
|
||||||
use reth_rpc_server_types::ToRpcResult;
|
use reth_rpc_server_types::ToRpcResult;
|
||||||
use reth_rpc_types::admin::{
|
|
||||||
EthInfo, EthPeerInfo, EthProtocolInfo, NodeInfo, PeerInfo, PeerNetworkInfo, PeerProtocolInfo,
|
|
||||||
Ports, ProtocolInfo,
|
|
||||||
};
|
|
||||||
|
|
||||||
/// `admin` API implementation.
|
/// `admin` API implementation.
|
||||||
///
|
///
|
||||||
|
|||||||
@ -3,13 +3,13 @@ use alloy_rpc_types::{
|
|||||||
state::StateOverride, BlockOverrides, EIP1186AccountProofResponse, Filter, Log, SyncStatus,
|
state::StateOverride, BlockOverrides, EIP1186AccountProofResponse, Filter, Log, SyncStatus,
|
||||||
};
|
};
|
||||||
use alloy_rpc_types_eth::transaction::TransactionRequest;
|
use alloy_rpc_types_eth::transaction::TransactionRequest;
|
||||||
|
use alloy_serde::JsonStorageKey;
|
||||||
use jsonrpsee::core::RpcResult as Result;
|
use jsonrpsee::core::RpcResult as Result;
|
||||||
use reth_primitives::{BlockId, BlockNumberOrTag};
|
use reth_primitives::{BlockId, BlockNumberOrTag};
|
||||||
use reth_rpc_api::{EngineEthApiServer, EthApiServer, EthFilterApiServer};
|
use reth_rpc_api::{EngineEthApiServer, EthApiServer, EthFilterApiServer};
|
||||||
/// Re-export for convenience
|
/// Re-export for convenience
|
||||||
pub use reth_rpc_engine_api::EngineApi;
|
pub use reth_rpc_engine_api::EngineApi;
|
||||||
use reth_rpc_eth_api::{FullEthApiTypes, RpcBlock, RpcReceipt, RpcTransaction};
|
use reth_rpc_eth_api::{FullEthApiTypes, RpcBlock, RpcReceipt, RpcTransaction};
|
||||||
use reth_rpc_types::JsonStorageKey;
|
|
||||||
use tracing_futures::Instrument;
|
use tracing_futures::Instrument;
|
||||||
|
|
||||||
macro_rules! engine_span {
|
macro_rules! engine_span {
|
||||||
|
|||||||
@ -2,8 +2,8 @@
|
|||||||
|
|
||||||
use alloy_network::{AnyNetwork, Network};
|
use alloy_network::{AnyNetwork, Network};
|
||||||
use alloy_rpc_types::{Transaction, TransactionInfo};
|
use alloy_rpc_types::{Transaction, TransactionInfo};
|
||||||
|
use alloy_serde::WithOtherFields;
|
||||||
use reth_primitives::{Address, TransactionSignedEcRecovered, TxKind};
|
use reth_primitives::{Address, TransactionSignedEcRecovered, TxKind};
|
||||||
use reth_rpc_types::WithOtherFields;
|
|
||||||
use reth_rpc_types_compat::{
|
use reth_rpc_types_compat::{
|
||||||
transaction::{from_primitive_signature, GasPrice},
|
transaction::{from_primitive_signature, GasPrice},
|
||||||
TransactionCompat,
|
TransactionCompat,
|
||||||
|
|||||||
@ -10,6 +10,7 @@ use alloy_rpc_types::{
|
|||||||
},
|
},
|
||||||
FilteredParams, Header, Log, Transaction,
|
FilteredParams, Header, Log, Transaction,
|
||||||
};
|
};
|
||||||
|
use alloy_serde::WithOtherFields;
|
||||||
use futures::StreamExt;
|
use futures::StreamExt;
|
||||||
use jsonrpsee::{
|
use jsonrpsee::{
|
||||||
server::SubscriptionMessage, types::ErrorObject, PendingSubscriptionSink, SubscriptionSink,
|
server::SubscriptionMessage, types::ErrorObject, PendingSubscriptionSink, SubscriptionSink,
|
||||||
@ -20,7 +21,6 @@ use reth_provider::{BlockReader, CanonStateSubscriptions, EvmEnvProvider};
|
|||||||
use reth_rpc_eth_api::{pubsub::EthPubSubApiServer, FullEthApiTypes, RpcTransaction};
|
use reth_rpc_eth_api::{pubsub::EthPubSubApiServer, FullEthApiTypes, RpcTransaction};
|
||||||
use reth_rpc_eth_types::logs_utils;
|
use reth_rpc_eth_types::logs_utils;
|
||||||
use reth_rpc_server_types::result::{internal_rpc_err, invalid_params_rpc_err};
|
use reth_rpc_server_types::result::{internal_rpc_err, invalid_params_rpc_err};
|
||||||
use reth_rpc_types::WithOtherFields;
|
|
||||||
use reth_rpc_types_compat::transaction::from_recovered;
|
use reth_rpc_types_compat::transaction::from_recovered;
|
||||||
use reth_tasks::{TaskSpawner, TokioTaskExecutor};
|
use reth_tasks::{TaskSpawner, TokioTaskExecutor};
|
||||||
use reth_transaction_pool::{NewTransactionEvent, TransactionPool};
|
use reth_transaction_pool::{NewTransactionEvent, TransactionPool};
|
||||||
|
|||||||
Reference in New Issue
Block a user