From 8b18568baeb0e9d55d71e43c847e63ad27d20afc Mon Sep 17 00:00:00 2001 From: Cassandra Heart Date: Wed, 13 Nov 2024 14:51:41 -0600 Subject: [PATCH] the mystery of 6% --- node/consensus/data/message_handler.go | 2 +- node/consensus/data/prover_lookup.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/node/consensus/data/message_handler.go b/node/consensus/data/message_handler.go index c6dd9a3..93775cb 100644 --- a/node/consensus/data/message_handler.go +++ b/node/consensus/data/message_handler.go @@ -211,7 +211,7 @@ func (e *DataClockConsensusEngine) handleClockFrame( } trie := e.GetFrameProverTries()[0] - if !trie.Contains(addr.Bytes()) { + if !trie.Contains(addr.FillBytes(make([]byte, 32))) { e.logger.Debug( "prover not in trie at frame, address may be in fork", zap.Binary("address", address), diff --git a/node/consensus/data/prover_lookup.go b/node/consensus/data/prover_lookup.go index 860d65f..8f9ddc3 100644 --- a/node/consensus/data/prover_lookup.go +++ b/node/consensus/data/prover_lookup.go @@ -56,7 +56,7 @@ func (e *DataClockConsensusEngine) IsInProverTrie(key []byte) bool { return false } - provingKeyAddress := h.Bytes() + provingKeyAddress := h.FillBytes(make([]byte, 32)) for _, tries := range e.GetFrameProverTries() { if tries.Contains(provingKeyAddress) { return true