-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Add tx list request and response #5
base: develop
Are you sure you want to change the base?
Conversation
Thanks for the PR already! I don't have time to look at the code right now, maybe next week. The CI build failed because of the linter. See https://travis-ci.org/philippgille/libra-sdk-go/builds/558352696#L631 Regarding the decoding you may find some inspiration here:
And could you please change the target branch from |
Hey @philippgille, I've made some good progress on pulling the TX list. Heres what a single transaction from a transaction list looks like [
{
"raw_bytes": "0x0a20000000000000000000000000000000000000000000000000000000000000000028904e38bfecb8e9051af4010abf014c49425241564d0a010007014a000000060000000350000000060000000c56000000050000000d5b00000004000000055f0000003300000004920000002000000007b20000000d000000000000010002000300010400020002040203020402063c53454c463e0c4c696272614163636f756e74094c69627261436f696e046d61696e0f6d696e745f746f5f6164647265737300000000000000000000000000000000000000000000000000000000000000000001020004000c000c01110102122408011220f7d5da0c23abd8a7d33fbf200ed9f5a25329020cfecb7d2375f7447b22940354120a120800e1f50500000000",
"sender_pub_key": "0x4bd5f14227c3c3dfcb74454fb31005dac5631522552b30ac0edae67cc8abe405",
"sender_sig": "0xd328f8b34c610cd19d57b1916fefefa0fd280744d1f789b610cafe7283a784e537992469cb3043287f4b8f11a26cf7dd9cfcb550301383108d6be78d1fe25300"
}] I think the |
// Transaction is a transaction of Libra Coins. | ||
type Transaction struct { | ||
RawBytes []byte | ||
SenderPubKey []byte | ||
SenderSig []byte | ||
} | ||
|
||
// TransactionList | ||
type TransactionList struct { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
An extra type for a transaction list that only contains a slice of transactions is not necessary I think.
Great to see you're still working on it! Did you check out the TypeScript SDK I linked to in the previous comment for clues regarding the decoding? I didn't check it in detail yet, maybe I can have a more thorough look soon. |
I was hoping to get a better understanding of the project and the flow to add new features. Got stuck on the serialization of the response items. Once I fully understand how to parse these responses there are a few other features I would like to help add! Can we get this PR resolved and the responses serialized correctly?!
Changes
82258967750773ea090d125f9aeb9b9e42f6c7ff6df0742336992bfc52b4096a
since it was causing the example app to panic.GetTransactionList
and used the existing Request Item types.tx.go
file to support Transaction ListsHelp Needed
With
FromTransactionListBlob
not exactly sure how to serialize the response. Also withFromTransactionListResourceBlob