Skip to content

Sync Committee: Initial Batch Construction#600

Merged
zadykian merged 1 commit intomainfrom
sync-committee/aggregator-genesis
Mar 24, 2025
Merged

Sync Committee: Initial Batch Construction#600
zadykian merged 1 commit intomainfrom
sync-committee/aggregator-genesis

Conversation

@zadykian
Copy link
Copy Markdown
Contributor

Sync Committee: Initial Batch Construction

To align with state root initialization on the Proposer side, the latest proved state root (or genesis block) is used as a starting point in the Aggregator as well.

  • Implemented the getStartingBlockRef() method, which retrieves the starting point for the next fetching iteration, prioritizing the latest fetched block if available;
  • If neither LatestFetched nor LatestProvedStateRoot is defined, the method returns ErrStateRootNotInitialized;
  • Added a check to verify whether the LatestFetched block exists on L2, triggering a reset if it does not (requireBlockExistsInChain);

In short, LatestProvedStateRoot must now be initialized to be used by Aggregator as the starting point for block processing

@zadykian zadykian self-assigned this Mar 19, 2025
@zadykian zadykian changed the title ### Sync Committee: Initial Batch Construction Sync Committee: Initial Batch Construction Mar 19, 2025
@notion-workspace
Copy link
Copy Markdown

@zadykian zadykian marked this pull request as ready for review March 19, 2025 12:18
To align with state root initialization on the `Proposer` side,
the latest proved state root (or genesis block) is used as a starting point in the Aggregator as well.

* Implemented the `getStartingBlockRef()` method, which retrieves the starting point for the next fetching iteration, prioritizing the latest fetched block if available;
* If neither `LatestFetched` nor `LatestProvedStateRoot` is defined, the method returns `ErrStateRootNotInitialized`;
* Added a check to verify whether the `LatestFetched` block exists on L2, triggering a reset if it does not (`requireBlockExistsInChain`);

In short, `LatestProvedStateRoot` must now be initialized to be used by `Aggregator` as the starting point for block processing
@zadykian zadykian added this pull request to the merge queue Mar 24, 2025
Merged via the queue into main with commit 34ba236 Mar 24, 2025
14 checks passed
@zadykian zadykian deleted the sync-committee/aggregator-genesis branch March 24, 2025 13:01
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.

2 participants