ethereum-optimism / optimistic-specs

Optimistic: Bedrock, is a protocol that strives to be an extremely simple optimistic rollup that maintains 1:1 compatibility with Ethereum
MIT License
168 stars 36 forks source link

feature request: Add revert reason to FailedRelayedMessage event #289

Open transmissions11 opened 3 years ago

transmissions11 commented 3 years ago

Is your feature request related to a problem? Please describe. It's a real pain to debug L1->L2 messages that revert when they're relayed. This is because they just show a generic "evm execution reverted" error.

Example: https://kovan-optimistic.etherscan.io/tx/0x647991fe8282b4ddd1fdb8dd201c412adc6cbb92eba021f47be182a8a0dfe00e/advanced

Describe the solution you'd like Adding the error message into FailedRelayedMessage would allow block explorers or the watcher to alert users and devs of why the relay failed, making it easier to debug.

Describe alternatives you've considered Doing a trace and looking directly for the revert in l2geth and exposing this to etherscan?

smartcontracts commented 3 years ago

Won't make it into 0.5.0 but this is a great candidate for 1.0.0.

protolambda commented 2 years ago

In bedrock the L1 to L2 messages have their own deposit txs, and the relay / entry-point on L2 is customizable. (there will likely be an encouraged default though that can replay failed deposit execution, and there this feedback is still useful). cc @maurelian