erigontech / erigontech/silkworm
evmone: missing specific error string for OOG in call_impl
- Dominant language
- C++
- Stars
- 318
- Forks
- 84
- PR merge metrics
- No merged PRs in 30d
Description
Calling
```
{
"jsonrpc":"2.0",
"method":"debug_traceTransaction",
"params":[
"0x75f027631056616468a13d3bf83c08a2f7ce803bb20b8d980c9d73bdbd5ce355",
{"disableStorage": true,"disableMemory": true,"disableStack": true}
],
"id":1
}
```
the silkworm RPC JSON result differs from erigon in the trace error field for opcode CALL at PC 244 (depth 2.
That's due to the check made in [call_impl](https://github.com/erigontech/evmone/blob/1aa56aebb472bfee4901047f369809c85c2ed82c/lib/evmone/instructions_calls.cpp#L160).
The `call_impl` function returns false We would need to receive also an error string indicating the specific reason for the OOG error.
Current JSON result:
```
{
"depth": 2,
"error": "out of gas",
"gas": 8216,
"gasCost": 40,
"op": "CALL",
"pc": 244
}
```
Expected JSON result:
```
{
"depth": 2,
"error": "out of gas: gas uint64 overflow",
"gas": 8216,
"gasCost": 40,
"op": "CALL",
"pc": 244
}
```
The related integration tests are [test_62, test_74, test_75](https://github.com/erigontech/rpc-tests/tree/main/integration/mainnet/debug_traceTransaction)
Contributor guide
Assessment
This issue has not been assessed yet.