Skip to content

Commit

Permalink
miner: Improve a couple of log messages.
Browse files Browse the repository at this point in the history
  • Loading branch information
davecgh authored and jholdstock committed Oct 9, 2023
1 parent a8faa5a commit 8eb243a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions cmd/miner/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -303,8 +303,9 @@ func (m *Miner) process(ctx context.Context) {
continue
}

log.Tracef("subscription details: %s, %s, %d",
notifyID, extraNonce1E, extraNonce2Size)
log.Tracef("Subscription details (notifyID: %s, "+
"extraNonce1: %s, extraNonce2Size: %d)", notifyID,
extraNonce1E, extraNonce2Size)

m.extraNonce1E = extraNonce1E
m.extraNonce2Size = extraNonce2Size
Expand Down
4 changes: 2 additions & 2 deletions cmd/miner/cpuminer.go
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,8 @@ func (m *CPUMiner) solveBlock(ctx context.Context, headerB []byte, target *big.R
m.workData.extraNonce2 = extraNonce2

m.updateHashes <- hashesCompleted
log.Infof("Solved block hash at height (%v) is (%v)",
header.Height, header.BlockHash().String())
log.Infof("Found hash at height %d with work below target!"+
" (pow hash %v)", header.Height, hash)
return true
}

Expand Down

0 comments on commit 8eb243a

Please sign in to comment.