Skip to content

Commit

Permalink
Support Electra for WriteBlockChunk (#13999)
Browse files Browse the repository at this point in the history
  • Loading branch information
terencechain authored and nisdas committed Jun 19, 2024
1 parent 17dab11 commit 9d8558e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions beacon-chain/sync/rpc_chunked_response.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,12 @@ func WriteBlockChunk(stream libp2pcore.Stream, tor blockchain.TemporalOracle, en
return err
}
obtainedCtx = digest[:]
case version.Electra:
digest, err := forks.ForkDigestFromEpoch(params.BeaconConfig().ElectraForkEpoch, valRoot[:])
if err != nil {
return err
}
obtainedCtx = digest[:]
default:
return errors.Wrapf(ErrUnrecognizedVersion, "block version %d is not recognized", blk.Version())
}
Expand Down

0 comments on commit 9d8558e

Please sign in to comment.