diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp --- a/src/rpc/blockchain.cpp +++ b/src/rpc/blockchain.cpp @@ -1505,7 +1505,9 @@ gArgs.GetArg("-maxmempool", DEFAULT_MAX_MEMPOOL_SIZE) * 1000000; ret.pushKV("maxmempool", (int64_t)maxmempool); ret.pushKV("mempoolminfee", - ValueFromAmount(g_mempool.GetMinFee(maxmempool).GetFeePerK())); + ValueFromAmount( + std::max(g_mempool.GetMinFee(maxmempool), ::minRelayTxFee) + .GetFeePerK())); return ret; } diff --git a/test/functional/wallet_basic.py b/test/functional/wallet_basic.py --- a/test/functional/wallet_basic.py +++ b/test/functional/wallet_basic.py @@ -47,6 +47,10 @@ assert_equal(len(self.nodes[1].listunspent()), 0) assert_equal(len(self.nodes[2].listunspent()), 0) + self.log.info("Check for mempoolminfee in getmempoolinfo") + assert_equal(self.nodes[0].getmempoolinfo()[ + 'mempoolminfee'], Decimal('0.00001000')) + self.log.info("Mining blocks...") self.nodes[0].generate(1)