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
Currently skaled is not handling Panic errors like other ethereum clients and returns revert message EVM revert instruction without description message instead. We need to handle internal errors and return the details in revertReason in the same format with Geth.
0x00: Used for generic compiler inserted panics.
0x01: If you call assert with an argument that evaluates to false.
0x11: If an arithmetic operation results in underflow or overflow outside of an unchecked { ... } block.
0x12; If you divide or modulo by zero (e.g. 5 / 0 or 23 % 0).
0x21: If you convert a value that is too big or negative into an enum type.
0x22: If you access a storage byte array that is incorrectly encoded.
0x31: If you call .pop() on an empty array.
0x32: If you access an array, bytesN or an array slice at an out-of-bounds or negative index (i.e. x[i] where i >= x.length or i < 0).
0x41: If you allocate too much memory or create an array that is too large.
0x51: If you call a zero-initialized variable of internal function type.
curl GOERLI_URL -X POST -H "Content-Type: application/json" -d '{"id":1931024001,"jsonrpc":"2.0","method":"eth_call","params":[{"data":"0x0e955ddb000000000000000000000000000000000000000000000000000000000000000b000000000000000000000000000000000000000000000000000000000000000b","from":"0xa68F946090c600eDa6f139783077EE802Afeb990","to":"0x0139D5EA708C7Fb2e668E032608a65d482e754cB","type":"0x1","value":"0x0"},"latest"]}'
{"jsonrpc":"2.0","id":1931024001,"error":{"code":3,"data":"0x4e487b710000000000000000000000000000000000000000000000000000000000000032","message":"execution reverted: out-of-bounds access of an array or bytesN"}}
The text was updated successfully, but these errors were encountered:
Currently skaled is not handling Panic errors like other ethereum clients and returns revert message
EVM revert instruction without description message
instead. We need to handle internal errors and return the details in revertReason in the same format with Geth.Map of Panic errors according to solidity doc (https://docs.soliditylang.org/en/v0.8.21/control-structures.html#panic-via-assert-and-error-via-require):
Implementation in go-ethereum: https://github.com/ethereum/go-ethereum/blob/63aaac81007ad46b208570c17cae78b7f60931d4/accounts/abi/abi.go#L258
Example of GETH response:
The text was updated successfully, but these errors were encountered: