From a7c72fe3f1a5942297fe01cf8cfc6b9a3b8e5197 Mon Sep 17 00:00:00 2001 From: Luis Carvalho Date: Mon, 30 Sep 2024 12:02:15 +0100 Subject: [PATCH] fix: add gas adjustment parameter to paloma txs Make sure pigeon txs to paloma have enough gas. --- util/ion/tx.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/util/ion/tx.go b/util/ion/tx.go index 10c69b65..3eb8449f 100644 --- a/util/ion/tx.go +++ b/util/ion/tx.go @@ -23,6 +23,8 @@ import ( "google.golang.org/grpc/status" ) +const txGasAdjustment = 1.2 + func (cc *Client) TxFactory() tx.Factory { return tx.Factory{}. WithAccountRetriever(cc). @@ -68,6 +70,8 @@ func (cc *Client) SendMsgs(ctx context.Context, msgs []sdk.Msg, memo string, opt return nil, err } + txf = txf.WithGasAdjustment(txGasAdjustment) + // TODO: Make this work with new CalculateGas method // TODO: This is related to GRPC client stuff? // https://github.com/cosmos/cosmos-sdk/blob/5725659684fc93790a63981c653feee33ecf3225/client/tx/tx.go#L297