js-algorand-sdk
js-algorand-sdk copied to clipboard
createDryrun() doesn't include latest-timestamp, round and has wrong address encoding
trafficstars
Subject of the issue
As stated in the title createDryRun doesn't include latest-timestamp, round and has wrong address encoding as you can see in the snippet below. This breaks debugging with tealdbg.
"txns":[
{
"sig":"qSF3er9aqhbkCpR3aepHV0gdQ1r0JLJbrZUcmrrNP43lW1ybu2frS0LdkWX4WQQJbGqQe8LXqm+cwzjl1TV3AA==",
"txn":{
"fee":1000,
"fv":8057,
"lv":9057,
"snd":"DAz9jKOg9I+rQX6TyJyLmLeWAQ+/7bl/mjT5SRIPrFU=",
"type":"appl",
"gen":"sandnet-v1",
"gh":"+Kt49Kg2hPGRlt3igdBRceD9+m6B1zGTrl9z9/otbVA=",
"grp":"R5lk//FzfbewiysWMHEpBPz2S/AKDFJD7v8KLG2zmK0=",
"apid":32,
"apaa":[
"ZG9uYXRl"
]
}
},
{
"sig":"kHgBaczzd3vSwajdl/KiZyZxf6N0wZsOWlk8DEE+KNWS7dJhFJmnxxHaqOq08AZVC51C1WUzZDMqw47du6VIDg==",
"txn":{
"amt":1000000,
"fee":1000,
"fv":8057,
"lv":9057,
"snd":"DAz9jKOg9I+rQX6TyJyLmLeWAQ+/7bl/mjT5SRIPrFU=",
"type":"pay",
"gen":"sandnet-v1",
"gh":"+Kt49Kg2hPGRlt3igdBRceD9+m6B1zGTrl9z9/otbVA=",
"grp":"R5lk//FzfbewiysWMHEpBPz2S/AKDFJD7v8KLG2zmK0=",
"rcv":"gyRX8FGoYjyYRST6uyRYLfmLX4i5YdbBTLwHamRGqQs="
}
}
]
Your environment
- Software version: 3.6.2.stable [rel/stable] (commit #5e6bc6fc)
- Node status if applicable:
Last committed block: 465
Time since last block: 1.9s
Sync Time: 0.0s
Last consensus protocol: https://github.com/algorandfoundation/specs/tree/d5ac876d7ede07367dbaa26e149aa42589aac1f7
Next consensus protocol: https://github.com/algorandfoundation/specs/tree/d5ac876d7ede07367dbaa26e149aa42589aac1f7
Round for next consensus protocol: 466
Next consensus protocol supported: true
Last Catchpoint:
Genesis ID: sandnet-v1
Genesis hash: +Kt49Kg2hPGRlt3igdBRceD9+m6B1zGTrl9z9/otbVA=
Steps to reproduce
- Make any transaction and dump it with createDryrun()
- Try debugging it with tealdbg
Expected behaviour
Correct address encoding in txns array and presence of latest-timestamp and round field
Actual behaviour
Address encoded in base64 (i think) and additional fields missing
@andreademasi I recommend using msgpack for these types of files rather than JSON.
See this doc link for msgpack file creation: https://developer.algorand.org/docs/get-details/dapps/smart-contracts/debugging/#creating-a-dryrun-dump-file