chore: backport #21075 to v4 (decouple proposal validators via composition)#21120
Merged
spalladino merged 1 commit intov4from Mar 4, 2026
Merged
chore: backport #21075 to v4 (decouple proposal validators via composition)#21120spalladino merged 1 commit intov4from
spalladino merged 1 commit intov4from
Conversation
…sition Remove pass-through getters (blockNumber, txHashes, txs) from CheckpointProposal that just delegated to lastBlock. Split ProposalValidator into header validation (validate) and tx validation (validateTxs). BlockProposalValidator and CheckpointProposalValidator now use ProposalValidator by composition instead of inheritance, calling validate() for header checks and validateTxs() for tx checks (on the block proposal directly or via getBlockProposal()). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4aa5498 to
1d5ed19
Compare
spalladino
approved these changes
Mar 4, 2026
Collaborator
Author
Flakey Tests🤖 says: This CI run detected 1 tests that failed, but were tolerated due to a .test_patterns.yml entry. |
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.
Summary
Backport of #21075 to v4.
blockNumber,txHashes,txs) fromCheckpointProposalthat just delegated tolastBlockProposalValidatorinto header validation (validate) and tx validation (validateTxs)BlockProposalValidatorandCheckpointProposalValidatornow useProposalValidatorby composition instead of inheritanceproposal_validator.test.tsthat testsProposalValidatordirectly with both proposal typesConflict resolution
The automatic cherry-pick failed due to modify/delete conflicts on two test files:
checkpoint_proposal_validator.test.ts— modified on v4, deleted in PRproposal_validator_test_suite.ts— modified on v4, deleted in PRResolution: accepted the deletions since the PR replaces both files with a new consolidated
proposal_validator.test.tsthat covers all test cases from both files.Test plan
ClaudeBox log: http://ci.aztec-labs.com/5e44af188aafe7dc-1