mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-15 16:38:23 +01:00
9b75cfda4dtest: retain the intended behavior of `feature_fee_estimation.py` nodes (ismaelsadeeq)5c1236f04atest: fix incorrect subtest in `feature_fee_estimation.py` (ismaelsadeeq) Pull request description: Attempt to fix #32461 In the `estimatesmartfee` RPC, we return the maximum of the following: the feerate estimate for the target, `minrelaytxfee`, and `mempoolminfee`.9a05b45da6/src/rpc/fees.cpp (L85)The test `test_feerate_mempoolminfee`, originally introduced inea31caf6b4, is incorrect. It should calculate the fee rate ceiling by taking the maximum of the custom `minrelaytxfee`, `mempoolminfee`, and the highest fee rate observed during the test (`check_smart_estimates`). This is necessary because: * There is no guarantee that the generated fee rates will exceed both `minrelaytxfee` and `mempoolminfee`. * Users can start a node with custom fee settings. Due to the non-deterministic nature of the `feature_fee_estimation.py` test, it often passes by chance. The randomly generated fees typically include a value higher than the custom `minrelaytxfee`, inadvertently hiding the issue. Issue #32461 identified a random seeds that consistently fails the test because the generated fees never exceed the custom `minrelaytxfee`: e.g ``` build/test/functional/feature_fee_estimation.py --random=3450808900320758527 ``` This PR has two commits which : * Correctly fixes the test by calculating the fee rate ceiling as the maximum of the node `minrelaytxfee`, `mempoolminfee`, and the highest seen fee rate, when verifying smart fee estimates. * Improves the subtest name and comment for clarity. * Restores the original test behavior by appending 4000 WU to the custom `blockmaxweight`. ACKs for top commit: achow101: ACK9b75cfda4dglozow: ACK9b75cfda4dtheStack: Light ACK9b75cfda4dTree-SHA512: 0f7fb0496b50a399b58f6fb1afd95414fad454795fbc0046e22dfc54a2062ae0c519a12ebfeb6ad7ef547438868d99eca2351c0d19d0346adaadb500eff6f15f
21 KiB
Executable File
21 KiB
Executable File