mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-25 12:57:18 +00:00
fix bad root (#6096)
This commit is contained in:
parent
7429221f3f
commit
75aaa5e07b
@ -67,7 +67,22 @@ func BlockBodyRoot(body *ethpb.BeaconBlockBody) ([32]byte, error) {
|
||||
if body == nil {
|
||||
// Treat nil body to be the same as empty. This is mostly for test setup purposes and would
|
||||
// be very unlikely to happen in production workflow.
|
||||
return [32]byte{117, 149, 118, 243, 29, 85, 147, 152, 201, 11, 234, 19, 146, 229, 35, 209, 93, 246, 109, 242, 141, 181, 176, 126, 79, 196, 1, 189, 124, 203, 199, 62}, nil
|
||||
emptyRoot := make([]byte, 32)
|
||||
emptyRandao := make([]byte, 96)
|
||||
body = ðpb.BeaconBlockBody{
|
||||
RandaoReveal: emptyRandao,
|
||||
Eth1Data: ðpb.Eth1Data{
|
||||
DepositRoot: emptyRoot,
|
||||
DepositCount: 0,
|
||||
BlockHash: emptyRoot,
|
||||
},
|
||||
Graffiti: emptyRoot,
|
||||
ProposerSlashings: make([]*ethpb.ProposerSlashing, 0),
|
||||
AttesterSlashings: make([]*ethpb.AttesterSlashing, 0),
|
||||
Attestations: make([]*ethpb.Attestation, 0),
|
||||
Deposits: make([]*ethpb.Deposit, 0),
|
||||
VoluntaryExits: make([]*ethpb.SignedVoluntaryExit, 0),
|
||||
}
|
||||
}
|
||||
hasher := hashutil.CustomSHA256Hasher()
|
||||
fieldRoots := make([][32]byte, 8)
|
||||
|
Loading…
Reference in New Issue
Block a user