Skip to content

Commit

Permalink
Merge pull request #3658 from ethereum/mkalinin-patch-6
Browse files Browse the repository at this point in the history
EIP-7251: Fix has_sufficient_effective_balance computation
  • Loading branch information
ralexstokes committed Apr 7, 2024
2 parents b18bbd8 + 64da0da commit e6092db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion specs/_features/eip7251/beacon-chain.md
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ def get_expected_withdrawals(state: BeaconState) -> Tuple[Sequence[Withdrawal],
break

validator = state.validators[withdrawal.index]
has_sufficient_effective_balance = validator.effective_balance == MIN_ACTIVATION_BALANCE
has_sufficient_effective_balance = validator.effective_balance >= MIN_ACTIVATION_BALANCE
has_excess_balance = state.balances[withdrawal.index] > MIN_ACTIVATION_BALANCE
if validator.exit_epoch == FAR_FUTURE_EPOCH and has_sufficient_effective_balance and has_excess_balance:
withdrawable_balance = min(state.balances[withdrawal.index] - MIN_ACTIVATION_BALANCE, withdrawal.amount)
Expand Down

0 comments on commit e6092db

Please sign in to comment.