Skip to content

chore: add rebuild integration test for unrelated L2 txs#1107

Open
romanbrodetski-ai wants to merge 11 commits intomatter-labs:mainfrom
romanbrodetski-ai:upstream-main-pr3-rebuild-integration-test
Open

chore: add rebuild integration test for unrelated L2 txs#1107
romanbrodetski-ai wants to merge 11 commits intomatter-labs:mainfrom
romanbrodetski-ai:upstream-main-pr3-rebuild-integration-test

Conversation

@romanbrodetski-ai
Copy link
Copy Markdown
Contributor

Summary

Add a rebuild integration test and the small harness hook needed to restart the node with rebuild config overrides.

Why

This captures the regression where rebuilding after emptying a historical block must still preserve unrelated L2 transactions in later blocks.

Validation

  • cargo nextest run -p zksync_os_integration_tests -E 'test(=node::rebuild::rebuild_after_emptying_historical_block_preserves_unrelated_l2_txs::current_to_l1)' --no-capture

RomanBrodetski pushed a commit that referenced this pull request Mar 30, 2026
## Summary
Wait for the previous block to be fully applied before executing the
next one, using the startup block boundary as intial value

## Why
This removes a race between BlockExecutor and BlockApplier during replay
and rebuild.

This fix is necessary for #1107 to succeed.

## Validation
- the targeted rebuild integration test in #1107 passes with this fix in
place

Co-authored-by: romanbrodetski-ai <romanbrodetski-ai@users.noreply.github.com>
RomanBrodetski pushed a commit that referenced this pull request Mar 30, 2026
## Summary
Make invalid-tx handling configurable so rebuild skips invalid
transactions without marking the live tx source entry invalid.

## Why
This was panicing for Rebuilds - as there is no actual (markable) pool
int that case

This fix is necessary for #1107 to succeed.

## Validation
- the targeted rebuild integration test in #1107 passes with this fix in
place

---------

Co-authored-by: romanbrodetski-ai <romanbrodetski-ai@users.noreply.github.com>
@romanbrodetski-ai romanbrodetski-ai force-pushed the upstream-main-pr3-rebuild-integration-test branch from 48993a3 to 0bdb89e Compare March 30, 2026 11:08
@romanbrodetski-ai romanbrodetski-ai force-pushed the upstream-main-pr3-rebuild-integration-test branch from 5326be2 to cbee95f Compare March 30, 2026 13:57
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