Page MenuHomePhabricator

[Cashtab] [Alias] pt 9 - Retain tokenInfoById upon alias validation
ClosedPublic

Authored by emack on Feb 22 2023, 00:52.

Details

Summary

T2551

Depends on D13143

This diff updates loadCashtabCache to retain tokenInfoById via the new parseInvalidCashtabCacheForMigration function when migrating pre-alias wallets.

[Cashtab] [Alias] pt 1 - Create scaffold for new Alias component
[Cashtab] [Alias] pt 2 - Upgrade sendXec() to handle alias registration
[Cashtab] [Alias] pt 3 - Implement isAliasAvailable function
[Cashtab] [Alias] pt 4 - Implement isAddressRegistered function
[Cashtab] [Alias] pt 5 - Implement getAddressFromAlias function
[Cashtab] [Alias] pt 6.1 - Get latest alias tx count from payment address
[Cashtab] [Alias] pt 6.1.1 - Apply Promise.All approach for alias history retrieval
[Cashtab] [Alias] pt 6.2 - Implement getAliasesFromLocalForage
[Cashtab] [Alias] pt 6.3 - Implement updateAliases
[Cashtab] [Alias] pt 6.4 - Update getAliases() to extract both alias and address
[Cashtab] [Alias] pt 6.5 - Optimize getAllTxHistory to only make API calls for uncached tx history pages
[Cashtab] [Alias] pt 6.6 - Render list of Aliases owned by active wallet in Alias.js
[Cashtab] [Alias] pt 7 - Mitigate edge cases for registration records
[Cashtab] [Alias] pt 8 - Activation flag in prod
[Cashtab] [Alias] pt 9 - Retain tokenInfoById upon alias validation
--cutoff--
[Cashtab] [Alias] pt 10 - Enable alias lookup for Send XEC component
[Cashtab] [Alias] pt 11 - Enable alias lookup for Send Token component
[Cashtab] [Alias] pt 12 - Upgrade tx history to recognize alias registration txs
[Cashtab] [Alias] pt 13 - Port Alias feature to Cashtab extension
[Cashtab] [Alias] pt 14 - Pre-prod update (Set final registration fees, remove residual dev logs and enable prod flag)

Test Plan
  • checkout master cashtab
  • npm start and ensure pre-alias cashtabCache is loaded
  • arc patch this diff
  • npm start, upon cashtab startup verify the console log is displaying invalid cashtabCache detected, missing params initialized from currency.defaultCashtabCache and ensure post-alias cashtabCache contains the new aliasCache object as well as retaining the existing tokenInfoById object
  • double check ALL existing tokens in tokenInfoById have been retained
  • refresh cashtab and ensure console log is displaying valid cashtabCache detected
  • npm test

Diff Detail

Repository
rABC Bitcoin ABC
Branch
aliases
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 22050
Build 43735: Build Diffcashtab-tests
Build 43734: arc lint + arc unit