ethabi
ethabi copied to clipboard
decode doesn't work
Is the parameter of ethabi decode the same as the output of encode? I got Error: Ethabi(InvalidData)
all the time.
json:
[{
"type":"function",
"inputs":[{
"name":"b",
"type":"bool"
}],
"name":"foo",
"outputs": []
}]
-
encode:
ethabi encode function ./example.json foo -p 1
-
get
455575780000000000000000000000000000000000000000000000000000000000000001
-
decode:
ethabi decode function ./example.json foo 455575780000000000000000000000000000000000000000000000000000000000000001
-
get:
Error: Ethabi(InvalidData)
hey this is more than a year later but did you manage to fix the issue ? I am facing the same problem..