From 9d9b2a65cac9e82302a190c3f5efc512a10442f1 Mon Sep 17 00:00:00 2001 From: Freddy Caceres Date: Mon, 20 Jun 2022 20:29:32 -0400 Subject: [PATCH 1/2] fix gasPrice minGasPrice comparison --- rpc/namespaces/ethereum/eth/api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpc/namespaces/ethereum/eth/api.go b/rpc/namespaces/ethereum/eth/api.go index ed11f08e37..99181b2168 100644 --- a/rpc/namespaces/ethereum/eth/api.go +++ b/rpc/namespaces/ethereum/eth/api.go @@ -216,7 +216,7 @@ func (e *PublicAPI) GasPrice() (*hexutil.Big, error) { if err != nil { return nil, err } - minGasPriceInt := minGasPrice.BigInt() + minGasPriceInt := minGasPrice.TruncateInt().BigInt() if result.Cmp(minGasPriceInt) < 0 { result = minGasPriceInt } From efd1b5d272257db20ff7163cf79c6f60f1ca3434 Mon Sep 17 00:00:00 2001 From: Freddy Caceres Date: Tue, 21 Jun 2022 07:11:56 -0400 Subject: [PATCH 2/2] update changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index fcf38ac236..ac6ada4059 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -53,6 +53,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Bug Fixes * (evm) [tharsis#1118](https://github.com/evmos/ethermint/pull/1118) Fix `Type()` `Account` method `EmptyCodeHash` comparison +* (rpc) [tharsis#1138](https://github.com/evmos/ethermint/pull/1138) Fix GasPrice calculation with relation to `MinGasPrice` ## [v0.16.0] - 2022-06-06