From 48dd3f385cd3ecde1baeb9135815f376d79b048a Mon Sep 17 00:00:00 2001 From: Pawan Dhananjay Date: Mon, 7 Oct 2024 09:35:38 -0700 Subject: [PATCH] Filter out BlsToExecutionChange messages for 0x02 validators (#6464) * Filter out 0x02 validators from `get_bls_to_execution_changes` * Prune bls to execution changes that have a 0x02 credential * lint --- beacon_node/operation_pool/src/bls_to_execution_changes.rs | 2 +- beacon_node/operation_pool/src/lib.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/beacon_node/operation_pool/src/bls_to_execution_changes.rs b/beacon_node/operation_pool/src/bls_to_execution_changes.rs index 07fd72f02c5..cbab97e7199 100644 --- a/beacon_node/operation_pool/src/bls_to_execution_changes.rs +++ b/beacon_node/operation_pool/src/bls_to_execution_changes.rs @@ -113,7 +113,7 @@ impl BlsToExecutionChanges { .validators() .get(validator_index as usize) .map_or(true, |validator| { - let prune = validator.has_eth1_withdrawal_credential(spec) + let prune = validator.has_execution_withdrawal_credential(spec) && head_block .message() .body() diff --git a/beacon_node/operation_pool/src/lib.rs b/beacon_node/operation_pool/src/lib.rs index e6a61edc098..0b032b0c8a7 100644 --- a/beacon_node/operation_pool/src/lib.rs +++ b/beacon_node/operation_pool/src/lib.rs @@ -585,7 +585,7 @@ impl OperationPool { && state .get_validator(address_change.as_inner().message.validator_index as usize) .map_or(false, |validator| { - !validator.has_eth1_withdrawal_credential(spec) + !validator.has_execution_withdrawal_credential(spec) }) }, |address_change| address_change.as_inner().clone(),