fix bug with _epochs_until_leak helper

This commit is contained in:
Alex Stokes
2021-08-22 09:59:28 -07:00
parent 820affd2aa
commit 270814e20f

View File

@@ -61,7 +61,11 @@ def _randomize_state(spec, state):
## epochs
def _epochs_until_leak(spec):
return spec.MIN_EPOCHS_TO_INACTIVITY_PENALTY
"""
State is "leaking" if the current epoch is at least
this value after the last finalized epoch.
"""
return spec.MIN_EPOCHS_TO_INACTIVITY_PENALTY + 1
def _epochs_for_shard_committee_period(spec):