Summary
When a wallet transaction’s unconfirmed inputs reference an aggregate mempool ancestor set whose size exceeds the GatherClusters() DoS limit (currently 500), MiniMiner cannot compute combined bump fees and CreateRateBumpTransaction() must surface a clear error to the caller instead of crashing or silently returning garbage.
This adds a unit test that constructs the offending topology, eight disjoint mempool chains, each at the cluster-count cap, totalling 512 transactions, and exercises CreateRateBumpTransaction through a wallet tx whose inputs are the chain tips. The test asserts the expected Result::WALLET_ERROR and that the surfaced error mentions the cluster-of-unconfirmed-transactions condition.
The construction is parameterised on MAX_CLUSTER_COUNT_LIMIT and the local kGatherClustersDoSLimit, so it survives changes to either; a static_assert pins the relationship at compile time. A second static_assert ensures the cluster count fits in the coinbases provided by TestChain100Setup.
Test plan
-
cmake --build build --target test_bitcoin --config Release -j -
build/bin/Release/test_bitcoin.exe --run_test=feebumper_tests --log_level=messagepasses - Mutation check: temporarily change
if (ret.size() > 500)insrc/txmempool.cpp:988to> 1000, rebuild, confirm the test now fails with both assertions, then revert
Related
Closes #34902.