mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-02 09:46:14 +00:00
Merge bitcoin/bitcoin#31616: init,log: Unify block index log line
e04be3731f4921cd51d25b1d6210eace7600fea4 init,log: Unify block index and chainstate loading log line (Lőrinc)
Pull request description:
The line has been present since the beginning.
Removed redundant duration as well since it can be recovered from the timestamps.
Example logs before the change:
```
2025-01-07T11:58:33Z Verification progress: 99%
2025-01-07T11:58:33Z Verification: No coin database inconsistencies in last 6 blocks (18905 transactions)
2025-01-07T11:58:33Z block index 31892ms
2025-01-07T11:58:33Z Setting NODE_NETWORK on non-prune mode
```
ACKs for top commit:
maflcko:
lgtm ACK e04be3731f4921cd51d25b1d6210eace7600fea4
TheCharlatan:
ACK e04be3731f4921cd51d25b1d6210eace7600fea4
danielabrozzoni:
tACK e04be3731f4921cd51d25b1d6210eace7600fea4
BrandonOdiwuor:
Code Review ACK e04be3731f4921cd51d25b1d6210eace7600fea4
Tree-SHA512: cbe4569a17f56ff23e829b837a083c2f730cc490b47bee3bac12126e2257e0ba9ebe9b4384deb03203a0a60aac3b8d283c5d31a6d0481635ba011ac6e2c61ad1
This commit is contained in:
commit
528354e213
@ -1245,7 +1245,6 @@ static ChainstateLoadResult InitAndLoadChainstate(
|
||||
"", CClientUIInterface::MSG_ERROR);
|
||||
};
|
||||
uiInterface.InitMessage(_("Loading block index…").translated);
|
||||
const auto load_block_index_start_time{SteadyClock::now()};
|
||||
auto catch_exceptions = [](auto&& f) {
|
||||
try {
|
||||
return f();
|
||||
@ -1263,7 +1262,7 @@ static ChainstateLoadResult InitAndLoadChainstate(
|
||||
}
|
||||
std::tie(status, error) = catch_exceptions([&] { return VerifyLoadedChainstate(chainman, options); });
|
||||
if (status == node::ChainstateLoadStatus::SUCCESS) {
|
||||
LogPrintf(" block index %15dms\n", Ticks<std::chrono::milliseconds>(SteadyClock::now() - load_block_index_start_time));
|
||||
LogInfo("Block index and chainstate loaded");
|
||||
}
|
||||
}
|
||||
return {status, error};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user