diff --git a/specs/core/1_shard-data-chains.md b/specs/core/1_shard-data-chains.md index 2045c7a7e..a31f16880 100644 --- a/specs/core/1_shard-data-chains.md +++ b/specs/core/1_shard-data-chains.md @@ -384,11 +384,6 @@ def process_shard_attestations(beacon_state: BeaconState, shard_state: ShardStat pubkeys.append(beacon_state.validators[validator_index].pubkey) process_delta(beacon_state, shard_state, validator_index, get_base_reward(beacon_state, validator_index)) attestation_count += 1 - # Exit early if no participants - if not any(pubkeys): - assert block.attestations == BLSSignature() - return - # Verify there are no extraneous bits set beyond the shard committee for i in range(len(shard_committee), 2 * MAX_PERIOD_COMMITTEE_SIZE): assert block.aggregation_bits[i] == 0b0 diff --git a/test_libs/pyspec/eth2spec/test/helpers/phase1/shard_block.py b/test_libs/pyspec/eth2spec/test/helpers/phase1/shard_block.py index a339a0e70..834adc93f 100644 --- a/test_libs/pyspec/eth2spec/test/helpers/phase1/shard_block.py +++ b/test_libs/pyspec/eth2spec/test/helpers/phase1/shard_block.py @@ -66,13 +66,16 @@ def build_empty_shard_block(spec, (True,) * len(shard_committee) + (False,) * (spec.MAX_PERIOD_COMMITTEE_SIZE * 2 - len(shard_committee)) ) - block.attestations = sign_shard_attestation( - spec, - beacon_state, - shard_state, - block, - participants=shard_committee, - ) + else: + shard_committee = [] + + block.attestations = sign_shard_attestation( + spec, + beacon_state, + shard_state, + block, + participants=shard_committee, + ) if signed: sign_shard_block(spec, beacon_state, shard_state, block)