You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
algosdk.decodeObj(tx)
Uncaught RangeError: Extra 157 of 368 byte(s) found at buffer[211]
at Decoder.createNoExtraBytesError (C:\src\multisig-dispatcher\node_modules\algo-msgpack-with-bigint\dist\Decoder.js:78:16)
at Decoder.doDecodeSingleSync (C:\src\multisig-dispatcher\node_modules\algo-msgpack-with-bigint\dist\Decoder.js:88:24)
at Decoder.decode (C:\src\multisig-dispatcher\node_modules\algo-msgpack-with-bigint\dist\Decoder.js:83:21)
at Object.decode (C:\src\multisig-dispatcher\node_modules\algo-msgpack-with-bigint\dist\decode.js:13:20)
at Object.decode (C:\src\multisig-dispatcher\node_modules\algosdk\dist\cjs\src\encoding\encoding.js:71:20)
at Object.decodeObj (C:\src\multisig-dispatcher\node_modules\algosdk\dist\cjs\src\main.js:210:21)
>
The text was updated successfully, but these errors were encountered:
This RangeError means you have probably several msgpack object encoded in a single buffer. msgpack-lite is decoding the first one without alerting you there is more data to the buffer, the better behavior is to throw the error.
If your example errors at position 211 try slicing the buffer and decoding the following: tx.slice(0,211) and tx.slice(211).
We could add a method to decode multiple mspack objects to make this easier.
Subject of the issue
Decoding transaction using
algosdk.decodeObj
will fail. The same procedure usingmsgpack-lite
decode function will go thru without problems.Your environment
Steps to reproduce
algosdk.decodeObj( ... )
Expected behaviour
As
msgpack-lite
decode function output:Actual behaviour
The text was updated successfully, but these errors were encountered: