Page MenuHomePhabricator

[Cashtab] [wallet mgmt improvements p7] Do not set renamed active wallet in state unless storage update succeeded
ClosedPublic

Authored by bytesofman on Dec 10 2022, 18:47.

Details

Summary

T2822

Depends on D12847

Pretty sure this is the 'root cause' of the bug, though the diffs earlier on this stack implement better dev practices.

This diff ensures that we do not set a renamed active wallet in state as wallet unless it has also updated in indexedDb.

Test Plan

npm start
Create 3 or 4 wallets
Rapidly switch between them
Every once in awhile, rename the active wallet, or a saved wallet
Confirm that you never see the initial bug (savedWallets does not add an extra renamed activeWallet)

Diff Detail

Repository
rABC Bitcoin ABC
Branch
stack-to-improve-wallet-mgmt
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 21516
Build 42679: Build Diffcashtab-tests
Build 42678: arc lint + arc unit