Expected behavior
getblockchaininfo.initialblockdownload stays true until all blocks are imported
Actual behavior
getblockchaininfo.initialblockdownload
becomes false before before all blocks are imported:
02022-11-01T11:16:39Z UpdateTip: new best=00000000000000000006f01ad0649cefc26c86c24a2808109c584bdcdc0d5293 height=761091 version=0x20f0c000 log2_work=93.816484 tx=776463417 date='2022-10-31T11:13:46Z' progress=0.999730 cache=338.3MiB(2269631txo)
12022-11-01T11:16:39Z Leaving InitialBlockDownload (latching to false)
22022-11-01T11:16:42Z UpdateTip: new best=000000000000000000078315da1efb6937a0d06015891b0412164dc2531e3004 height=761092 version=0x20c00000 log2_work=93.816497 tx=776466523 date='2022-10-31T11:29:40Z' progress=0.999733 cache=338.7MiB(2273000txo)
3<snip 162 lines of UpdateTip>
42022-11-01T11:16:57Z UpdateTip: new best=00000000000000000004656d346fbac96ddcec6ee31b6abd696a241cd6994181 height=761255 version=0x2e4a6000 log2_work=93.818629 tx=776748676 date='2022-11-01T11:09:42Z' progress=0.999999 cache=375.6MiB(2573669txo)
Observe the 15 seconds it took my (reasonably fast) machine to import the remaining blocks. This is a problem for me since my application relies on this field to determine if syncing is complete. We can not rely on getblockchaininfo.verificationprogress
either due to #26433
To reproduce
Start a node that hasn’t been synced in a while and observe the log output.
System information
Observed on version 22 from the website.