fix argument typing for auxilary transition func

This commit is contained in:
protolambda 2019-04-15 23:37:13 +10:00
parent dba7a1890b
commit c3d321ada8
No known key found for this signature in database
GPG Key ID: EC89FDBB2B4C7623
1 changed files with 2 additions and 1 deletions

View File

@ -10,6 +10,7 @@ from typing import (
from .spec import ( from .spec import (
BeaconState, BeaconState,
BeaconBlock, BeaconBlock,
Slot
) )
@ -98,7 +99,7 @@ def process_epoch_transition(state: BeaconState) -> None:
spec.finish_epoch_update(state) spec.finish_epoch_update(state)
def state_transition_to(state: BeaconState, up_to: int) -> BeaconState: def state_transition_to(state: BeaconState, up_to: Slot) -> BeaconState:
while state.slot < up_to: while state.slot < up_to:
spec.cache_state(state) spec.cache_state(state)
if (state.slot + 1) % spec.SLOTS_PER_EPOCH == 0: if (state.slot + 1) % spec.SLOTS_PER_EPOCH == 0: