• Matthew Slipper's avatar
    op-deployer: Custom gas price estimator (#12239) · 1217d4ac
    Matthew Slipper authored
    * op-deployer: Custom gas price estimator
    
    Sepolia's fees are super high and extremely volatile right now. As a result, it became difficult for users to deploy new chains using op-deployer. The OPCM's deploy transaction buys most of the gas in the block, and the default gas price estimation logic in the transaction manager wasn't aggressive enough for the transactions to land on chain in a timely manner.
    
    This PR adds the ability to customize the transaction manager with a custom `GasPriceEstimator` function that returns the tip, base fee, and blob fee. I extracted the original logic in the transaction manager into a default estimator that will be used if one isn't specified. For op-deployer, I built a custom estimator that pads the head block's base fee by 20%, and multiplies the suggested tip by 10. After testing this, I was able to get transactions onto Sepolia reliably. The algorithm is pretty simple and overpays for transactions by a lot, but for op-deployer's use case it's more important that transactions land quickly than it is they be cheap. Deployments are a one-time thing.
    
    * code review updates
    
    * better default support
    
    * specific test for extension
    1217d4ac
Name
Last commit
Last update
..
cliapp Loading commit data...
client Loading commit data...
clock Loading commit data...
crypto Loading commit data...
ctxinterrupt Loading commit data...
dial Loading commit data...
endpoint Loading commit data...
enum Loading commit data...
errutil Loading commit data...
eth Loading commit data...
flags Loading commit data...
httputil Loading commit data...
ioutil Loading commit data...
jsonutil Loading commit data...
log Loading commit data...
metrics Loading commit data...
oppprof Loading commit data...
predeploys Loading commit data...
retry Loading commit data...
rpc Loading commit data...
safego Loading commit data...
signer Loading commit data...
solabi Loading commit data...
sources Loading commit data...
tasks Loading commit data...
testlog Loading commit data...
testutils Loading commit data...
tls Loading commit data...
txmgr Loading commit data...
Makefile Loading commit data...
util.go Loading commit data...
util_test.go Loading commit data...
version.go Loading commit data...
version_test.go Loading commit data...