Skip to content

fix: missing shareman->RegisterRecoveryInterface() in ActiveContext::Start #7243

@thepastaclaw

Description

@thepastaclaw

Bug

ActiveContext::Start() registers recovery interfaces for cl_signer and is_signer but not shareman:

// src/active/context.cpp — current code
cl_signer->RegisterRecoveryInterface();
is_signer->RegisterRecoveryInterface();
// shareman->RegisterRecoveryInterface(); ← MISSING

Without this, completed sig share sessions are only cleaned up via the 5-second Cleanup() interval instead of promptly via HandleNewRecoveredSig. The corresponding UnregisterRecoveryInterface() call in Stop() is also missing.

Impact

  • Delayed cleanup of completed sig share sessions (up to 5s instead of immediate)
  • Under CI load with frozen mocktime, this manifests as flaky test failures in feature_llmq_signing.py and interface_zmq_dash.py where InstantSend locks don't arrive within expected timeouts

Root Cause

The registration was likely dropped during the sig share refactoring that split share management into a separate shareman object. The cl_signer and is_signer registrations survived but shareman was missed.

Fix

// In ActiveContext::Start():
cl_signer->RegisterRecoveryInterface();
is_signer->RegisterRecoveryInterface();
+shareman->RegisterRecoveryInterface();

// In ActiveContext::Stop():
+shareman->UnregisterRecoveryInterface();
is_signer->UnregisterRecoveryInterface();
cl_signer->UnregisterRecoveryInterface();

Discovery

Found during CI triage of dash#7242 (wallet deprecation backport). The fix was originally committed as a80c46c438 on the backport branch but has been stripped out since it's unrelated to that PR's scope.

See also: dash#7233 (flaky LLMQ signing test fixes — related symptoms, different root cause).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions