fix: backport timestamp and anvil fixes#22110
Merged
spalladino merged 11 commits intobackport-to-v4-next-stagingfrom Mar 30, 2026
Merged
fix: backport timestamp and anvil fixes#22110spalladino merged 11 commits intobackport-to-v4-next-stagingfrom
spalladino merged 11 commits intobackport-to-v4-next-stagingfrom
Conversation
…ery mined block (with conflicts)
…k (with conflicts)
…tests (with conflicts)
… eth_simulateV1 timestamp (with conflicts)
Resolves conflicts from cherry-picking PRs #21829, #21853, #21869, #22023. Key resolutions: - start_anvil.ts: take full rewrite from PR #21829 (spawn-based instead of @viem/anvil) - sequencer-publisher.ts: use getNextL1SlotTimestamp with pipelining (PR #21853), getSimulationTimestamp for simulation timestamps (PR #22023), add aztecSlotDuration property - setup.ts: add slotsInAnEpoch and dateProvider options - slasher_config.test.ts: add anvilSlotsInAnEpoch option - checkpoint_voter test: add epochCache mock methods - Drop backupFailedTx calls (infrastructure not on this branch)
All conflicts were about dateProvider support from PR #21829 - take our version.
b5b52f4 to
5c1e180
Compare
- Add aztecSlotDuration to SequencerPublisher constructor call sites - Replace isProposerPipeliningEnabled (not on this branch) with false default - Remove getSlotNow mock (not on this branch's EpochCache) - Fix eth.timestamp() -> eth.lastBlockTimestamp() in e2e test - Revert update to noir-repo submodule - Delete claude settings.local.json
5c1e180 to
f818201
Compare
Tests were failing with 'Cannot convert undefined to a BigInt' because mock configs didn't include aztecSlotDuration.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Backport deflaking fixes from next: send deploy tx before call tx with a 1s propagation delay instead of sending both simultaneously, and add retryUntil poll in assertMultipleBlocksPerSlot to handle archiver sync race. Originally fixed in #21003 and #21026. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Collaborator
Flakey Tests🤖 says: This CI run detected 1 tests that failed, but were tolerated due to a .test_patterns.yml entry. |
PhilWindle
approved these changes
Mar 30, 2026
| const ignoredErrors = ['SlotAlreadyInChain', 'InvalidProposer', 'InvalidArchive']; | ||
|
|
||
| const nextL1SlotTs = await this.getNextL1SlotTimestampWithL1Floor(); | ||
| const pipelined = opts.pipelined ?? false; |
Collaborator
There was a problem hiding this comment.
This looks safe but apears to be a pipelining change. Is this expected?
Contributor
Author
There was a problem hiding this comment.
Good catch, let me look into it
Contributor
Author
There was a problem hiding this comment.
It wasn't expected, but doesn't hurt either, it'll always be falsey here since callers don't set it.
AztecBot
added a commit
that referenced
this pull request
Mar 31, 2026
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.
Backport PRs to
backport-to-v4-next-stagingCherry-picked the following PRs (in order) on top of the branch, committing each with conflicts unresolved:
fix: sync dateProvider from anvil stdout on every mined blockfix(sequencer): remove l1 block timestamp checkfix(e2e): set anvilSlotsInAnEpoch in slashing testsfix(sequencer): use last L1 slot of L2 slot as eth_simulateV1 timestampConflict resolution
Added a single commit resolving all cherry-pick conflicts:
yarn-project/ethereum/src/test/start_anvil.ts: Took the full rewrite from PR fix: sync dateProvider from anvil stdout on every mined block #21829, replacing the@viem/anvil-based implementation with a directchild_process.spawnapproach. Updatedstart_anvil.test.tsto import the new localAnviltype instead of@viem/anvil.yarn-project/end-to-end/src/fixtures/setup.ts: AddedslotsInAnEpochanddateProvideroptions to thestartAnvilcall.yarn-project/end-to-end/src/e2e_sequencer/slasher_config.test.ts: AddedanvilSlotsInAnEpoch: 4option to thesetupcall.yarn-project/sequencer-client/src/sequencer/checkpoint_voter.ha.integration.test.ts: AddedepochCache.getSlotNowandepochCache.getL1Constantsmock return values.yarn-project/sequencer-client/src/publisher/sequencer-publisher.ts:canProposeAt: ReplacedgetNextL1SlotTimestampWithL1Floor()withgetNextL1SlotTimestamp()plus pipelining offset (PR fix(sequencer): remove l1 block timestamp check #21853). Addedpipelined?: booleanto the opts type.validateCheckpointForSubmission: Changed return type toPromise<void>, removed manual timestamp computation (PR fix(sequencer): use last L1 slot of L2 slot as eth_simulateV1 timestamp #22023).enqueueCastSignalHelper/simulateProposeTx: UsegetSimulationTimestamp()for simulation timestamps, improved error logging withformatViemError(PR fix(sequencer): use last L1 slot of L2 slot as eth_simulateV1 timestamp #22023).aztecSlotDurationclass property and wired it through the config.backupFailedTxcalls since the underlyingFailedL1Tx/createL1TxFailedStoreinfrastructure does not exist on this branch.