AI-generated analysisPublished automatically and not human-verified. Validated context appears in community notes below.
← Watch feed
Informational 15 Bitcoin

Merge bitcoin/bitcoin#35472: test: add coverage for feebumper uncomputable cluster error path

Public commit record

What the developer wrote

Authored by merge-script

100/100 · Strong
Merge bitcoin/bitcoin#35472: test: add coverage for feebumper uncomputable cluster error path

47632ab2a3876825576b3f07e6f80e799e6ed58f test: add coverage for feebumper uncomputable cluster error path (Henry Romp)

Pull request description:

Add functional test coverage for the error path in `CheckFeeRate()` when `calculateCombinedBumpFee()` returns `nullopt` because unconfirmed inputs span more than 500 mempool transactions (`CTxMemPool::GatherClusters` DoS limit).

The crash on this path was fixed in #34870; this PR adds the missing test requested in #34902.

The test builds eight independent 64-transaction clusters (512 total, above the 500 limit), keeps a wallet-owned RBF transaction that spends one output from each cluster out of the mempool, and asserts that `bumpfee` with an explicit `fee_rate` returns the expected wallet error instead of proceeding with an empty optional.

Closes #34902.

## Testing
- [ ] `./build/test/functional/wallet_bumpfee.py`
- [ ] Temporarily removed the early return in `CheckFeeRate()` and confirmed the test fails with `bad optional_access` instead of the expected error message

ACKs for top commit:
rapennas:
Tested ACK 47632ab2a3
furszy:
ACK 47632ab2a3876825576b3f07e6f80e799e6ed58f
sedited:
ACK 47632ab2a3876825576b3f07e6f80e799e6ed58f

Tree-SHA512: d44e774579131a476654f6ba26cd349c5a02c6a6a41bafdaca6727646ffe1083f49a2e4448fb4a8ef73638ca086bf9f4ffeaba18bb819c22e20a7d79a5bc49d2
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Mentions testing or verification✓ Links an issue, advisory, or supporting reference
The short version

What changed, and why it matters

This commit only adds a new automated test to Bitcoin Core. It does not change any production wallet, mempool, or node code. The test verifies that when a user tries to bump the fee of a transaction whose unconfirmed inputs depend on too many other unconfirmed transactions (more than 500), the wallet returns a clear error message instead of crashing. The underlying crash was already fixed in an earlier pull request; this change simply adds the missing test coverage.

Recommended action

No security action required. This is a test-only change adding regression coverage for an already-fixed bug. Reviewers may verify the test correctly exercises the error path as described.

Security signals we found

01

Adds regression test for previously fixed crash path (bad optional_access in CheckFeeRate)

02

No production code changes; no new attack surface introduced

03

Test exercises DoS-limit error handling in fee bumping

Risk score

Why this scored 15/100

Our methodology →
Potential impact 0/30
Exploitability 0/25
Stealth signal 0/15
Affected reach 0/15
Confidence 10/10
Evidence quality 5/5
Human-validated context

Community notes

Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.

No validated notes yet.

The AI analysis stands alone for now. Submit a note if you can add evidence or important context.