Skip to content

Conversation

@arunjot12
Copy link

Earlier, I was deploying ERC 4337 account abstraction entry point contract (version 6) and it has function simulateValidation that reverts ValidationResult and has uint data type, while calling this function I am unable to get the values in ValidationResult due to which my dapp is stuck at that point.

But now I've made a solutions for this.

This PR enhances the revert handling logic by adding support for decoding and handling multiple custom error selectors in Solidity revert statements.

@arunjot12 arunjot12 requested a review from sorpaas as a code owner January 6, 2025 11:06
@arunjot12
Copy link
Author

arunjot12 commented Jan 6, 2025

@#1582 This issue

@conr2d
Copy link
Contributor

conr2d commented Jan 12, 2025

Parsing and displaying error messages from revert results is a client-side responsibility, not something managed by Frontier.

In the current Frontier implementation, a reverted eth_call correctly includes the result data in the RPC response. If the issue involves the improper handling of Solidity-defined error objects (as opposed to string errors), this likely indicates a problem with the EVM backend not providing the expected data. In such cases, the focus should be on analyzing the rust-ethereum/evm implementation rather than making changes here.

Additionally, the value immediately following the function signature (4 bytes) in the revert data is the data offset, not reason_uint as suggested in your changes. For reference, you can find more details about the format in the Solidity documentation.

@boundless-forest
Copy link
Collaborator

Does your solution follow the currently existing Ethereum clients like Geth or REth? Please provide more test cases for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants