From 4e64b3fc78e733666bc14daf0f9a2882c2fd4d9a Mon Sep 17 00:00:00 2001 From: Angel Valkov Date: Fri, 3 Jan 2025 16:18:08 +0200 Subject: [PATCH] Debug logging --- consensus/bor/bor.go | 1 + consensus/bor/snapshot.go | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/consensus/bor/bor.go b/consensus/bor/bor.go index 959a9162bb..a963165dfe 100644 --- a/consensus/bor/bor.go +++ b/consensus/bor/bor.go @@ -1201,6 +1201,7 @@ func (c *Bor) FetchAndCommitSpan( ) if c.HeimdallClient == nil { + log.Error("Heimdall client is nil") // fixme: move to a new mock or fake and remove c.HeimdallClient completely s, err := c.getNextHeimdallSpanForTest(ctx, newSpanID, header, chain) if err != nil { diff --git a/consensus/bor/snapshot.go b/consensus/bor/snapshot.go index 87e3fb163c..459ce78707 100644 --- a/consensus/bor/snapshot.go +++ b/consensus/bor/snapshot.go @@ -4,6 +4,7 @@ import ( "encoding/json" "github.com/ethereum/go-ethereum/consensus/bor/valset" + "github.com/ethereum/go-ethereum/log" lru "github.com/hashicorp/golang-lru" @@ -152,7 +153,7 @@ func (s *Snapshot) apply(headers []*types.Header) (*Snapshot, error) { } validatorBytes := header.GetValidatorBytes(s.chainConfig) - + log.Error("ValidatorBytes", "headerNumber", header.Number.String(), "validatorBytes", validatorBytes) // get validators from headers and use that for new validator set newVals, _ := valset.ParseValidators(validatorBytes) v := getUpdatedValidatorSet(snap.ValidatorSet.Copy(), newVals)