Page MenuHomePhabricator

[Cashtab] [chronik tx history p21] Better token burn parsing
ClosedPublic

Authored by bytesofman on Oct 5 2022, 22:38.

Details

Summary

T2447

Depends on D12158

For token transactions with high decimal count, chronik will (sometimes?) include the slpBurn field, even if the burned amount is 0...so it's not actually a burn.

This specifies that the existence of an slpBurn field is not enough to imply a token burn. Amount must be zero. This corrects an issue where non-burn txs were being parsed incorrectly (wrong amount, wrong tx type)

Test Plan

Review new unit test and npm test
Receive an etoken tx with 9 decimal places
Verify that it is rendered in tx history as a received etoken tx with correct quantity

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable