miner: fix inconsistent time unit, close XFN-59 (#1633)

This commit is contained in:
Daniel Liu 2025-11-03 17:23:10 +08:00 committed by benjamin202410
parent 5fa42ea2d0
commit 7032e9f8ed

View file

@ -388,7 +388,7 @@ func getResetTime(chain *core.BlockChain, minePeriod int) time.Duration {
if resetTime > minePeriodDuration || resetTime <= 0 { if resetTime > minePeriodDuration || resetTime <= 0 {
resetTime = minePeriodDuration resetTime = minePeriodDuration
} }
log.Debug("[update] Miner worker timer reset", "resetMilliseconds", resetTime.Milliseconds(), "minePeriodSec", minePeriod, "currentBlockTimeSec", fmt.Sprintf("%d", currentBlockTime), "currentSystemTimeSec", fmt.Sprintf("%d.%03d", nowTime/1000, nowTime%1000)) log.Debug("[update] Miner worker timer reset", "resetTimeSec", resetTime.Seconds(), "minePeriodSec", minePeriod, "currentBlockTimeSec", fmt.Sprintf("%d", currentBlockTime), "currentSystemTimeSec", fmt.Sprintf("%d.%03d", nowTime/1000, nowTime%1000))
return resetTime return resetTime
} }