Skip to content

Commit

Permalink
Merge branch 'main' into rkrasiuk/desired-block-gas-limit
Browse files Browse the repository at this point in the history
  • Loading branch information
rkrasiuk authored Dec 12, 2024
2 parents bd6f227 + c339811 commit 31f9fcc
Show file tree
Hide file tree
Showing 35 changed files with 762 additions and 415 deletions.
32 changes: 17 additions & 15 deletions Cargo.lock

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

10 changes: 5 additions & 5 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -477,11 +477,11 @@ alloy-transport-ipc = { version = "0.8.0", default-features = false }
alloy-transport-ws = { version = "0.8.0", default-features = false }

# op
op-alloy-rpc-types = "0.8.0"
op-alloy-rpc-types-engine = "0.8.0"
op-alloy-rpc-jsonrpsee = "0.8.0"
op-alloy-network = "0.8.0"
op-alloy-consensus = "0.8.0"
op-alloy-rpc-types = "0.8.1"
op-alloy-rpc-types-engine = "0.8.1"
op-alloy-rpc-jsonrpsee = "0.8.1"
op-alloy-network = "0.8.1"
op-alloy-consensus = "0.8.1"

# misc
aquamarine = "0.6"
Expand Down
2 changes: 1 addition & 1 deletion crates/ethereum/payload/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ reth-primitives.workspace = true
reth-primitives-traits.workspace = true
reth-revm.workspace = true
reth-transaction-pool.workspace = true
reth-provider.workspace = true
reth-payload-builder.workspace = true
reth-storage-api.workspace = true
reth-payload-builder-primitives.workspace = true
reth-payload-primitives.workspace = true
reth-execution-types.workspace = true
Expand Down
4 changes: 2 additions & 2 deletions crates/ethereum/payload/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use reth_basic_payload_builder::{
PayloadConfig,
};
use reth_chain_state::ExecutedBlock;
use reth_chainspec::ChainSpec;
use reth_chainspec::{ChainSpec, ChainSpecProvider};
use reth_errors::RethError;
use reth_evm::{system_calls::SystemCaller, ConfigureEvm, NextBlockEnvAttributes};
use reth_evm_ethereum::{eip6110::parse_deposits_from_receipts, EthEvmConfig};
Expand All @@ -33,7 +33,6 @@ use reth_primitives::{
Block, BlockBody, BlockExt, EthereumHardforks, InvalidTransactionError, Receipt,
TransactionSigned,
};
use reth_provider::{ChainSpecProvider, StateProviderFactory};
use reth_revm::database::StateProviderDatabase;
use reth_transaction_pool::{
error::InvalidPoolTransactionError, noop::NoopTransactionPool, BestTransactions,
Expand All @@ -52,6 +51,7 @@ use tracing::{debug, trace, warn};

mod config;
pub use config::*;
use reth_storage_api::StateProviderFactory;

type BestTransactionsIter<Pool> = Box<
dyn BestTransactions<Item = Arc<ValidPoolTransaction<<Pool as TransactionPool>::Transaction>>>,
Expand Down
26 changes: 25 additions & 1 deletion crates/net/network/src/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,37 @@ use tokio_stream::wrappers::UnboundedReceiverStream;
use tracing::{debug, error, trace, warn};

#[cfg_attr(doc, aquamarine::aquamarine)]
// TODO: Inlined diagram due to a bug in aquamarine library, should become an include when it's
// fixed. See https://github.com/mersinvald/aquamarine/issues/50
// include_mmd!("docs/mermaid/network-manager.mmd")
/// Manages the _entire_ state of the network.
///
/// This is an endless [`Future`] that consistently drives the state of the entire network forward.
///
/// The [`NetworkManager`] is the container type for all parts involved with advancing the network.
///
/// include_mmd!("docs/mermaid/network-manager.mmd")
/// ```mermaid
/// graph TB
/// handle(NetworkHandle)
/// events(NetworkEvents)
/// transactions(Transactions Task)
/// ethrequest(ETH Request Task)
/// discovery(Discovery Task)
/// subgraph NetworkManager
/// direction LR
/// subgraph Swarm
/// direction TB
/// B1[(Session Manager)]
/// B2[(Connection Lister)]
/// B3[(Network State)]
/// end
/// end
/// handle <--> |request response channel| NetworkManager
/// NetworkManager --> |Network events| events
/// transactions <--> |transactions| NetworkManager
/// ethrequest <--> |ETH request handing| NetworkManager
/// discovery --> |Discovered peers| NetworkManager
/// ```
#[derive(Debug)]
#[must_use = "The NetworkManager does nothing unless polled"]
pub struct NetworkManager<N: NetworkPrimitives = EthNetworkPrimitives> {
Expand Down
11 changes: 8 additions & 3 deletions crates/optimism/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ workspace = true
reth-primitives.workspace = true
reth-primitives-traits = { workspace = true, features = ["op"] }
reth-codecs = { workspace = true, optional = true, features = ["op"] }
reth-zstd-compressors = { workspace = true, optional = true }

# ethereum
alloy-primitives.workspace = true
Expand All @@ -30,6 +31,7 @@ op-alloy-consensus.workspace = true

# codec
bytes = { workspace = true, optional = true }
modular-bitfield = { workspace = true, optional = true }
serde = { workspace = true, optional = true }

# misc
Expand Down Expand Up @@ -59,9 +61,10 @@ std = [
"serde?/std",
"bytes?/std",
"derive_more/std",
"revm-primitives/std",
"secp256k1?/std",
"alloy-rlp/std",
"revm-primitives/std",
"secp256k1?/std",
"alloy-rlp/std",
"reth-zstd-compressors?/std"
]
reth-codec = [
"dep:reth-codecs",
Expand All @@ -74,6 +77,8 @@ reth-codec = [
"reth-codecs?/op",
"reth-primitives/reth-codec",
"dep:bytes",
"dep:modular-bitfield",
"dep:reth-zstd-compressors"
]
serde = [
"dep:serde",
Expand Down
5 changes: 4 additions & 1 deletion crates/optimism/primitives/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ extern crate alloc;
pub mod bedrock;
pub mod transaction;

pub use transaction::{signed::OpTransactionSigned, tx_type::OpTxType, OpTransaction};
pub use transaction::{signed::OpTransactionSigned, tx_type::OpTxType};

mod receipt;
pub use receipt::OpReceipt;

/// Optimism primitive types.
pub type OpPrimitives = reth_primitives::EthPrimitives;
Expand Down
Loading

0 comments on commit 31f9fcc

Please sign in to comment.