All fees in bitcoin core are specified in BTC/kB but -paytxfee silently ([init.cpp]) ignores this rule due to fPayAtLeastCustomFee = true.
This PR will:
- Default
fPayAtLeastCustomFeeto false - Improve the rpc wallet tests: Always assert the fee per kB via
check_amount()(Previously only fee == fee per 1000 bytes was asserted) - Introduce
-payatleastcustomfee - Fixes #6479
For completeness: Copy of #6649 description:
This allows for much finer control of the transaction fees per kilobyte as it prevent small transactions using a fee that is more appropriate for one that is of a kilobyte.
This also allows controlling the fee per kilobyte over rpc such that:
bitcoin-cli settxfee `bitcoin-cli estimatefee 2`
would make sense, while currently it grossly fails often by a factor of x3
This fixes issue #6479, and has minimal impact as dynamic fees are currently the default. This default can be overriden in the qt wallet, although I have trouble imagining where that is useful. Possibly the entire concept of fPayAtLeastCustomFee can be removed in a later version.