-
Notifications
You must be signed in to change notification settings - Fork 384
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Interface for errors RPC response in eth_call and eth_estimateGas #232
Labels
A-spec
Area: specification
Comments
This was referenced Oct 24, 2024
fjl
added a commit
to ethereum/go-ethereum
that referenced
this issue
Nov 7, 2024
Here I'm adding a new helper function that extracts the revert reason of a contract call. Unfortunately, this aspect of the API is underspecified. See these spec issues for more detail: - ethereum/execution-apis#232 - ethereum/execution-apis#463 - ethereum/execution-apis#523 The function added here only works with Geth-like servers that return error code `3`. We will not be able to support all possible servers. However, if there is a specific server implementation that makes it possible to extract the same info, we could add it in the same function as well. --------- Co-authored-by: Marius van der Wijden <[email protected]>
holiman
pushed a commit
to ethereum/go-ethereum
that referenced
this issue
Nov 19, 2024
Here I'm adding a new helper function that extracts the revert reason of a contract call. Unfortunately, this aspect of the API is underspecified. See these spec issues for more detail: - ethereum/execution-apis#232 - ethereum/execution-apis#463 - ethereum/execution-apis#523 The function added here only works with Geth-like servers that return error code `3`. We will not be able to support all possible servers. However, if there is a specific server implementation that makes it possible to extract the same info, we could add it in the same function as well. --------- Co-authored-by: Marius van der Wijden <[email protected]>
zfy0701
pushed a commit
to sentioxyz/go-ethereum
that referenced
this issue
Dec 3, 2024
Here I'm adding a new helper function that extracts the revert reason of a contract call. Unfortunately, this aspect of the API is underspecified. See these spec issues for more detail: - ethereum/execution-apis#232 - ethereum/execution-apis#463 - ethereum/execution-apis#523 The function added here only works with Geth-like servers that return error code `3`. We will not be able to support all possible servers. However, if there is a specific server implementation that makes it possible to extract the same info, we could add it in the same function as well. --------- Co-authored-by: Marius van der Wijden <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Currently when an eth_call or eth_estimateGas fails and if the revert data is present, geth's rpc returns:
However, this seems to be nonstandardized. For e.g. some clients do not include
data
.Also the open rpc link in readme as well as https://eth.wiki/json-rpc/API do not specify how the error response would be for eth_call or eth_estimateGas.
Would it be beneficial if the error response is also included in API spec?
The text was updated successfully, but these errors were encountered: