Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wallet: log on rescan completion #15901

Merged
merged 2 commits into from
Apr 28, 2019

Conversation

andrewtoth
Copy link
Contributor

Currently there is nothing logged when a rescan completes successfully. This leaves the last log message something like:

 Still rescanning. At block 573037. Progress=0.998415

It is unclear when the rescan actually finished. This adds a Rescan completed. message to make it more clear.

Copy link
Member

@maflcko maflcko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK 9a5ca80

@@ -1862,6 +1862,8 @@ CWallet::ScanResult CWallet::ScanForWalletTransactions(const uint256& start_bloc
} else if (block_height && chain().shutdownRequested()) {
WalletLogPrintf("Rescan interrupted by shutdown request at block %d. Progress=%f\n", *block_height, progress_current);
result.status = ScanResult::USER_ABORT;
} else {
WalletLogPrintf("Rescan completed.\n");
}
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style-nit: Could add a commit to remove this scope (and the 4 extraneous spaces that precede the lines)?

Copy link
Contributor Author

@andrewtoth andrewtoth Apr 26, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the commit to do that, but the diff is pretty big.

@DrahtBot
Copy link
Contributor

DrahtBot commented Apr 26, 2019

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

Reviewers, this pull request conflicts with the following ones:

  • #15730 (rpc: Show scanning details in getwalletinfo by promag)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

@maflcko
Copy link
Member

maflcko commented Apr 26, 2019

Checked that the second commit is only removing a scope and whitespace.

utACK 34e78fd

Show signature
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

utACK 34e78fdcd985cf009b29911ce94e7560a063a681
-----BEGIN PGP SIGNATURE-----

iQGzBAEBCgAdFiEE+rVPoUahrI9sLGYTzit1aX5ppUgFAlwqrYAACgkQzit1aX5p
pUiAmQwApeg172htEwBZh4j0Wc17e9Hc0j/KLT2Lb4VEdE9z4IYrPpVVariSmRPP
fd/ZVWOu+8t3rwbcoq/tAXMPHJuElZ+isxyKK7huF0n4HepD5h8qc9HbvG8hLzEx
XP2hVNazJePrPF7LfUK1iawIseofe3i/FMQAaeInT+8Q0P/FDz8wU+7zFbJKFl6A
tRnGPERRtSS8PjNjm3NYkNDVHTRXYDQVka0sQb3WEqK/DyTFXKIxYDcbWUiwscJJ
DAv52Is5p5vTFZGMa7/hFmgL0pgEtE8gt47asmf7oE+yd3LdYvYcdG8AtI6CjpDO
eg67WVmqffuwV/nSPsf/DdYYYk0rEYRJmq+PzWvxpHfvmQKZH+cuiVvnOXR4FcnM
bmJprtrHSyvduKtksaGnu9EIT2I8GNqRtyIAlgLzEWQZjYlTUgVTZ4Vuo9fGMv3H
ym2Wr95VmGKQYOpuhwIMaqQpSeHqA8F4fPA6PZrhthK0zR4zXTCotLTfyNCKl8JS
PFHQv/Vm
=vukP
-----END PGP SIGNATURE-----

@maflcko maflcko added this to the 0.19.0 milestone Apr 26, 2019
@meshcollider
Copy link
Contributor

Concept ACK

@Empact
Copy link
Member

Empact commented Apr 27, 2019

nit: Looking at the callers, this one already logs the success:

walletInstance->WalletLogPrintf("Rescan completed in %15dms\n", GetTimeMillis() - nStart);

@andrewtoth
Copy link
Contributor Author

@Empact I removed the logging from that caller, and added the time check to the log for every caller.

@Empact
Copy link
Member

Empact commented Apr 27, 2019

utACK 1b602f6

1 similar comment
@meshcollider
Copy link
Contributor

utACK 1b602f6

@meshcollider meshcollider merged commit 1b602f6 into bitcoin:master Apr 28, 2019
meshcollider added a commit that referenced this pull request Apr 28, 2019
1b602f6 remove extraneous scope (andrewtoth)
6ad372a wallet: log on rescan completion (andrewtoth)

Pull request description:

  Currently there is nothing logged when a rescan completes successfully. This leaves the last log message something like:
  ```
   Still rescanning. At block 573037. Progress=0.998415
  ```
  It is unclear when the rescan actually finished. This adds a `Rescan completed.` message to make it more clear.

ACKs for commit 1b602f:
  Empact:
    utACK 1b602f6
  meshcollider:
    utACK 1b602f6

Tree-SHA512: 618d646a0f143c2372f1db91c14e7f677b39fb3a2957e887cbc349971c3e8953bc017e2028ac489368c20dbb9a7265c4c2d448c95de785366acfe0e576f1be66
@andrewtoth andrewtoth deleted the log-rescan-completed branch April 28, 2019 00:28
kwvg added a commit to kwvg/dash that referenced this pull request Dec 4, 2021
kwvg added a commit to kwvg/dash that referenced this pull request Dec 8, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
kwvg added a commit to kwvg/dash that referenced this pull request Dec 8, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
kwvg added a commit to kwvg/dash that referenced this pull request Dec 12, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
kwvg added a commit to kwvg/dash that referenced this pull request Dec 13, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
kwvg added a commit to kwvg/dash that referenced this pull request Dec 13, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
kwvg added a commit to kwvg/dash that referenced this pull request Dec 13, 2021
Co-authored-by: UdjinM6 <UdjinM6@users.noreply.github.com>
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Dec 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants