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
accounts/abi: added new error type #23161
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally lgtm. But you should also fix the revert reason resolving part. Currently we hold the assumption that all the revert reason is encoded by the string format. But now it's possible to encode with the customized rules, so we need to generate the decode binding for users and also fix in the API.
@rjl493456442 I would like to merge this without the actual logic to unpack errors. |
@MariusVanDerWijden @rjl493456442 any updates here? It would be awesome to get this into 1.10.9 |
error is not yet supported by abigen: ethereum/go-ethereum#23161
a1d8289
to
46e872a
Compare
abi.Events[name] = NewEvent(name, field.Name, field.Anonymous, field.Inputs) | ||
case "error": | ||
abi.Errors[field.Name] = NewError(field.Name, field.Inputs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does error type also support overloading? Should we also handle the overloading here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, errors do not support overloading
Left one comment, otherwise lgtm for the first step to introduce builtin error type. |
This is the initial step for support of Solidity errors in contract bindings. As of this change, errors can be decoded, but are not supported in bindings yet. Closes ethereum#23157
This is the initial step for support of Solidity errors in contract bindings. As of this change, errors can be decoded, but are not supported in bindings yet. Closes ethereum#23157
This is the initial step for support of Solidity errors in contract bindings. As of this change, errors can be decoded, but are not supported in bindings yet. Closes ethereum#23157
closes: #23157
TODO: