[Bitcoin-development] Wallet related bug?

grarpamp grarpamp at gmail.com
Fri Jun 22 11:01:19 UTC 2012

I think there may be an ideal order of ops bug around rescan,
wallet upgrades/import and last block markers.

I dropped an old wallet in a current blockchain.

First ran - in rescan mode.
It said old walletver.
Then rescanned whole chain.
AddToWallet some blockhash, blocks out of range, invalid/nonwallet txid's,
which were already in there as legit ones in the old logs.

Second run in plain mode.
New wallet ver logged.
Rescanned  the last 20k blocks or so,
which might have been the marker last time the old wallet was used.

Third and later runs... duplicates the second.

Never did say 'upgrading wallet' as it sometimes does.

Running detach=1 always.

Why scan the last 20k every time? Shouldn't have to if
whole chain was scanned. And certainly no more than
once if not.

Dumping the run params (bitcoin.conf, cmdline) to the log would be good.

And not automatically truncate the log when big but just append or roll it.

More information about the bitcoin-dev mailing list