Skip to content

test: wallet_listtransactions.py's keypoolrefill(1000) can exceed the RPC timeout on a loaded machine #242

Closed

Description

@djh58

wallet_listtransactions.py can fail with an RPC timeout on a loaded machine, independent of the change under test.

What happens

run_externally_generated_address_test refills node 0's keypool before copying its wallet to node 2 (test/functional/wallet_listtransactions.py:228):

self.nodes[0].keypoolrefill(1000)

For P2MR descriptor wallets each new keypool entry derives and persists post-quantum key material (see #26), so 1,000 entries is slow. Running the whole functional suite at -j 4 on a busy host, this call took longer than the 30 s RPC timeout and failed the test. The same test passed with --timeout-factor=4, and it failed the same way on a build without the change being tested, so the flake is pre-existing.

Why it matters now

Whole-suite runs on small CI runners hit it first. With #241, pull requests that touch the transport also run the whole suite with hybrid transport on a 4-core GitHub-hosted runner (pq-functional), so this test would fail some of those runs.

Possible fixes

  • Refill only what the test needs: it copies the wallet so node 2 recognizes the addresses node 0 hands out afterwards, which is far fewer than 1,000. A smaller refill with some margin keeps the check and removes most of the work.
  • Or give this one call a longer RPC timeout, scaled by the timeout factor.

The first is preferable: it makes the test faster everywhere instead of only tolerating the slow path.

Activity

  1. added
    bug
    on Oct 22, 2026
  2. added a commit that references this issue on Oct 23, 2026
    3c4bcb1
  3. djh58 commented on Oct 23, 2026

    @djh58
    MemberAuthor

    Fixed by #243, merged into feature/pq-transport as 3c4bcb1. It reaches 1.x.x with #233.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions