Skip to content

Add a max-fee-per-gas headroom factor to the driver gas config - #4871

Draft
squadgazzz wants to merge 1 commit into
mainfrom
driver-max-fee-headroom
Draft

Add a max-fee-per-gas headroom factor to the driver gas config#4871
squadgazzz wants to merge 1 commit into
mainfrom
driver-max-fee-headroom

Conversation

@squadgazzz

@squadgazzz squadgazzz commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Description

When mainnet base fee jumps between the moment a settlement is submitted and the moment it would be included, the transaction can end up stranded below the new base fee and expires unmined. We saw a burst of these during the Sep 4 gas spike (0.7 to ~4.75 gwei in a few minutes): valid solutions that never landed because their max_fee_per_gas was set from a pre-spike estimate.

Today the driver submits with exactly the estimator's max_fee_per_gas (only raised to cover the tip, then capped at gas-price-cap), with no headroom. This adds a configurable factor on top of the estimate.

max_fee_per_gas is a ceiling, not the amount paid: a settlement always pays the real base_fee + priority_fee. So extra headroom changes nothing in calm conditions and only bites when base fee rises after submission. Unlike raising the priority fee, it does not add per-settlement cost, and it is a separate lever from the tip aimed at the expiry case.

The default is 1.0, so behavior is unchanged until a network opts in via config.

Changes

  • Added a max-fee-per-gas-factor option to the driver [submission] config, defaulting to 1.0 (no headroom)
  • Applied the factor to the estimated max_fee_per_gas before the gas-price cap check, in the driver's gas price estimator

How to test

Existing tests. The default of 1.0 is a no-op; set it above 1.0 for a network and confirm submitted transactions carry a proportionally higher max_fee_per_gas while the effective price paid still tracks base fee plus tip.

@squadgazzz
squadgazzz force-pushed the driver-max-fee-headroom branch from bcf4af3 to 4a21620 Compare September 4, 2026 15:23
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.

1 participant