Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

op-e2e: Nuke allocs #13364

Merged
merged 10 commits into from
Dec 14, 2024
Merged

op-e2e: Nuke allocs #13364

merged 10 commits into from
Dec 14, 2024

Conversation

mslipper
Copy link
Collaborator

This PR integrates op-deployer with op-e2e for the purposes of generating L1/L2 allocs on-the-fly. As a result, there is no longer any need to run make devnet-allocs or otherwise continue maintaining the legacy Python devnet. The generated allocs are at parity with those generated by the Python devnet - i.e., they contain the Alphabet VM, the fast fault game, and the deploy config customizations in devnetL1.json.

One notable change here is that the ability to generate new allocs files for L2OO chains will no longer be possible post-Holocene. To continue supporting the L2OO tests for the time being, the L2OO allocs files have been archived at the Holocene fork.

Cleaning up the old devnet will be handled separately.

@mslipper mslipper requested review from a team as code owners December 11, 2024 21:22
Copy link

codecov bot commented Dec 11, 2024

Codecov Report

Attention: Patch coverage is 73.22835% with 34 lines in your changes missing coverage. Please review.

Project coverage is 47.34%. Comparing base (3c27ab2) to head (353275e).
Report is 18 commits behind head on develop.

Files with missing lines Patch % Lines
op-chain-ops/foundry/allocs.go 0.00% 8 Missing ⚠️
op-deployer/pkg/deployer/artifacts/locator.go 0.00% 6 Missing ⚠️
op-deployer/pkg/deployer/pipeline/dispute_games.go 79.31% 4 Missing and 2 partials ⚠️
op-deployer/pkg/deployer/opcm/anchor_roots.go 84.21% 2 Missing and 1 partial ⚠️
op-deployer/pkg/deployer/pipeline/opchain.go 84.21% 2 Missing and 1 partial ⚠️
op-service/util.go 0.00% 3 Missing ⚠️
op-deployer/pkg/deployer/opcm/l2genesis.go 0.00% 2 Missing ⚠️
op-deployer/pkg/deployer/pipeline/init.go 33.33% 0 Missing and 2 partials ⚠️
op-deployer/pkg/deployer/state/deploy_config.go 90.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #13364      +/-   ##
===========================================
+ Coverage    47.13%   47.34%   +0.20%     
===========================================
  Files          938      939       +1     
  Lines        78365    78464      +99     
  Branches       796      796              
===========================================
+ Hits         36940    37151     +211     
+ Misses       38697    38536     -161     
- Partials      2728     2777      +49     
Flag Coverage Δ
cannon-go-tests-32 62.23% <ø> (ø)
cannon-go-tests-64 57.20% <ø> (ø)
contracts-bedrock-tests 91.76% <ø> (+2.67%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
op-chain-ops/interopgen/deploy.go 72.32% <100.00%> (+0.10%) ⬆️
op-deployer/pkg/deployer/inspect/l1.go 77.77% <100.00%> (+77.77%) ⬆️
...deployer/pkg/deployer/opcm/dispute_game_factory.go 100.00% <ø> (ø)
op-deployer/pkg/deployer/opcm/mips.go 100.00% <ø> (+33.33%) ⬆️
op-deployer/pkg/deployer/opcm/opchain.go 0.00% <ø> (ø)
op-deployer/pkg/deployer/state/chain_intent.go 82.35% <ø> (ø)
op-deployer/pkg/deployer/state/intent.go 45.37% <ø> (ø)
op-deployer/pkg/deployer/state/deploy_config.go 82.75% <90.00%> (ø)
op-deployer/pkg/deployer/opcm/l2genesis.go 0.00% <0.00%> (ø)
op-deployer/pkg/deployer/pipeline/init.go 59.40% <33.33%> (ø)
... and 6 more

... and 32 files with indirect coverage changes

@mslipper mslipper force-pushed the feat/nuke-allocs branch 2 times, most recently from e20282f to f798a03 Compare December 11, 2024 21:34
@mslipper mslipper marked this pull request as draft December 11, 2024 22:01
This PR integrates op-deployer with op-e2e for the purposes of generating L1/L2 allocs on-the-fly. As a result, there is no longer any need to run `make devnet-allocs` or otherwise continue maintaining the legacy Python devnet. The generated allocs are at parity with those generated by the Python devnet - i.e., they contain the Alphabet VM, the fast fault game, and the deploy config customizations in `devnetL1.json`.

One notable change here is that the ability to generate new allocs files for L2OO chains will no longer be possible post-Holocene. To continue supporting the L2OO tests for the time being, the L2OO allocs files have been archived at the Holocene fork.

Cleaning up the old devnet will be handled separately.
@mslipper mslipper marked this pull request as ready for review December 12, 2024 05:20
Copy link
Member

@sebastianst sebastianst left a comment

Choose a reason for hiding this comment

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

Mainly reviewed the op-e2e init and setup code, which lgtm. A couple non-blocking comments and suggestions.

An alternative pattern to creating the allocs in init() could be to use lazy-initialization for each alloc type, so that they are created on demand the first time they are used, e.g. using sync.Once or sync.OnceValue.

op-e2e/config/init.go Show resolved Hide resolved
op-e2e/config/init.go Show resolved Hide resolved
op-e2e/config/init.go Show resolved Hide resolved
op-e2e/config/init.go Show resolved Hide resolved
op-e2e/config/init.go Show resolved Hide resolved
op-e2e/config/init.go Outdated Show resolved Hide resolved
op-e2e/config/init.go Outdated Show resolved Hide resolved
op-deployer/pkg/deployer/inspect/l1.go Show resolved Hide resolved
op-e2e/config/init.go Show resolved Hide resolved
op-deployer/pkg/deployer/state/intent.go Outdated Show resolved Hide resolved
Copy link
Contributor

@tynes tynes left a comment

Choose a reason for hiding this comment

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

This is a great step forward! Would be amazing if in the future we can decouple from the idea of allocs type and instead just run op-deployer in an EVM backend that can be cloned and handed off to different tests. This would let us skip needing to generate all of the allocs and write them to disk which would reduce a ton of boilerplate with setting up a hardfork, since there is 1 alloc file written to disk per hardfork

@mslipper mslipper added this pull request to the merge queue Dec 14, 2024
Merged via the queue into develop with commit 6823d67 Dec 14, 2024
42 checks passed
@mslipper mslipper deleted the feat/nuke-allocs branch December 14, 2024 00:09
mslipper added a commit that referenced this pull request Dec 14, 2024
sigma pushed a commit that referenced this pull request Dec 19, 2024
* op-e2e: Nuke allocs

This PR integrates op-deployer with op-e2e for the purposes of generating L1/L2 allocs on-the-fly. As a result, there is no longer any need to run `make devnet-allocs` or otherwise continue maintaining the legacy Python devnet. The generated allocs are at parity with those generated by the Python devnet - i.e., they contain the Alphabet VM, the fast fault game, and the deploy config customizations in `devnetL1.json`.

One notable change here is that the ability to generate new allocs files for L2OO chains will no longer be possible post-Holocene. To continue supporting the L2OO tests for the time being, the L2OO allocs files have been archived at the Holocene fork.

Cleaning up the old devnet will be handled separately.

* fix broken tests

* bring back l2oo test

* swap more keys

* more keys

* swap prestates

* remove dead code

* fix prestate proof

* Code review updates

* toml fields
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