Skip to content

refactor(key-wallet): drop unused first_loaded_at and total_transactions from WalletMetadata#719

Merged
xdustinface merged 1 commit intov0.42-devfrom
claude/frosty-benz-fdfc3c
May 4, 2026
Merged

refactor(key-wallet): drop unused first_loaded_at and total_transactions from WalletMetadata#719
xdustinface merged 1 commit intov0.42-devfrom
claude/frosty-benz-fdfc3c

Conversation

@QuantumExplorer
Copy link
Copy Markdown
Member

Summary

  • Drops first_loaded_at and total_transactions from WalletMetadata; neither field is read by any consumer.
  • Removes WalletInfoInterface::{first_loaded_at, set_first_loaded_at}, the ManagedWalletInfo::increment_transactions helper, and the six WalletManager call sites that wrote first_loaded_at after from_wallet.
  • Strips test assertions in wallet_checker and wallet/mod.rs that exercised the removed fields.

Test plan

  • cargo build --workspace
  • cargo test -p key-wallet -p key-wallet-manager
  • cargo clippy -p key-wallet -p key-wallet-manager --all-targets -- -D warnings
  • cargo fmt --check

🤖 Generated with Claude Code

…ctions` from `WalletMetadata`

Neither field is read by any consumer (FFI, SPV, key-wallet-manager, or
key-wallet itself outside of the assertions removed here). `first_loaded_at`
was only ever written via `set_first_loaded_at` from `WalletManager`; the
trait methods, the field, and all six call sites are gone. `total_transactions`
was only incremented in `check_core_transaction` and asserted on in tests;
the increment, the helper, and the test assertions are gone.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 3, 2026

Warning

Rate limit exceeded

@QuantumExplorer has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 30 minutes and 1 second before requesting another review.

To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 7f8982ca-9235-44c7-8661-d7c91f567f8a

📥 Commits

Reviewing files that changed from the base of the PR and between fcaf66e and 15d622e.

📒 Files selected for processing (6)
  • key-wallet-manager/src/lib.rs
  • key-wallet/src/transaction_checking/wallet_checker.rs
  • key-wallet/src/wallet/managed_wallet_info/mod.rs
  • key-wallet/src/wallet/managed_wallet_info/wallet_info_interface.rs
  • key-wallet/src/wallet/metadata.rs
  • key-wallet/src/wallet/mod.rs
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch claude/frosty-benz-fdfc3c

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
Review rate limit: 0/1 reviews remaining, refill in 30 minutes and 1 second.

Comment @coderabbitai help to get the list of available commands and usage tips.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 3, 2026

Codecov Report

❌ Patch coverage is 66.66667% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 70.59%. Comparing base (fcaf66e) to head (15d622e).
⚠️ Report is 1 commits behind head on v0.42-dev.

Files with missing lines Patch % Lines
key-wallet-manager/src/lib.rs 66.66% 2 Missing ⚠️
Additional details and impacted files
@@              Coverage Diff              @@
##           v0.42-dev     #719      +/-   ##
=============================================
+ Coverage      70.57%   70.59%   +0.01%     
=============================================
  Files            319      319              
  Lines          68211    68183      -28     
=============================================
- Hits           48142    48132      -10     
+ Misses         20069    20051      -18     
Flag Coverage Δ
core 75.81% <ø> (ø)
ffi 43.37% <ø> (ø)
rpc 20.00% <ø> (ø)
spv 87.32% <ø> (+0.10%) ⬆️
wallet 69.61% <66.66%> (-0.04%) ⬇️
Files with missing lines Coverage Δ
...-wallet/src/transaction_checking/wallet_checker.rs 99.38% <ø> (-0.01%) ⬇️
key-wallet/src/wallet/managed_wallet_info/mod.rs 68.42% <ø> (-1.58%) ⬇️
...allet/managed_wallet_info/wallet_info_interface.rs 83.22% <ø> (+1.23%) ⬆️
key-wallet/src/wallet/mod.rs 88.17% <ø> (-0.04%) ⬇️
key-wallet-manager/src/lib.rs 62.10% <66.66%> (-0.73%) ⬇️

... and 4 files with indirect coverage changes

@xdustinface xdustinface merged commit a9fb28f into v0.42-dev May 4, 2026
37 checks passed
@xdustinface xdustinface deleted the claude/frosty-benz-fdfc3c branch May 4, 2026 13: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