feat: custom gas token#17320
Closed
hexshire wants to merge 12 commits intoethereum-optimism:feat/cgtfrom
Closed
Conversation
Signed-off-by: Hex <165055168+hexshire@users.noreply.github.com> Co-authored-by: niha <205694301+0xniha@users.noreply.github.com> Co-authored-by: Ashitaka <96790496+ashitakah@users.noreply.github.com> Co-authored-by: AgusDuha <81362284+agusduha@users.noreply.github.com>
chore(cgt): sync develop
Contributor
|
/ci authorize 1026df6 |
* feat: add L1BlockCGT * feat: add L2ToL1MessagePasserCGT * chore: remove test exclution in test validation
* test(cgt): fix failing tests * test(cgt): fix portal version * test(cgt): skip tests on forked mode * fix: predeploys test cgt mismatch * test(cgt): minor fixes --------- Co-authored-by: niha <205694301+0xniha@users.noreply.github.com>
Contributor
|
/ci authorize 4590fa8 |
| }, | ||
| CustomGasToken: &CustomGasToken{ | ||
| Enabled: false, | ||
| Name: "Test", |
Contributor
There was a problem hiding this comment.
Name/Symbol should be empty since Enabled is false?
tynes
reviewed
Sep 8, 2025
| if len(chain.AdditionalDisputeGames) > 0 { | ||
| return fmt.Errorf("%w: chainId=%s additionalDisputeGames must be nil", ErrNonStandardValue, chain.ID) | ||
| } | ||
| if chain.CustomGasToken != nil && (chain.CustomGasToken.Enabled != standard.CustomGasTokenEnabled) { |
Contributor
There was a problem hiding this comment.
This is something that we may need to revisit
tynes
reviewed
Sep 8, 2025
| @@ -125,6 +125,9 @@ contract OptimismPortal2 is Initializable, ResourceMetering, ReinitializableBase | |||
| /// @notice Whether the OptimismPortal is using Super Roots or Output Roots. | |||
Contributor
There was a problem hiding this comment.
We may need to break this out into its own contract pending some open decisions on the rollout, will follow up as soon as possible
Contributor
|
We will want to add a flag that enables the ability to set the amount of liquidity in the native asset liquidity contract so that it can be set to 0 for chains that would like that usecase |
Closed
Contributor
|
Closing in favor of #17412 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Enables OP Stack chains to use an asset other than ETH as their native fee currency by introducing a minimal, flexible, and standardizable Custom Gas Token (CGT) architecture. To do so, it introduces new predeploys (
NativeAssetLiquidityandLiquidityController) that decouple native asset management from core bridging operations while using a singleisCustomGasToken()flag that disables ETH transfer flows in all bridging methods. The two new pre-deploys manage the native asset supply.Tests
Core contracts:
OptimismPortalandL1Block: Tests forisCustomGasToken()flag blocking ETH deposits/withdrawalsNativeAssetLiquidity: Tests deposit/withdraw access control and functionalityLiquidityController: Tests minter authorization, mint/burn operations, and metadata functionsMetadata
Contributors