Skip to content

Conversation

@Quexington
Copy link
Contributor

@Quexington Quexington commented Dec 4, 2025

This PR moves a large chunk of code from the wallet RPC into WSM. None of this logic belongs in the RPC which is a front end primarily concerned with serialization and conversion of types.


Note

Extracts singleton/DID/NFT manual lookup and DID recovery logic into WalletStateManager and updates RPC endpoints to delegate to these helpers, with tests adjusted accordingly.

  • Backend:
    • Move manual singleton helpers to wallet_state_manager:
      • get_latest_singleton_coin_spend(), manual_did_search(), manual_nft_search(), find_lost_did().
      • Add result structs: ManualDIDSearchResults, ManualNFTSearchResults.
    • Update RPC endpoints to delegate:
      • did_get_info(), did_find_lost_did(), nft_get_info() now call wallet_state_manager methods.
    • Remove inlined DID/NFT parsing/reconstruction and related imports from wallet_rpc_api.
  • Tests:
    • Adjust NFT RPC tests to reflect new coin_id parsing (drop invalid-format check) and unchanged behavior for bech32/hex IDs.
  • Misc:
    • Minor import cleanups and code slimming in wallet_rpc_api.

Written by Cursor Bugbot for commit 32a7a92. This will update automatically on new commits. Configure here.

@Quexington Quexington requested a review from a team as a code owner December 4, 2025 22:37
@Quexington Quexington changed the title Extract manual syncing logic out of wallet RPC [LABS-307] Extract manual syncing logic out of wallet RPC Dec 4, 2025
@Quexington Quexington added the Changed Required label for PR that categorizes merge commit message as "Changed" for changelog label Dec 4, 2025
@coveralls-official
Copy link

Pull Request Test Coverage Report for Build 19967060081

Details

  • 142 of 186 (76.34%) changed or added relevant lines in 2 files are covered.
  • 39 unchanged lines in 7 files lost coverage.
  • Overall coverage decreased (-0.02%) to 90.747%

Changes Missing Coverage Covered Lines Changed/Added Lines %
chia/wallet/wallet_state_manager.py 135 179 75.42%
Files with Coverage Reduction New Missed Lines %
chia/timelord/timelord_api.py 1 93.02%
chia/timelord/timelord_launcher.py 2 70.0%
chia/full_node/full_node.py 3 87.0%
chia/wallet/wallet_node.py 5 86.32%
chia/daemon/server.py 7 80.62%
chia/server/node_discovery.py 10 80.32%
chia/timelord/timelord.py 11 72.0%
Totals Coverage Status
Change from base Build 19938390251: -0.02%
Covered Lines: 102457
Relevant Lines: 112731

💛 - Coveralls

@github-actions github-actions bot added the merge_conflict Branch has conflicts that prevent merge to main label Dec 8, 2025
@Quexington Quexington force-pushed the quex.extract_manual_syncing branch from 00989fa to e631f8d Compare December 8, 2025 17:44
@github-actions github-actions bot removed the merge_conflict Branch has conflicts that prevent merge to main label Dec 8, 2025
@emlowe
Copy link
Contributor

emlowe commented Dec 8, 2025

cursor review

@github-actions github-actions bot added the merge_conflict Branch has conflicts that prevent merge to main label Dec 10, 2025
@Quexington Quexington force-pushed the quex.extract_manual_syncing branch from 15270c9 to 32a7a92 Compare December 12, 2025 13:05
@github-actions github-actions bot removed the merge_conflict Branch has conflicts that prevent merge to main label Dec 12, 2025
@github-actions
Copy link
Contributor

File Coverage Missing Lines
chia/wallet/wallet_state_manager.py 75.4% lines 3023, 3036, 3043, 3090, 3114, 3147, 3172, 3176, 3198-3200, 3207, 3210-3216, 3219-3222, 3224-3225, 3228-3230, 3233-3238, 3242-3243, 3252, 3271-3274, 3276, 3294-3295
Total Missing Coverage
186 lines 44 lines 76%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Changed Required label for PR that categorizes merge commit message as "Changed" for changelog coverage-diff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants