Skip to content

Commit

Permalink
chore: rm beacon consensus deps (#13716)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattsse authored Jan 7, 2025
1 parent ccaf9da commit fb69028
Show file tree
Hide file tree
Showing 16 changed files with 17 additions and 25 deletions.
8 changes: 3 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion crates/cli/commands/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ repository.workspace = true

[dependencies]
# reth
reth-beacon-consensus.workspace = true
reth-ethereum-consensus.workspace = true
reth-chainspec.workspace = true
reth-cli.workspace = true
reth-ethereum-cli.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion crates/cli/commands/src/import.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ use crate::common::{AccessRights, CliNodeTypes, Environment, EnvironmentArgs};
use alloy_primitives::B256;
use clap::Parser;
use futures::{Stream, StreamExt};
use reth_beacon_consensus::EthBeaconConsensus;
use reth_chainspec::{EthChainSpec, EthereumHardforks};
use reth_cli::chainspec::ChainSpecParser;
use reth_config::Config;
Expand All @@ -15,6 +14,7 @@ use reth_downloaders::{
file_client::{ChunkedFileReader, FileClient, DEFAULT_BYTE_LEN_CHUNK_CHAIN_FILE},
headers::reverse_headers::ReverseHeadersDownloaderBuilder,
};
use reth_ethereum_consensus::EthBeaconConsensus;
use reth_evm::execute::BlockExecutorProvider;
use reth_network_p2p::{
bodies::downloader::BodyDownloader,
Expand Down
2 changes: 1 addition & 1 deletion crates/cli/commands/src/stage/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ use crate::common::{AccessRights, CliNodeTypes, Environment, EnvironmentArgs};
use alloy_eips::BlockHashOrNumber;
use alloy_primitives::Sealable;
use clap::Parser;
use reth_beacon_consensus::EthBeaconConsensus;
use reth_chainspec::{EthChainSpec, EthereumHardforks};
use reth_cli::chainspec::ChainSpecParser;
use reth_cli_runner::CliContext;
Expand All @@ -18,6 +17,7 @@ use reth_downloaders::{
headers::reverse_headers::ReverseHeadersDownloaderBuilder,
};
use reth_eth_wire::NetPrimitivesFor;
use reth_ethereum_consensus::EthBeaconConsensus;
use reth_evm::execute::BlockExecutorProvider;
use reth_exex::ExExManagerHandle;
use reth_network::BlockDownloaderProvider;
Expand Down
1 change: 1 addition & 0 deletions crates/engine/tree/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ reth-chain-state = { workspace = true, features = ["test-utils"] }
reth-chainspec.workspace = true
reth-db = { workspace = true, features = ["test-utils"] }
reth-ethereum-engine-primitives.workspace = true
reth-ethereum-consensus.workspace = true
reth-evm = { workspace = true, features = ["test-utils"] }
reth-exex-types.workspace = true
reth-network-p2p = { workspace = true, features = ["test-utils"] }
Expand Down
2 changes: 1 addition & 1 deletion crates/engine/tree/src/tree/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2785,10 +2785,10 @@ mod tests {
use alloy_rlp::Decodable;
use alloy_rpc_types_engine::{CancunPayloadFields, ExecutionPayloadSidecar};
use assert_matches::assert_matches;
use reth_beacon_consensus::EthBeaconConsensus;
use reth_chain_state::{test_utils::TestBlockBuilder, BlockState};
use reth_chainspec::{ChainSpec, HOLESKY, MAINNET};
use reth_engine_primitives::ForkchoiceStatus;
use reth_ethereum_consensus::EthBeaconConsensus;
use reth_ethereum_engine_primitives::{EthEngineTypes, EthereumEngineValidator};
use reth_evm::test_utils::MockExecutorProvider;
use reth_primitives::{Block, BlockExt, EthPrimitives};
Expand Down
3 changes: 1 addition & 2 deletions crates/ethereum/engine-primitives/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]

mod payload;
use std::sync::Arc;

use alloy_rpc_types_engine::{ExecutionPayload, ExecutionPayloadSidecar, PayloadError};
pub use alloy_rpc_types_engine::{
ExecutionPayloadEnvelopeV2, ExecutionPayloadEnvelopeV3, ExecutionPayloadEnvelopeV4,
Expand All @@ -26,6 +24,7 @@ use reth_payload_primitives::{
use reth_payload_validator::ExecutionPayloadValidator;
use reth_primitives::{Block, NodePrimitives, SealedBlock, SealedBlockFor};
use reth_rpc_types_compat::engine::payload::block_to_payload;
use std::sync::Arc;

/// The types used in the default mainnet ethereum beacon consensus engine.
#[derive(Debug, Default, Clone, serde::Deserialize, serde::Serialize)]
Expand Down
2 changes: 1 addition & 1 deletion crates/ethereum/node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ reth-payload-builder.workspace = true
reth-ethereum-engine-primitives.workspace = true
reth-basic-payload-builder.workspace = true
reth-ethereum-payload-builder.workspace = true
reth-ethereum-consensus.workspace = true
reth-node-builder.workspace = true
reth-tracing.workspace = true
reth-provider.workspace = true
Expand All @@ -24,7 +25,6 @@ reth-network.workspace = true
reth-evm.workspace = true
reth-evm-ethereum.workspace = true
reth-consensus.workspace = true
reth-beacon-consensus.workspace = true
reth-rpc.workspace = true
reth-node-api.workspace = true
reth-chainspec.workspace = true
Expand Down
7 changes: 3 additions & 4 deletions crates/ethereum/node/src/node.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
//! Ethereum Node types config.
pub use crate::payload::EthereumPayloadBuilder;
use crate::{EthEngineTypes, EthEvmConfig};
use reth_beacon_consensus::EthBeaconConsensus;
use reth_chainspec::ChainSpec;
use reth_consensus::{ConsensusError, FullConsensus};
use reth_ethereum_consensus::EthBeaconConsensus;
pub use reth_ethereum_engine_primitives::EthereumEngineValidator;
use reth_ethereum_engine_primitives::{
EthBuiltPayload, EthPayloadAttributes, EthPayloadBuilderAttributes,
};
Expand All @@ -30,9 +32,6 @@ use reth_transaction_pool::{
use reth_trie_db::MerklePatriciaTrie;
use std::sync::Arc;

pub use crate::payload::EthereumPayloadBuilder;
pub use reth_ethereum_engine_primitives::EthereumEngineValidator;

/// Type configuration for a regular Ethereum node.
#[derive(Debug, Default, Clone, Copy)]
#[non_exhaustive]
Expand Down
1 change: 0 additions & 1 deletion crates/node/api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ workspace = true
[dependencies]
# reth
reth-db-api.workspace = true
reth-beacon-consensus.workspace = true
reth-consensus.workspace = true
reth-evm.workspace = true
reth-provider.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion crates/node/api/src/node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
use crate::ConfigureEvm;
use alloy_rpc_types_engine::JwtSecret;
use reth_beacon_consensus::BeaconConsensusEngineHandle;
use reth_consensus::{ConsensusError, FullConsensus};
use reth_db_api::{
database_metrics::{DatabaseMetadata, DatabaseMetrics},
Database,
};
use reth_engine_primitives::BeaconConsensusEngineHandle;
use reth_evm::execute::BlockExecutorProvider;
use reth_network_api::FullNetwork;
use reth_node_core::node_config::NodeConfig;
Expand Down
1 change: 0 additions & 1 deletion crates/rpc/rpc-builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ tokio = { workspace = true, features = ["rt", "rt-multi-thread"] }

[dev-dependencies]
reth-chainspec.workspace = true
reth-beacon-consensus.workspace = true
reth-network-api.workspace = true
reth-network-peers.workspace = true
reth-evm-ethereum.workspace = true
Expand Down
2 changes: 1 addition & 1 deletion crates/rpc/rpc-builder/tests/it/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ use std::{
};

use alloy_rpc_types_engine::{ClientCode, ClientVersionV1};
use reth_beacon_consensus::BeaconConsensusEngineHandle;
use reth_chainspec::MAINNET;
use reth_consensus::noop::NoopConsensus;
use reth_engine_primitives::BeaconConsensusEngineHandle;
use reth_ethereum_engine_primitives::{EthEngineTypes, EthereumEngineValidator};
use reth_evm::execute::BasicBlockExecutorProvider;
use reth_evm_ethereum::{execute::EthExecutionStrategyFactory, EthEvmConfig};
Expand Down
1 change: 0 additions & 1 deletion crates/rpc/rpc-engine-api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ reth-chainspec.workspace = true
reth-primitives.workspace = true
reth-rpc-api.workspace = true
reth-storage-api.workspace = true
reth-beacon-consensus.workspace = true
reth-payload-builder.workspace = true
reth-payload-builder-primitives.workspace = true
reth-payload-primitives.workspace = true
Expand Down
3 changes: 1 addition & 2 deletions crates/rpc/rpc-engine-api/src/engine_api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ use alloy_rpc_types_engine::{
use async_trait::async_trait;
use jsonrpsee_core::RpcResult;
use parking_lot::Mutex;
use reth_beacon_consensus::BeaconConsensusEngineHandle;
use reth_chainspec::{EthereumHardforks, Hardforks};
use reth_engine_primitives::{EngineTypes, EngineValidator};
use reth_engine_primitives::{BeaconConsensusEngineHandle, EngineTypes, EngineValidator};
use reth_payload_builder::PayloadStore;
use reth_payload_primitives::{
validate_payload_timestamp, EngineApiMessageVersion, PayloadBuilderAttributes,
Expand Down
3 changes: 1 addition & 2 deletions crates/rpc/rpc-engine-api/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ use alloy_primitives::{B256, U256};
use jsonrpsee_types::error::{
INTERNAL_ERROR_CODE, INVALID_PARAMS_CODE, INVALID_PARAMS_MSG, SERVER_ERROR_MSG,
};
use reth_beacon_consensus::BeaconForkChoiceUpdateError;
use reth_engine_primitives::BeaconOnNewPayloadError;
use reth_engine_primitives::{BeaconForkChoiceUpdateError, BeaconOnNewPayloadError};
use reth_payload_builder_primitives::PayloadBuilderError;
use reth_payload_primitives::EngineObjectValidationError;
use thiserror::Error;
Expand Down

0 comments on commit fb69028

Please sign in to comment.