Skip to content

Commit

Permalink
Better out-of-scope coinbase error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
jdowning100 committed Jun 20, 2023
1 parent a8e6361 commit 8e31ff0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions consensus/blake3pow/consensus.go
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header

coinbase, err := header.Coinbase().InternalAddress()
if err != nil {
fmt.Println("Block has out-of-scope coinbase, skipping block reward: " + header.Hash().String())
log.Error("Block has out of scope coinbase, skipping block reward", "Address", header.Coinbase().String(), "Hash", header.Hash().String())
return
}

Expand All @@ -489,7 +489,7 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header
for _, uncle := range uncles {
coinbase, err := uncle.Coinbase().InternalAddress()
if err != nil {
fmt.Println("Found uncle with out-of-scope coinbase, skipping reward: " + uncle.Hash().String())
log.Error("Found uncle with out of scope coinbase, skipping reward", "Address", uncle.Coinbase().String(), "Hash", uncle.Hash().String())
continue
}
r.Add(uncle.Number(), big8)
Expand Down

0 comments on commit 8e31ff0

Please sign in to comment.