diff --git a/.changelog/odd-birds-meow.md b/.changelog/odd-birds-meow.md new file mode 100644 index 00000000000..8190670f145 --- /dev/null +++ b/.changelog/odd-birds-meow.md @@ -0,0 +1,6 @@ +--- +reth-engine-local: patch +reth-node-builder: patch +--- + +Removed the `op` feature flag and `OpPayloadAttributes` `PayloadAttributesBuilder` implementation from `reth-engine-local`, along with the `op-alloy-rpc-types-engine` dependency. Updated `reth-node-builder` to no longer enable the removed `op` feature on `reth-engine-local`. diff --git a/Cargo.lock b/Cargo.lock index e697254b56f..5c614988418 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -8280,7 +8280,6 @@ dependencies = [ "alloy-rpc-types-engine", "eyre", "futures-util", - "op-alloy-rpc-types-engine", "reth-chainspec", "reth-engine-primitives", "reth-ethereum-engine-primitives", diff --git a/crates/engine/local/Cargo.toml b/crates/engine/local/Cargo.toml index 9cac2d3de11..ef21721f512 100644 --- a/crates/engine/local/Cargo.toml +++ b/crates/engine/local/Cargo.toml @@ -32,12 +32,6 @@ futures-util.workspace = true # misc eyre.workspace = true tracing.workspace = true -op-alloy-rpc-types-engine = { workspace = true, optional = true } [lints] workspace = true - -[features] -op = [ - "dep:op-alloy-rpc-types-engine", -] diff --git a/crates/engine/local/src/payload.rs b/crates/engine/local/src/payload.rs index 1b0c9704c3d..304de1ebcb2 100644 --- a/crates/engine/local/src/payload.rs +++ b/crates/engine/local/src/payload.rs @@ -60,56 +60,3 @@ where } } } - -#[cfg(feature = "op")] -impl - PayloadAttributesBuilder - for LocalPayloadAttributesBuilder -where - ChainSpec: EthChainSpec + EthereumHardforks + 'static, -{ - fn build( - &self, - parent: &SealedHeader, - ) -> op_alloy_rpc_types_engine::OpPayloadAttributes { - use alloy_primitives::B64; - use reth_chainspec::BaseFeeParams; - use std::env; - /// Dummy system transaction for dev mode. - /// OP Mainnet transaction at index 0 in block 124665056. - /// - /// - const TX_SET_L1_BLOCK_OP_MAINNET_BLOCK_124665056: [u8; 251] = alloy_primitives::hex!( - "7ef8f8a0683079df94aa5b9cf86687d739a60a9b4f0835e520ec4d664e2e415dca17a6df94deaddeaddeaddeaddeaddeaddeaddeaddead00019442000000000000000000000000000000000000158080830f424080b8a4440a5e200000146b000f79c500000000000000040000000066d052e700000000013ad8a3000000000000000000000000000000000000000000000000000000003ef1278700000000000000000000000000000000000000000000000000000000000000012fdf87b89884a61e74b322bbcf60386f543bfae7827725efaaf0ab1de2294a590000000000000000000000006887246668a3b87f54deb3b94ba47a6f63f32985" - ); - - // Configure EIP-1559 parameters for dev mode. These can be overridden via environment - // variables (OP_DEV_EIP1559_DENOMINATOR, OP_DEV_EIP1559_ELASTICITY, OP_DEV_GAS_LIMIT), - // otherwise defaults from Optimism's BaseFeeParams are used. The parameters are encoded - // as an 8-byte value (denominator + elasticity) required by Optimism's Jovian fork. - let default_eip_1559_params = BaseFeeParams::optimism(); - let denominator = env::var("OP_DEV_EIP1559_DENOMINATOR") - .ok() - .and_then(|v| v.parse::().ok()) - .unwrap_or(default_eip_1559_params.max_change_denominator as u32); - let elasticity = env::var("OP_DEV_EIP1559_ELASTICITY") - .ok() - .and_then(|v| v.parse::().ok()) - .unwrap_or(default_eip_1559_params.elasticity_multiplier as u32); - let gas_limit = env::var("OP_DEV_GAS_LIMIT").ok().and_then(|v| v.parse::().ok()); - - let mut eip1559_bytes = [0u8; 8]; - eip1559_bytes[0..4].copy_from_slice(&denominator.to_be_bytes()); - eip1559_bytes[4..8].copy_from_slice(&elasticity.to_be_bytes()); - let eip_1559_params = Some(B64::from(eip1559_bytes)); - - op_alloy_rpc_types_engine::OpPayloadAttributes { - payload_attributes: self.build(parent), - transactions: Some(vec![TX_SET_L1_BLOCK_OP_MAINNET_BLOCK_124665056.into()]), - no_tx_pool: None, - gas_limit, - eip_1559_params, - min_base_fee: Some(0), - } - } -} diff --git a/crates/node/builder/Cargo.toml b/crates/node/builder/Cargo.toml index 638c50f451f..12110e161b2 100644 --- a/crates/node/builder/Cargo.toml +++ b/crates/node/builder/Cargo.toml @@ -123,6 +123,5 @@ test-utils = [ ] trie-debug = ["reth-engine-tree/trie-debug"] op = [ - "reth-engine-local/op", "reth-evm/op", ]