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 19996
Build 39683: Build Diffcashtab-tests
Build 39682: arc lint + arc unit