@@ -167,10 +167,10 @@ def get_new_recent_block_hashes(old_block_hashes: Sequence[Hash32],
167167
168168
169169#
170- # Get shards_and_committees or indices
170+ # Get shards_committees or indices
171171#
172172@to_tuple
173- def get_shards_and_committees_for_slot (
173+ def get_shards_committees_for_slot (
174174 crystallized_state : 'CrystallizedState' ,
175175 slot : int ,
176176 epoch_length : int ) -> Iterable [ShardCommittee ]:
@@ -204,13 +204,13 @@ def get_attestation_indices(crystallized_state: 'CrystallizedState',
204204 """
205205 shard_id = attestation .shard_id
206206
207- shards_and_committees_for_slot = get_shards_and_committees_for_slot (
207+ shards_committees_for_slot = get_shards_committees_for_slot (
208208 crystallized_state ,
209209 attestation .slot ,
210210 epoch_length ,
211211 )
212212
213- for shard_committee in shards_and_committees_for_slot :
213+ for shard_committee in shards_committees_for_slot :
214214 if shard_committee .shard_id == shard_id :
215215 yield from shard_committee .committee
216216
@@ -229,7 +229,7 @@ def get_active_validator_indices(validators: Sequence['ValidatorRecord']) -> Tup
229229# Shuffling
230230#
231231@to_tuple
232- def _get_shards_and_committees_for_shard_indices (
232+ def _get_shards_committees_for_shard_indices (
233233 shard_indices : Sequence [Sequence [int ]],
234234 start_shard : int ,
235235 total_validator_count : int ,
@@ -311,7 +311,7 @@ def get_new_shuffling(*,
311311 # Split the shuffled list into committees_per_slot pieces
312312 shard_indices = split (slot_indices , committees_per_slot )
313313 start_shard = crosslinking_start_shard + index * committees_per_slot
314- yield _get_shards_and_committees_for_shard_indices (
314+ yield _get_shards_committees_for_shard_indices (
315315 shard_indices ,
316316 start_shard ,
317317 active_validators_size ,
@@ -325,7 +325,7 @@ def get_new_shuffling(*,
325325def get_block_committees_info (parent_block : 'BaseBeaconBlock' ,
326326 crystallized_state : 'CrystallizedState' ,
327327 epoch_length : int ) -> BlockCommitteesInfo :
328- shards_and_committees = get_shards_and_committees_for_slot (
328+ shards_committees = get_shards_committees_for_slot (
329329 crystallized_state ,
330330 parent_block .slot_number ,
331331 epoch_length ,
@@ -337,9 +337,9 @@ def get_block_committees_info(parent_block: 'BaseBeaconBlock',
337337 # `proposer_index_in_committee` th attester in `shard_committee`
338338 # is the proposer of the parent block.
339339 try :
340- shard_committee = shards_and_committees [0 ]
340+ shard_committee = shards_committees [0 ]
341341 except IndexError :
342- raise ValueError ("shards_and_committees should not be empty." )
342+ raise ValueError ("shards_committees should not be empty." )
343343
344344 proposer_committee_size = len (shard_committee .committee )
345345 if proposer_committee_size <= 0 :
@@ -360,5 +360,5 @@ def get_block_committees_info(parent_block: 'BaseBeaconBlock',
360360 proposer_index_in_committee = proposer_index_in_committee ,
361361 proposer_shard_id = shard_committee .shard_id ,
362362 proposer_committee_size = proposer_committee_size ,
363- shards_and_committees = shards_and_committees ,
363+ shards_committees = shards_committees ,
364364 )
0 commit comments