Skip to content

feat: introduce eth lockbox#14588

Merged
smartcontracts merged 39 commits intoethereum-optimism:feat/interop-portal-updatesfrom
defi-wonderland:feat/introduce-eth-lockbox
Mar 8, 2025
Merged

feat: introduce eth lockbox#14588
smartcontracts merged 39 commits intoethereum-optimism:feat/interop-portal-updatesfrom
defi-wonderland:feat/introduce-eth-lockbox

Conversation

@agusduha
Copy link
Copy Markdown
Contributor

Description

Introducing the ETHLockbox contract to improve the Superchain’s interoperable ETH withdrawal user experience, preventing withdrawal failures caused by insufficient ETH in the OptimismPortal.

Design doc: ethereum-optimism/design-docs#206
Spec: ethereum-optimism/specs#465

smartcontracts and others added 5 commits February 28, 2025 10:27
Updates the OptimismPortal to use the AnchorStateRegistry as the
source of truth for the validity of Dispute Game contracts.
* feat: create new eth lockbox contract with interface

* chore: add it on the deployment scripts (wip)

* feat: create the test base to check if the setup for it is working

* feat: add all eth lockbox tests

* fix: opcm deployment script issue

* fix: lockbox tests

* feat: add no withdrawal tx unlock eth check

* chore: check proper initialization on test

* fix: pre-pr fixes

* chore: run pre-pr

* fix: opcm tests related to eth lockbox

* feat: add admin owner check on authorize portal and lockbox as well

* refactor: add prefix to errors and declare them on contract

* chore add no withdrawal tx comment

* feat: authorize portal in lockbox on the opcm

* chore: add one more check for eth lockbox

* fix: intializable and specs tests

* fix: pre-pr
* feat: integrate portal with lockbox

* fix: migrate natspec

Co-authored-by: Disco <131301107+0xDiscotech@users.noreply.github.com>

* fix: delete natspec

Co-authored-by: Disco <131301107+0xDiscotech@users.noreply.github.com>

* fix: natspec nits

* chore: natspec wording

* chore: function order

* chore: remove internals

* feat: add eth lockbox as portal arg on opcm

* feat: add checks on scripts and unit tests

* feat: lock and unlock tests

* feat: add migrate liquidity tests

* fix: other failing portal tests

* chore: run pre-pr

* chore: improve lock and unlock checks on tests

* chore: undo portal version change and run pre-pr

* refactor: enhance expect call checks

* fix: fork test string error

* fix: just test failing tests

* refactor: pao base

* refactor: setup portal and lockbox integration on initialization

* feat: update lockbox setter

* chore: update pao naming on tests

* chore: portal comment

* chore: update version and run pre-pr

* fix: spec

* fix: lockbox storage layout

* fix: pr comments and failing test

* feat: portal upgrade test

* chore: remove portal balance check on chain assertions

* fix: error string on chain assertions

* feat: add test for portal unsafe target

* fix: approval

---------

Co-authored-by: Disco <131301107+0xDiscotech@users.noreply.github.com>
@agusduha agusduha requested a review from a team as a code owner February 28, 2025 17:30
@agusduha agusduha requested review from mbaxter, mds1 and smartcontracts and removed request for a team and mbaxter February 28, 2025 17:30
@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize a381511

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 878d2a9

0xDiscotech and others added 2 commits March 3, 2025 12:02
* chore: remove unused function

* chore: add pao validation checks over portal and lockbox

* refactor: use interface as arg type instead of address on functions

* fix: comment max length

* refactor: update lockbox param type as interface

* refactor: use interface as type on migrate liquidity and authorize lockbox functions

* chore: run pre pr

* fix: high fuzz runs failing test using mostly assume not forge address

* refactor: use ioptimis portal instead of ioptimism portal2 everywhere

* chore: undo changes on unrelated files to the pr
Updates the OptimismPortal to include a method that allows users
to prove against Super Roots for interop.
0xDiscotech and others added 6 commits March 3, 2025 17:28
* chore: undo initializable v5 test changes

* chore: remove portal already authorized check

* chore: remove portal already authorized check

* refactor: rename pao to proxy admin owner
…pwd-super-roots

feat: add Super Root specific method to OptimismPortal
* fix: test upgrade fails

* feat: handle fork state on eth lockbox tests

* chore: enhance comments

* chore: run pre-pr

* fix: semgrep

* fix: comments

* chore: address path where is not a fork to get the lockbox

* chore: run pre pr
Copy link
Copy Markdown
Contributor

@smartcontracts smartcontracts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Broadly looking quite good, pending CI

…e number (#303)

* fix: include lockbox on reinitialization test

* fix: polish nits

* refactor: get eth lockbox on test condition

* chore: add todos pointing to the issue
@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 859810a

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 23f5395

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 151b18f

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 5c59150

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 5311c21

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize b1b6ecc

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 8f150df

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 93c578d

@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize ae4dfad

* chore: remove unnecessary cast

* refactor: add lockbox on eth migrated event

* chore: rename pa owner to pa owned base

* refactor: add amount on liquidity received and migrated events

* fix: format

* refactor: add amount on liquidity migrated event

* chore: pre-pr

---------

Co-authored-by: agusduha <agusnduha@gmail.com>
@smartcontracts
Copy link
Copy Markdown
Contributor

/ci authorize 3f59cf0

@smartcontracts smartcontracts merged commit 7a771e6 into ethereum-optimism:feat/interop-portal-updates Mar 8, 2025
45 of 47 checks passed
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.

6 participants