Page MenuHomePhabricator

[Cashtab] Parse agora oneshot buys and sells
ClosedPublic

Authored by bytesofman on Oct 23 2024, 22:37.

Details

Reviewers
emack
Group Reviewers
Restricted Project
Commits
rABC31e27d47cace: [Cashtab] Parse agora oneshot buys and sells
Summary

Parse agora buy, sell, and cancel txs in Cashtab tx history

Test Plan

npm test

seems to also work on agora partials

image.png (449×482 px, 57 KB)

image.png (449×482 px, 55 KB)

Diff Detail

Event Timeline

back out unrelated line break, improve conditional organization for agora renderedTxType

bytesofman added inline comments.
modules/ecash-agora/src/agora.ts
890 ↗(On Diff #50348)

we still aren't publishing ecash-agora. I don't think there is any reason not to export this, since you can see in this diff how it could be useful to another application.

Arguably we should export something more like isAgoraCancel(inputScript) ... but at this point I don't think we have enough info to know what this method would look like. Cashtab's tx history rendering case is pretty specific. For example, we can reasonably assume the input is either an agora buy or an agora cancel.

This revision is now accepted and ready to land.Oct 24 2024, 05:32