mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-02-14 15:05:16 -05:00
fix weight
This commit is contained in:
@@ -319,7 +319,7 @@ func (f *ForkChoice) updateNewFullNodeWeight(fn *PayloadNode) {
|
||||
fn.balance += f.balances[index]
|
||||
}
|
||||
}
|
||||
fn.balance = fn.weight
|
||||
fn.weight = fn.balance
|
||||
}
|
||||
|
||||
func (s *Store) resolveVoteNode(r [32]byte, slot primitives.Slot, payloadStatus bool) (*PayloadNode, bool) {
|
||||
|
||||
@@ -141,7 +141,8 @@ func (bb *Builder) Check(t testing.TB, c *Check) {
|
||||
if c.Head != nil {
|
||||
r, err := bb.service.HeadRoot(ctx)
|
||||
require.NoError(t, err)
|
||||
require.Equal(t, true, bytes.Equal(common.FromHex(c.Head.Root), r))
|
||||
wantedRoot := common.FromHex(c.Head.Root)
|
||||
require.Equal(t, true, bytes.Equal(wantedRoot, r), fmt.Sprintf("Roots differ. wanted %#x, got %#x", wantedRoot, r))
|
||||
require.Equal(t, primitives.Slot(c.Head.Slot), bb.service.HeadSlot())
|
||||
}
|
||||
if c.JustifiedCheckPoint != nil {
|
||||
|
||||
Reference in New Issue
Block a user