Page MenuHomePhabricator

[Cashtab] [BCH deprecation] [TxBuilder] Pt 3/8 - Add local TxBuilder to createToken
ClosedPublic

Authored by emack on Nov 22 2022, 12:58.

Details

Summary

T2730

Depends on D12553

This diff updates the createToken() function to use the local transaction builder module and compares the txBuilder object after adding input, output and signing/building tx.

Pt 1/8 - Localize Transaction Builder module
Pt 2/8 - Deprecate BCH.TransactionBuilder in sendXec
Pt 3/8 - Add local TxBuilder to createToken
Pt 4/8 - Deprecate BCH.TransactionBuilder in createToken
Pt 5/8 - Add local TxBuilder to sendToken
Pt 6/8 - Deprecate BCH.TransactionBuilder in sendToken
Pt 7/8 - Add local TxBuilder to burnToken
Pt 8/8 - Deprecate BCH.TransactionBuilder in burnToken

Test Plan
  • npm ci
  • npm test and ensure no errors with txBuilder.test.js
  • npm start
  • create a new token and ensure the following 3 console log messages are displayed:
  • post-generateTokenTxInput() output matches
  • post-generateTokenTxOutput() output matches
  • post-signAndBuildTx() output matches

Diff Detail

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

Event Timeline

emack requested review of this revision.Nov 22 2022, 12:58

looks good but dependencies need to be rebased, I get this error when I arc patch

COMMITTED  Successfully committed patch.

 Cherry Pick Failed!
 Exception 
Command failed with error #1!
COMMAND
git cherry-pick -- arcpatch-D12541_1

STDOUT
Auto-merging web/cashtab/package-lock.json
CONFLICT (content): Merge conflict in web/cashtab/package-lock.json
Auto-merging web/cashtab/package.json
CONFLICT (content): Merge conflict in web/cashtab/package.json


STDERR
error: could not apply cbd56641c... [Cashtab] [BCH deprecation] [TxBuilder] Pt 1/8 - Localize Transaction Building module
This revision now requires changes to proceed.Nov 23 2022, 08:28
This revision is now accepted and ready to land.Nov 23 2022, 10:49