Page MenuHomePhabricator

[Cashtab] [chronik utxo handling p9] Update sendXec functions for new utxo storage format
ClosedPublic

Authored by bytesofman on Sep 13 2022, 17:43.

Details

Summary

T2447

Depends on D11967

Update sendXec function and the functions it relies on to generate and send an XEC transaction with the new chronik utxo storage format.

Key differences: chronik utxos have an outpoint key with the vout at outIdx. The txid is also included in this outpoint object.

Also, while chronik utxos still have a value key, it is string type. Transaction builder utxo signing requires this to be a number.

This diff also modifies mocks used by unit tests to have the new chronik format.

Test Plan

npm start

  1. Send a one-to-one XEC tx and review in block explorer for correct fee, change, weirdness check
  2. Do the same for a one-to-many XEC tx
  3. Do the same for a one-to-one and one-to-many XEC tx with OP_RETURN msg
  4. Do the same for one-to-one XEC tx with encrypted msg

Note: token txs are still broken in this iteration and will be fixed in a subsequent diff on this stack

Diff Detail

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