Page MenuHomePhabricator

[Cashtab] [chronik utxo handling p5] Add support for caching token info to limit chronik API calls to unseen tokens
ClosedPublic

Authored by bytesofman on Sep 12 2022, 16:34.

Details

Summary

T2447

Depends on D11942

Add support for cached token info.

The finalizeTokenArray function will accept an object, cachedTokenInfoById. This object is scanned to see what token info is already in cache. If token info is in this object, then Cashtab will not make an API call to get it.

cacheTokenInfoById will be added to local storage in a later diff on this stack. For now, the function will work even if it is not provided.

Test Plan

Review unit tests and mocks.
npm start
Send a token tx and confirm tx history and wallet balance update appropriately
Receive a token tx and confirm tx history and wallet balance update appropriately

Diff Detail

Repository
rABC Bitcoin ABC
Branch
chronik-utxo-handling-take2
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 19997
Build 39685: Build Diffcashtab-tests
Build 39684: arc lint + arc unit