Skip to content

feat: enhance gas pricing to boost inclusion chances & add legacy tx support - #2

Open
sainoe wants to merge 4 commits into
masterfrom
sainoe/relay-gas-optimization
Open

feat: enhance gas pricing to boost inclusion chances & add legacy tx support#2
sainoe wants to merge 4 commits into
masterfrom
sainoe/relay-gas-optimization

Conversation

@sainoe

@sainoe sainoe commented Sep 1, 2025

Copy link
Copy Markdown
  • Improve gas price calculation by maximizing validator tips. The approach is to treat the minimum relayer profit as a fixed fee and allocate the remaining amount to gas. This increases the chance of being included in a block faster by incentivizing validators. Enable this behavior via the ENHANCE_GAS_PRICE config option.

  • Add support for legacy transactions, which simplifies gas enhancement logic and removes the need for oracle-based gas estimates. Chains that should use legacy transactions must be listed under LEGACY_TRANSACTIONS_CHAINS in the config.

.env config file snippet:

...
ENHANCE_GAS_PRICE=true
LEGACY_TRANSACTION_CHAINS=[1, 42161, 8453]
...

sainoe added 4 commits August 29, 2025 14:35
* maximize validator tip by using the remaing relayer's profit after substracting MIN_RELAYER_FEE_PCT
* use legacy transaction to maximize validator tip in fee and to remove oracle gas estimate
@sainoe
sainoe requested a review from sryps September 1, 2025 09:26
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