refactor: use core hw activities#1044
Conversation
This comment has been minimized.
This comment has been minimized.
This comment was marked as outdated.
This comment was marked as outdated.
f3f9a2c to
435d9b0
Compare
|
Status update:
|
|
Status update after HW journey validation:
Remaining handoff: wait for checks/reviews on |
Trezor Android: #1044 vs #1062 — QA findingsDate: 2026-07-06 Scope mismatch
#1044 may be a stretch for 2.4.0: iOS Trezor is still behind, and for cross-platform consistency we should not ship HW tags or Explore inputs/outputs in 2.4.0. That fits 2.5.0 / #1029 instead. Finding 1: Trezor shows 0 balance + empty activity list (#1044)Symptom: Paired Trezor with known funds/history → app shows 0 sats and no activities. Not a Trezor/connect issue. Watcher starts; Core emits data; UI never updates. Cause: In Log evidence ( Likely persist root cause: HW activity ids = txids. Error on #1062: Updates Finding 2: Transfer shows duplicate rows — Transfer + Sent (#1044)On transfer to spending, activity list shows two rows for one flow:
Both appear in unified list; both are taggable. Not a quick polish issue — needs product rules for cross-wallet dedup/linking ( Finding 3: Scope ahead of 2.4.0 (#1044)#1044 adds:
Reasonable for 2.5.0 / #1029, but not aligned with a minimal, iOS-consistent 2.4.0 Trezor release. Prod / migration concernNot a prod issue today — no Trezor in prod. Before HW launch (2.5.0): migration must work on upgrade; UI must not depend on persist succeeding; transfer dedup needs design. Clear app data is a dev QA workaround, not a ship strategy. Recommendation
Later: cherry-pick #1062 reliability commits onto #1044 for 2.5.0; don’t merge as competing 0.3.9 paths. #1044 fixes needed (2.5.0, not blocking v1)
Links |
Addressed this Android-side gating issue: watcher state now updates before Core persistence, so the Trezor balance/activity UI stays live even if a Core upsert fails. Persistence failures are still logged with the watcher id, and received-transaction emission remains behind successful persistence. Validation: The migration/collision and transfer dedup points remain broader draft follow-ups outside this scoped fix. Resolved in f546f58 |
|
Set milestone to |
708cd21 to
794722a
Compare
Closes #1029
Refs #998
Description
This PR refactors hardware-wallet activity handling to use bitkit-core wallet-scoped activities instead of keeping Trezor transactions as separate in-memory watch-only entries.
This PR:
bitkit-coreto0.3.9and keeps activity reads, tags, transaction details, deletion, metadata, and seen-state calls scoped by wallet id.bitkit-core, avoiding duplicated hashing logic in the app.MetadataMismatchhandling accidentally carried by this branch; the LNURL validation change is already onmasterand there is no replacement exception to map.Out of scope for #1030:
Preview
QA Notes
Manual Tests
regression:normal on-chain/LN activity → Activity Detail → tags, Explore, and Boost: behavior matchesmaster.Automated Checks
HwWalletRepoTest.ktcovers active-watcher ownership, Core persistence ordering, duplicate address-type aggregation, wallet-id watcher restarts, and removal purge failures.TrezorRepoTest.kt,ActivityRepoTest.kt,ActivityDetailViewModelTest.kt,ActivityListViewModelTest.kt,AppViewModelSendFlowTest.kt,NotifyPaymentReceivedHandlerTest.kt, andPreActivityMetadataRepoTest.ktcover deterministic hardware wallet id derivation, scoped activity lookup/navigation, hardware tag/filter behavior, sheet detail routing, and nullable wallet-scope defaults.HomeViewModelTest.kt,HwWalletViewModelTest.kt, andBoostTransactionViewModelTest.ktcover hardware-wallet home/settings state and the public boost setup path used by the sheet.activity-blue-icons.xmlcovers unified hardware activity list/tab behavior;activity-detail-hw-tags.xmlcovers hardware tags and Explore inputs/outputs; hardware transfer journeys now handle the first-run Transfer To Spending intro before asserting the amount screen.connect-home-tile.xml,activity-blue-icons.xml,activity-detail-hw-tags.xml, anddetail-overview.xmlon8372a730f, covering pair/fund, blue activity rows, tabs, persisted tag + tag filter, Explore inputs/outputs, hardware wallet detail, transfer amount screen after first-run intro, remove cancel/confirm, watcher stop, and hardware activity purge.just compile,just test, andjust lintpassed onc0274e311;xmllintpassed for updated hardware-wallet journey XMLs on8372a730f.