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

Refactor: Add get_wallet_rescan_status() instead of getwalletinfo() for bci #1478

Merged
merged 1 commit into from
Apr 29, 2023

Conversation

kristapsk
Copy link
Member

Noticed this when tried to rebase #1462 after merging of #1477. #1461 added public getwalletinfo() method to BitcoinCoreInterface, which was used by code outside of jmclient/jmclient/blockchaininterface.py. This is bad approach, as it relies on Bitcoin Core RPC getwalletinfo returned dict, which contains a lots of different stuff too, could lead to more problems in future introducing other blockchain interface classes. Let's instead have generic method returning just wallet rescan status. Also it now returns Tuple[bool, Optional[Decimal]] with rescan status percentage, if rescan is in progress, although that's not used by any other code for now.

@AdamISZ
Copy link
Member

AdamISZ commented Apr 29, 2023

utACK e31e839 , very much agree with the thinking here.

@kristapsk kristapsk merged commit 2289fcb into JoinMarket-Org:master Apr 29, 2023
@kristapsk kristapsk deleted the bci-wallet-rescan branch April 29, 2023 17:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants