#35624 test: cover addnode connection limit

ReviewabilityReviewsAgreementSize
#35624 beihaili test: cover addnode connection limitAuthor silent 124d0Positive0 + 77 tests
  • Add functional test coverage ensuring manual outbound connections via addnode stay capped at 8
  • Author has been silent for 79 days so review feedback may wait a long time for a response
  • Concept approval without stated reasons (sedited)
  • Asked why the pull request is marked as draft (achow101)
  • 0 lines added or modified outside tests
  • 77 lines added or modified in tests
  • 0 lines removed in total
  • 2 files, 1 commits
Uncategorized15 PRs, unranked
2 rejected
  • RPC / REST / ZMQ: not a member. Touches only functional test files testing p2p connection limits via the addnode RPC.
  • Test infrastructure: not a member. Adds a functional test for p2p outbound connection limits with a mechanical registration in test_runner.py.
Reviewability: ReadyStalePaused
Agreement: StrongPositivePositive w/ caveatsNeutralMildDisputedBlockedCrickets
Reviews: current code-review ACKs, then (+stale ACKs) and -NACKs; greener = more ACKs.
Size: lines added or modified outside tests, then in tests; greener = smaller.

Goal

Adds a functional test verifying that active manual outbound connections created through the addnode RPC are capped at MAX_ADDNODE_CONNECTIONS (8). The test adds 9 reachable nodes, checks that getaddednodeinfo tracks all 9 entries, and confirms that getpeerinfo and getnetworkinfo show no more than 8 active connections over a stability period.

Problem: Bitcoin Core lacked dedicated functional test coverage verifying that manual outbound peer connections stay capped at 8 when users add more than 8 nodes via the addnode RPC.

Evidence of importance:

  • Addresses part of issue #28635 ('Test calling addnode more than once (and MAX_ADDNODE_CONNECTIONS)')

Reviewability

Stale · Author silent 124d

No author activity for 124 days; a review may wait a long time for a response.

Agreement

Positive

support without stated reasons, no open objection (sedited)

Thread notes: Initial record. sedited gave a Concept ACK while requesting the description be rewritten without an LLM; achow101 asked why the PR is in draft.

Objections, suggestions, and questions: none recorded.

Support:

  • sedited (contributor) (Concept ACK, 2026-06-30): Concept ACK [not substantive]

Participants:

  • sedited (contributor, support, 1 statements 2026-06-30 to 2026-06-30): Concept ACK, asked author to rewrite description in own words
  • achow101 (member, neutral, 1 statements 2026-07-23 to 2026-07-23): asked why the PR is in draft

Files

77 lines under test/bench/ci.

  • test/functional/rpc_addnode_limits.py +76/-0
  • test/functional/test_runner.py +1/-0

Card

The short text the ranking pass compares across PRs.

Adds a functional test covering the MAX_ADDNODE_CONNECTIONS limit (8) for manual outbound connections created via the addnode RPC. It addresses a gap identified in issue #28635, where the behavior of adding more nodes than the manual outbound cap was untested. The test adds 9 reachable target nodes and verifies that all 9 are tracked while active connections remain strictly capped at 8.

Data

dossier JSON · extract JSON · model ledger, generated 2026-09-18T03:34, confidence high, input hash b443c1f8389b1fb0
thread read through 2026-07-23 (2 statements), head 3be5ceeee7
Discussion read under schema 1 rules: suggestions and questions may be missing, and an objection may combine several harms (schema history).
labels: Tests · draft