From 27889860f098f92a60b7e543d61c5c156aeecb44 Mon Sep 17 00:00:00 2001 From: ericsson Date: Wed, 16 Jun 2021 12:03:20 +0300 Subject: [PATCH] fix typo: sometimes `change()` invoked on `ShardWork` itself, should be invoked on its `status` field --- specs/sharding/beacon-chain.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/specs/sharding/beacon-chain.md b/specs/sharding/beacon-chain.md index 98feba22b..d57e97752 100644 --- a/specs/sharding/beacon-chain.md +++ b/specs/sharding/beacon-chain.md @@ -576,12 +576,12 @@ def update_pending_shard_work(state: BeaconState, attestation: Attestation) -> N # TODO In Altair: set participation bit flag for voters of this early winning header if pending_header.commitment == DataCommitment(): # The committee voted to not confirm anything - state.shard_buffer[buffer_index][attestation_shard].change( + state.shard_buffer[buffer_index][attestation_shard].status.change( selector=SHARD_WORK_UNCONFIRMED, value=None, ) else: - state.shard_buffer[buffer_index][attestation_shard].change( + state.shard_buffer[buffer_index][attestation_shard].status.change( selector=SHARD_WORK_CONFIRMED, value=pending_header.commitment, ) @@ -785,7 +785,7 @@ def reset_pending_shard_work(state: BeaconState) -> None: shard = (start_shard + committee_index) % active_shards # a committee is available, initialize a pending shard-header list committee_length = len(get_beacon_committee(state, slot, committee_index)) - state.shard_buffer[buffer_index][shard].change( + state.shard_buffer[buffer_index][shard].status.change( selector=SHARD_WORK_PENDING, value=List[PendingShardHeader, MAX_SHARD_HEADERS_PER_SHARD]( PendingShardHeader(