Page MenuHomePhabricator

[ecash-wallet] Support including arbitrary data with ALP txs
ClosedPublic

Authored by bytesofman on Sep 9 2025, 18:47.

Details

Summary

ALP txs may include arbitary information in addition to the token tx itself. Support this with the already-defined DataAction.

Test Plan

npm test, CI integration test

Diff Detail

Event Timeline

add some more tests to confirm expected behavior

Failed tests logs:

====== Wallet can build and broadcast on regtest: We can send an ALP tx with DataAction containing "test" (ASCII encoded).Wallet can build and broadcast on regtest We can send an ALP tx with DataAction containing "test" (ASCII encoded) ======
AssertionError: expected '6a5037534c5032000453454e442c05c483f40…' to equal '6a5037534c5032000453454e44ae4d564a296…'
    at Context.<anonymous> (test/transactions.test.ts:2090:29)
    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)

      + expected - actual

      -6a5037534c5032000453454e442c05c483f40895f9effbd55d584042fb94b06a785fb96602d097eebffaaa8e54026400000000008403000000000474657374
      +6a5037534c5032000453454e44ae4d564a2968d3c11bfd7e349f3180cedecc39d4eb7f1d6cf581d7570a6d0566026400000000008403000000000474657374

Each failure log is accessible here:
Wallet can build and broadcast on regtest: We can send an ALP tx with DataAction containing "test" (ASCII encoded).Wallet can build and broadcast on regtest We can send an ALP tx with DataAction containing "test" (ASCII encoded)

bytesofman published this revision for review.Sep 9 2025, 19:06
This revision is now accepted and ready to land.Sep 9 2025, 20:19