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

Refactoring CSM startup #163

Merged
merged 18 commits into from
Jul 26, 2024
Merged

Refactoring CSM startup #163

merged 18 commits into from
Jul 26, 2024

Conversation

delbonis
Copy link
Contributor

@delbonis delbonis commented Jul 22, 2024

We likely will want to have deposits into the rollup preceeding genesis, so we can have activity in the rollup at genesis. So we now differentiate a "horizon" L1 block and a "L2 genesis" L1 block, and process stuff between these two blocks and after the L2 genesis L1 block is fairly buried we now initiate genesis, which is computed by the worker task I think, which kicks off the FCM to start running. The genesis block is computed strictly from the L1 data. This design and the requirements for it (and its downstream implications) wasn't immediately obvious until ~2 weeks ago. Another motivation was to clean up the startup process, which was previously really hacky because of changes made after another feature that was added and I forgot the specifics for why that happens. Regardless, this will clean up the startup process a bunch.

Closes #107
Closes #123
Closes #141
Closes #161

This ended up being bigger than I thought.

@delbonis delbonis requested a review from bewakes July 22, 2024 03:13
@delbonis delbonis marked this pull request as ready for review July 25, 2024 00:36
@delbonis delbonis force-pushed the feature/timely-l2-genesis branch 2 times, most recently from 7efb4b5 to 5594b49 Compare July 25, 2024 21:27
@delbonis
Copy link
Contributor Author

delbonis commented Jul 25, 2024

Okay this is rebased onto master, should be reviewed. There's more I'd like to do to clean up stuff around this but we should ship this for now.

@delbonis delbonis requested a review from prajwolrg July 25, 2024 21:42
@delbonis delbonis force-pushed the feature/timely-l2-genesis branch from 4e03a47 to cfff4e5 Compare July 26, 2024 14:31
@delbonis delbonis force-pushed the feature/timely-l2-genesis branch from 22a1d83 to 0a66c57 Compare July 26, 2024 14:39
Copy link

codecov bot commented Jul 26, 2024

Codecov Report

Attention: Patch coverage is 0.57034% with 523 lines in your changes missing coverage. Please review.

Project coverage is 49.85%. Comparing base (89d7117) to head (3ab5fb0).

@@            Coverage Diff             @@
##           master     #163      +/-   ##
==========================================
- Coverage   52.65%   49.85%   -2.81%     
==========================================
  Files          79       80       +1     
  Lines        6567     6880     +313     
==========================================
- Hits         3458     3430      -28     
- Misses       3109     3450     +341     
Files Coverage Δ
crates/consensus-logic/src/errors.rs 0.00% <ø> (ø)
crates/consensus-logic/src/message.rs 0.00% <ø> (ø)
crates/primitives/src/params.rs 0.00% <ø> (ø)
crates/state/src/sync_event.rs 100.00% <ø> (ø)
crates/consensus-logic/src/state_tracker.rs 0.00% <0.00%> (ø)
crates/state/src/chain_state.rs 60.00% <50.00%> (-28.24%) ⬇️
sequencer/src/l1_reader.rs 0.00% <0.00%> (ø)
crates/consensus-logic/src/duty_extractor.rs 0.00% <0.00%> (ø)
crates/state/src/l1.rs 21.81% <0.00%> (+0.32%) ⬆️
crates/consensus-logic/src/duty_executor.rs 0.00% <0.00%> (ø)
... and 10 more

... and 1 file with indirect coverage changes

@delbonis
Copy link
Contributor Author

Ignoring coverage report for now.

@delbonis
Copy link
Contributor Author

Merging because a bunch of stuff is blocked on this PR.

@delbonis delbonis merged commit 0ebed36 into master Jul 26, 2024
13 of 22 checks passed
@storopoli storopoli deleted the feature/timely-l2-genesis branch November 28, 2024 10:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant