Skip to content

Conversation

@random-zebra
Copy link

@random-zebra random-zebra commented Mar 30, 2021

Based on top of

Keep going down the rabbit hole...
Fix and resurrect wallet_import_rescan functional test.

@random-zebra random-zebra added this to the 6.0.0 milestone Mar 30, 2021
@random-zebra random-zebra self-assigned this Mar 30, 2021
@random-zebra random-zebra changed the title 202103 wallet import rescan [RPC][Test] Fix wallet_import_rescan Mar 30, 2021
@random-zebra random-zebra force-pushed the 202103_wallet_import_rescan branch 2 times, most recently from 3fbd0af to 60f2eb8 Compare March 31, 2021 19:32
@furszy
Copy link

furszy commented Apr 6, 2021

Can be rebased now.

@random-zebra random-zebra force-pushed the 202103_wallet_import_rescan branch from 60f2eb8 to 8d2be78 Compare April 7, 2021 09:11
@random-zebra
Copy link
Author

Rebased.

furszy
furszy previously approved these changes Apr 8, 2021
Copy link

@furszy furszy left a comment

Choose a reason for hiding this comment

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

Code review ACK 9a8e3642089d29e3eb1ebeab3a7e6b7a2d2c1bcb .

The wallet_basic.py test failing isn't for the changes introduced here.
We should try to replicate it in #2261 that has some changes to scope the issue down to one line.
Based on the convos that we had, would be good to push there a way to run the test N amounts of times in a loop until it fails.

Copy link
Collaborator

@Fuzzbawls Fuzzbawls left a comment

Choose a reason for hiding this comment

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

Functional ACK, just need to clean up a duplicate help message line

`coinControl->fAllowWatchOnly` should only affect the spendability of a
coin. A wo script is spendable if it is solvable and fAllowWatchOnly is
true.
When fAllowWatchOnly is false, the coin should not be skipped in
CheckOutputAvailability, but included as non-spendable, and then skipped
in AvailableCoins when `coinsFilter.fOnlySpendable` is true.
>>> backports bitcoin/bitcoin@99464bc

The use of mocktime in test logic means that comparisons between
GetTime() and GetTimeMicros()/1000000 are unreliable since the former
can use mocktime values while the latter always gets the system clock;
this changes the networking code's inactivity checks to consistently
use the system clock for inactivity comparisons.

Also remove some hacks from setmocktime() that are no longer needed,
now that we're using the system clock for nLastSend and nLastRecv.
Copy link

@furszy furszy left a comment

Choose a reason for hiding this comment

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

re-utACK 465d1eb

Copy link
Collaborator

@Fuzzbawls Fuzzbawls left a comment

Choose a reason for hiding this comment

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

ACK 465d1eb

@random-zebra random-zebra merged commit 91dc7f1 into PIVX-Project:master Apr 11, 2021
furszy added a commit that referenced this pull request Apr 13, 2021
…ng RescanFromTime

1cde8b4 [Trivial] Fix some comment/output: 'bitcoind' --> 'pivxd' (random-zebra)
29c267e Mention that other RPC calls report keys as "imported" while txns are still missing (Jonas Schnelli)
f773203 Reduce cs_main lock in ReadBlockFromDisk, only read GetBlockPos under the lock (Jonas Schnelli)
3e01665 Make sure WalletRescanReserver has successfully reserved the rescan (random-zebra)
4d05672 Add RAII wallet rescan reserver (Jonas Schnelli)
c3fc22d Avoid pemanent cs_main/cs_wallet lock during wallet rescans (random-zebra)
69a7288 Handle TIMESTAMP_WINDOW within CWallet::RescanFromTime (Russell Yanofsky)
fb12767 Make CWallet::RescanFromTime comment less ambiguous (Russell Yanofsky)
2d84bee Add RescanFromTime method and use from rpcdump (Russell Yanofsky)
e8dfb32 Move birthday optimization out of ScanForWalletTransactions (random-zebra)

Pull request description:

  Based on top of:
  - [x] #2279

  Backports bitcoin#10412, and bitcoin#11281

ACKs for top commit:
  furszy:
    ACK 1cde8b4 and merging

Tree-SHA512: 1c76ca9b7925299df796f72e171d70d1df9765d3b8d5976d7d280dd318474911cd8f173f686e57422a6f77fef145e4a9aae480b293e6b77ca4f93750688e997c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants