Skip to content

feat(p2p): reject and evict txs with insufficient max fee per gas (backport #21281)#21431

Closed
AztecBot wants to merge 4 commits intobackport-to-v4-next-stagingfrom
claudebox/backport-21281-reject-evict-txs-v4-next
Closed

feat(p2p): reject and evict txs with insufficient max fee per gas (backport #21281)#21431
AztecBot wants to merge 4 commits intobackport-to-v4-next-stagingfrom
claudebox/backport-21281-reject-evict-txs-v4-next

Conversation

@AztecBot
Copy link
Copy Markdown
Collaborator

Summary

Backport of #21281 to v4-next.

  • Changes GasTxValidator to return invalid instead of skipped when a tx's maxFeesPerGas is below current block fees, rejecting the tx outright.
  • Extracts MaxFeePerGasValidator as a standalone generic validator so it can be used in pool migration alongside full Tx validation.
  • Adds InsufficientFeePerGasEvictionRule that evicts pending txs after a new block is mined if their maxFeesPerGas no longer meets the block's gas fees.
  • Adds maxFeesPerGas to TxMetaValidationData so the eviction rule and pool migration validator can access it from metadata.

Conflict Resolution

One conflict resolved:

  • yarn-project/end-to-end/src/spartan/block_capacity.test.ts: modify/delete conflict — file was deleted in v4-next but modified in the source PR. Resolved by dropping the file since it doesn't exist on v4-next.

Commit Structure

  1. Cherry-pick commit — original cherry-pick with conflict recorded in history
  2. Conflict resolution — removes the deleted file

ClaudeBox log: https://claudebox.work/s/f3e3c07614d5a047?run=1

@AztecBot AztecBot added the claudebox Owned by claudebox. it can push to this PR. label Mar 12, 2026
@ludamad ludamad force-pushed the backport-to-v4-next-staging branch from 5c50c04 to 4eb8703 Compare March 12, 2026 19:33
@ludamad ludamad force-pushed the claudebox/backport-21281-reject-evict-txs-v4-next branch from 9936b53 to 5f8f38b Compare March 12, 2026 19:40
nchamo and others added 4 commits March 13, 2026 11:59
…with public functions (#20775)

Cherry-pick of cee97a1 with conflicts.
Resolved conflicts in:
- docs/docs-developers/docs/resources/migration_notes.md
- noir-projects/aztec-nr/aztec/src/macros/aztec.nr
- noir-projects/noir-protocol-circuits/crates/types/src/constants.nr
- noir-projects/noir-protocol-circuits/crates/types/src/constants_tests.nr
- yarn-project/end-to-end/src/composed/ha/e2e_ha_full.test.ts
…e per gas (#21281)

Cherry-pick of 9e2d79c with conflicts.

Conflicts:
- yarn-project/end-to-end/src/spartan/block_capacity.test.ts: modify/delete conflict
  (deleted in v4-next, modified in source)
Remove yarn-project/end-to-end/src/spartan/block_capacity.test.ts which was deleted
in v4-next but modified by the cherry-picked commit. The file does not exist on the
target branch so the modification is dropped.
@AztecBot AztecBot changed the base branch from backport-to-v4-next-staging to claudebox/backport-20775-v4-next March 13, 2026 12:00
@AztecBot AztecBot force-pushed the claudebox/backport-21281-reject-evict-txs-v4-next branch from 5f8f38b to 96d4ab8 Compare March 13, 2026 12:00
@AztecBot AztecBot changed the base branch from claudebox/backport-20775-v4-next to claudebox/ff2dd4f68e9ac0be-2 March 13, 2026 13:41
Base automatically changed from claudebox/ff2dd4f68e9ac0be-2 to backport-to-v4-next-staging March 13, 2026 13:52
@spalladino spalladino closed this Mar 13, 2026
@spalladino
Copy link
Copy Markdown
Contributor

We have reverted the original PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claudebox Owned by claudebox. it can push to this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants