From 705d3e6b2c8d224d22c29f07e9ce5daff15f38e5 Mon Sep 17 00:00:00 2001 From: wuyachi Date: Tue, 8 Nov 2022 16:38:41 +0800 Subject: [PATCH] Hardcode Astar's gas price --- wallet/wallet.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wallet/wallet.go b/wallet/wallet.go index ba9fed8..e847d46 100644 --- a/wallet/wallet.go +++ b/wallet/wallet.go @@ -251,6 +251,10 @@ func (w *Wallet) GasPrice() (price *big.Int, err error) { } func (w *Wallet) GasTip() (price *big.Int, err error) { + if w.sdk.ChainID == base.ASTAR { + // astar average price is 60 Gwei while node returns 1 Gwei + return big.NewInt(1000000000 * 60), nil + } return w.sdk.Node().SuggestGasTipCap(context.Background()) }