go-opera
go-opera copied to clipboard
Old SFC transactions return wrong traces (trace_)
Describe the bug
SFC transactions in the first 4,5M blocks still return incorrect responses for trace_
methods.
As you can see in the example below, value
, gas
, and input
are all zeroes, when they shouldn't be.
Apply a similar fix to #372.
To Reproduce
curl --request POST --data '[{"id":1,"jsonrpc":"2.0","method":"trace_block","params":["0x367cd"]}]' -H "Content-Type: application/json" https://rpcapi-tracing.fantom.network | jq
{
"jsonrpc": "2.0",
"id": 1,
"result": [
{
"action": {
"callType": "call",
"from": "0xadf29f3ece4549cce8e3f07692806864cb8f55b5",
"to": "0xfc00face00000000000000000000000000000000",
"value": "0x0",
"gas": "0x0",
"input": "0x"
},
"blockHash": "0x0000048d00000e73b01df5b401d9bf3d735433fb8b667a04eaed46adab0b3bfb",
"blockNumber": 223181,
"error": "sfc tx",
"subtraces": 0,
"traceAddress": [],
"transactionHash": "0xaad40c38472b4d30046f646a11eaae0308bcfb02ee3d262718a03f2af366a349",
"transactionPosition": 0,
"type": "call"
}
]
}
Expected behavior See transaction on ftmscan here.
- value field is missing but supposed to be 1420FTM
- gas is missing, should be 74743
- input is missing, should be 0x3a274ff6
I initially thought it would be just the first 4,5M blocks as in #372 , but it is still happening on block 6,045,149 (0x5C3DDD)
curl --request POST --data '[{"id":1,"jsonrpc":"2.0","method":"trace_block","params":["0x5C3DDD"]}]' -H "Content-Type: application/json" https://YOUR_NODE
[...]
{
"action": {
"callType": "call",
"from": "0x86dbab76ebe0df382f6dc1929cbb6571b293ecff",
"to": "0xfc00face00000000000000000000000000000000",
"value": "0x0",
"gas": "0x0",
"input": "0x"
},
"blockHash": "0x000022950000009db4656cc606a1d0edf47964305b2f5daa6b5059004d6c2142",
"blockNumber": 6045149,
"error": "sfc tx",
"subtraces": 0,
"traceAddress": [],
"transactionHash": "0xb0bd3adc0e1c0dc4b672bd1e17ced05f8e7c72460ff2640f1aa2dfe93b75164c",
"transactionPosition": 24,
"type": "call"
}
[...]
Describe the bug SFC transactions in the first 4,5M blocks still return incorrect responses for
trace_
methods. As you can see in the example below,value
,gas
, andinput
are all zeroes, when they shouldn't be.Apply a similar fix to #372.
To Reproduce
curl --request POST --data '[{"id":1,"jsonrpc":"2.0","method":"trace_block","params":["0x367cd"]}]' -H "Content-Type: application/json" https://rpcapi-tracing.fantom.network | jq { "jsonrpc": "2.0", "id": 1, "result": [ { "action": { "callType": "call", "from": "0xadf29f3ece4549cce8e3f07692806864cb8f55b5", "to": "0xfc00face00000000000000000000000000000000", "value": "0x0", "gas": "0x0", "input": "0x" }, "blockHash": "0x0000048d00000e73b01df5b401d9bf3d735433fb8b667a04eaed46adab0b3bfb", "blockNumber": 223181, "error": "sfc tx", "subtraces": 0, "traceAddress": [], "transactionHash": "0xaad40c38472b4d30046f646a11eaae0308bcfb02ee3d262718a03f2af366a349", "transactionPosition": 0, "type": "call" } ] }
Expected behavior See transaction on ftmscan here.
- value field is missing but supposed to be 1420FTM
- gas is missing, should be 74743
- input is missing, should be 0x3a274ff6
[]()