getL2Output reverts if not found#2979
Conversation
🦋 Changeset detectedLatest commit: ad77328 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Hey @maurelian! This PR has merge conflicts. Please fix them before continuing review. |
c64b175 to
5a7873b
Compare
|
@smartcontracts: I discussed this change with @tynes. Would appreciate your input before I spend time debuggin the go tests. |
5a7873b to
90478ca
Compare
|
Hey @maurelian! This PR has merge conflicts. Please fix them before continuing review. |
90478ca to
dc46973
Compare
dc46973 to
a57ead4
Compare
|
Hey @maurelian! This PR has merge conflicts. Please fix them before continuing review. |
a57ead4 to
235dba7
Compare
|
@mergify refresh |
✅ Pull request refreshed |
|
Hey @maurelian! This PR has merge conflicts. Please fix them before continuing review. |
9fdcbe9 to
4d4e89d
Compare
|
Hey @maurelian! This PR has merge conflicts. Please fix them before continuing review. |
82017d8 to
cbfb4e8
Compare
|
@mergify refresh |
✅ Pull request refreshed |
cbfb4e8 to
efb96fd
Compare
|
@mergify refresh |
✅ Pull request refreshed |
feat(bedrock): Handle error on empty output in Portal feat(ctb): use isOutputFinalized in finalizeWithdrawalTx
Revert "feat(ctb): use isOutputFinalized in finalizeWithdrawalTx" This reverts commit 4d4e89d. ctb: getL2Output returns the next output for a block ctb: Fix error message style
a6e9bf4 to
ad77328
Compare
|
This PR has been added to the merge queue, and will be merged soon. |
|
This PR is next in line to be merged, and will be merged as soon as checks pass. |
Description
Calls to
oracle.getL2Outputrevert if no output is found for the given block number.Pros:
Reverting on blocks which are not found forces 3rd parties to consider and handle this failure mode, instead of possibly missing this 'edge case'. This feels more semantically correct, and is similar to how many of ERC721's functions handle non-existent token IDs (ex. getApproved).
Cons:
This change forces us to introduce some pretty ugly try/catch code in
isOutputFinalized().Metadata