diff --git a/beacon_node/beacon_chain/src/beacon_chain.rs b/beacon_node/beacon_chain/src/beacon_chain.rs index 161eac2a25..c050077094 100644 --- a/beacon_node/beacon_chain/src/beacon_chain.rs +++ b/beacon_node/beacon_chain/src/beacon_chain.rs @@ -74,6 +74,7 @@ pub enum BlockProcessingOutcome { #[derive(Debug, PartialEq)] pub enum AttestationProcessingOutcome { Processed, + EmptyAggregationBitfield, UnknownHeadBlock { beacon_block_root: Hash256, }, @@ -692,6 +693,10 @@ impl BeaconChain { metrics::inc_counter(&metrics::ATTESTATION_PROCESSING_REQUESTS); let timer = metrics::start_timer(&metrics::ATTESTATION_PROCESSING_TIMES); + if attestation.aggregation_bits.num_set_bits() == 0 { + return Ok(AttestationProcessingOutcome::EmptyAggregationBitfield); + } + // From the store, load the attestation's "head block". // // An honest validator would have set this block to be the head of the chain (i.e., the