Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Builder disable bumps #1125

Merged
merged 6 commits into from
Sep 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions seth/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,7 @@ func (m *Client) WaitMined(ctx context.Context, l zerolog.Logger, b bind.DeployB
return receipt, nil
} else if errors.Is(err, ethereum.NotFound) {
l.Debug().
Str("Timeout", m.Cfg.Network.TxnTimeout.String()).
Str("TX", tx.Hash().String()).
Msg("Awaiting transaction")
} else {
Expand Down
2 changes: 1 addition & 1 deletion seth/client_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func NewClientBuilder() *ClientBuilder {
BlockStatsConfig: &BlockStatsConfig{RPCRateLimit: 10},
NonceManager: &NonceManagerCfg{KeySyncRateLimitSec: 10, KeySyncRetries: 3, KeySyncTimeout: MustMakeDuration(60 * time.Second), KeySyncRetryDelay: MustMakeDuration(5 * time.Second)},
GasBump: &GasBumpConfig{
Retries: 10,
Retries: 0, // bumping disabled by default
},
},
}
Expand Down
4 changes: 2 additions & 2 deletions seth/retry.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@ var prepareReplacementTransaction = func(client *Client, tx *types.Transaction)
ctxPending, cancelPending := context.WithTimeout(context.Background(), client.Cfg.Network.TxnTimeout.Duration())
_, isPending, err := client.Client.TransactionByHash(ctxPending, tx.Hash())
defer cancelPending()
if err != nil {
if err != nil && !strings.Contains(err.Error(), "not found") {
return nil, err
}

if !isPending {
if err != nil && !isPending {
L.Debug().Str("Tx hash", tx.Hash().Hex()).Msg("Transaction was confirmed before bumping gas")
return nil, errors.New("transaction was confirmed before bumping gas")
}
Expand Down
Loading