Skip to content

Conversation

zeroXbrock
Copy link
Member

@zeroXbrock zeroXbrock commented Apr 11, 2025

Motivation

Was seeing a lot of "replacement transaction underpriced" errors.

Solution

Started by adding a mechanism to automatically increase the gas price when we saw the error. The spammer increased the gas price a ton yet I still saw the error, which led me to find an inconspicuous bug in the priority fee calculation.

With that fixed, gas price increases happened much less frequently. They still happen, though, so every time contender sees an "underpriced" error, it increases the gas price for following txs by 10%. When a batch of transactions is sent without error, the gas price for the following batch is decreased by 10%. This ensures we can keep running the spammer for a long time without the gas booster going exponential.

spamd now reliably fills blocks on a live testnet until the accounts run out of gas, at which point contender must be manually stopped.

Future improvement

In spamd, automatically replenish funds in agent accounts

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

@zeroXbrock zeroXbrock merged commit 8da7325 into main Apr 11, 2025
7 checks passed
@zeroXbrock zeroXbrock deleted the feat/scenario-generator-context branch April 11, 2025 21:09
@github-actions github-actions bot mentioned this pull request Jun 18, 2025
This was referenced Aug 14, 2025
This was referenced Aug 28, 2025
This was referenced Sep 4, 2025
This was referenced Oct 15, 2025
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