Skip to content

macOS app 2026.5.26 shows duplicate node approval prompts for already-paired node #87382

Closed

Description

@rcritz

Summary

After upgrading/restarting the macOS app to 2026.5.26, the app repeatedly shows the same Allow node to connect? approval prompt for an already-paired node.

In one observed restart/reconnect cycle, the same laptop node prompt appeared twice immediately after restart, then a third time shortly after.

Environment

  • OpenClaw gateway: 2026.5.26 (10ad3aa)
  • macOS app showing prompt: 2026.5.26
  • Node shown in prompt:
    • Name: Richard's MacBook Pro M4 Max
    • Node ID: cc29297fbca0-cace5aa858d634196188b6b-b58ae644a8d4a74361a7116fee0a0
    • Platform: macOS 26.5
    • App: 2026.5.26
    • IP: 100.91.254.107
  • Account setup includes other paired nodes, but this prompt was for the same laptop node each time.

What happened

  1. Upgrade completed to OpenClaw 2026.5.26.
  2. The laptop macOS app/node was restarted/reconnected.
  3. The macOS app displayed Allow node to connect? for Richard's MacBook Pro M4 Max.
  4. The same approval prompt appeared multiple times for the same node:
    • twice immediately after restart
    • a third time shortly after

The prompt had the expected buttons: Approve Node, Not Now, and Reject.

Expected behavior

An already-paired node should reconnect without repeatedly asking for node-pair approval.

If approval is truly required again after an upgrade/restart, the UI should show at most one active approval prompt for the node and should retire/deduplicate stale requests once the node is approved.

Observed state/checks

Before seeing the duplicate/triplicate prompt:

  • openclaw nodes describe --node ace worked.
  • openclaw nodes list eventually returned normally after earlier reconnect churn.
  • Pending node pairings were reported as 0.
  • Paired nodes were reported as 3.
  • The laptop node was shown as paired/connected.

Gateway logs around the upgrade/reconnect showed node pairing approval activity and reconnect churn. There was also an earlier stale control UI on 2026.5.20 repeatedly sending approvals for unknown request IDs before the 2026.5.26 upgrade completed, but the duplicate prompt reproduced after the app restart on 2026.5.26.

This appears to be duplicate/stale node-pair approval presentation for the same already-known node, not exec approval prompts and not multiple devices.

Impact

The user is asked to repeatedly approve a node that should already be trusted, which makes normal macOS app restart/reconnect feel like a new-device/security event and erodes confidence in the pairing state.

Activity

  1. WarrenJones commented on May 27, 2026

    @WarrenJones
  2. clawsweeper commented on May 27, 2026

    @clawsweeper
    Contributor

    Thanks for the context here. I did a careful shell check against current main, and this is already implemented.

    Current main fixes the repeated already-paired macOS node approval prompt by reconciling paired-node reconnects before creating new pairing requests and clearing stale same-node pending reapproval after a successful hello; the fix is merged and shipped in v2026.6.8-beta.1.

    I found the merged PR that appears to have closed this: #92547: fix(nodes): surface pending reapproval diagnostics.

    So I’m closing this as already implemented rather than keeping a duplicate issue open.

    Review details

    Best possible solution:

    Keep the current gateway-side reconnect cleanup and reapproval diagnostics behavior; reopen only with a repro against v2026.6.8-beta.1 or later showing same-surface prompts still appear.

    Do we have a high-confidence way to reproduce the issue?

    No current-main failure path remains. The historical 2026.5.26 and 2026.5.28-beta reports reproduced the prompt loop, and current source plus regression coverage now show same-surface paired-node reconnects clear stale pending prompts instead of creating another approval.

    Is this the best way to solve the issue?

    Yes. Fixing this at the gateway reconnect and cleanup boundary is the best shape because it suppresses stale same-surface prompts without auto-approving expanded commands, capabilities, or permissions.

    Security review:

    Security review: This is a non-PR issue cleanup; no patch security or supply-chain review applies, and the implemented path preserves explicit reapproval for expanded node surfaces.

    AGENTS.md: found and applied where relevant.

    What I checked:

    • Current reconnect decision: Unchanged paired-node reconnects do not call the pairing request path: only command, capability, or permission changes create pending reapproval, while same-surface reconnects return effective declared surfaces with shouldClearPendingPairings: true. (src/gateway/node-connect-reconcile.ts:173, 1db8ab373422)
    • Successful hello clears stale pending requests: The node hello path snapshots paired-node state before reconciliation, keeps a cleanup claim only for same-surface reconnects, finalizes it after hello succeeds, and broadcasts node.pair.resolved for cleared stale requests. (src/gateway/server/ws-connection/message-handler.ts:1672, 1db8ab373422)
    • Pairing store cleanup is node-scoped: beginNodePairingConnect claims pending revisions for the paired node and finalizeNodePairingCleanupClaim deletes only still-matching claimed revisions, so stale prompts are retired without dropping newer or changed-surface approval requests. (src/infra/node-pairing.ts:364, 1db8ab373422)
    • Regression coverage: The gateway regression test pairs a node, creates a pending upgraded reapproval, reconnects the same node with the approved surface, and asserts pending requests for that node are cleared; adjacent tests still require reapproval for command upgrades. (src/gateway/server.node-pairing-authz.test.ts:456, 1db8ab373422)
    • Fix provenance: Merged pull request fix(nodes): surface pending reapproval diagnostics #92547 added the current reapproval diagnostics and stale reconnect cleanup across the gateway reconciliation, websocket hello, pairing store, coordinator, and tests. (65b460f2345a)
    • PR merge provenance: GitHub reports fix(nodes): surface pending reapproval diagnostics #92547 merged at 2026-06-14T00:40:19Z with merge commit 65b460f, and the PR body explicitly includes clearing stale reapproval only after a successful hello while preserving expanded-surface approval. (65b460f2345a)

    Likely related people:

    • fuller-stack-dev: Authored the merged reapproval diagnostics and stale cleanup PR, including the fix(nodes): defer stale pairing cleanup commit that changed the websocket reconnect cleanup path. (role: fix author; confidence: high; commits: 65b460f2345a, 0d06b277b256, a1721524fbec; files: src/gateway/node-connect-reconcile.ts, src/infra/node-pairing.ts, src/gateway/server/ws-connection/message-handler.ts)
    • steipete: Merged the fixing PR and authored follow-up commits in the same branch that preserve, serialize, and bound reapproval cleanup during reconnect races. (role: merger and reconnect-race contributor; confidence: high; commits: 65b460f2345a, d7b4dfad6ddd, a698a0f01a96; files: src/gateway/node-reapproval-coordinator.ts, src/infra/node-pairing.ts, src/gateway/server.node-pairing-authz.test.ts)
    • eleqtrizit: Authored the earlier merged reconnect command-upgrade re-pairing behavior that the current fix preserves while suppressing stale same-surface prompts. (role: introduced related behavior; confidence: medium; commits: a383878e97b7; files: src/gateway/node-connect-reconcile.ts, src/gateway/server.node-pairing-authz.test.ts)

    Codex review notes: model internal, reasoning high; reviewed against 1db8ab373422; fix evidence: merged PR #92547, release v2026.6.8-beta.1, commit 65b460f2345a.

  3. added
    P2Normal backlog priority with limited blast radius.
    impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.
    impact:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.
    issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.
    clawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.
    on May 27, 2026
  4. zhanghenglim commented on May 30, 2026

    @zhanghenglim

    Additional live repro from 2026.5.28-beta.4:

    Environment:

    • CLI/Gateway: OpenClaw 2026.5.28-beta.4 (b717704)
    • macOS app bundle: 2026.5.27 (CFBundleVersion=2026052790)
    • macOS: 26.5 (25F71)
    • Install kind: npm package under /opt/homebrew/lib/node_modules/openclaw

    Observed behavior:

    1. Start with a paired local macOS node. openclaw nodes pending --json returns [].
    2. openclaw nodes status --json reports the same node as paired: true and connected: true.
    3. Quit and reopen /Applications/OpenClaw.app.
    4. The app shows Allow node to connect? for the same node id/display name.
    5. Gateway logs show another node pairing approval path after relaunch. At the same time, openclaw nodes status still reports the same node as already paired/connected.

    I also tested removing the node entry from ~/.openclaw/nodes/paired.json, reopening the app, and manually approving the new prompt. The node paired successfully, but the prompt returned again on the next app relaunch. So this does not look like a corrupt stale pairing record.

    Suspected cause:

    • requestNodePairing() in dist/node-pairing-*.js reconciles only existing pending requests for a node.
    • It does not short-circuit when state.pairedByNodeId[nodeId] already exists.
    • As a result, a relaunch-time node.pair.request from an already-paired macOS app node can create another pending approval request.

    Local mitigation tested:

    • If state.pairedByNodeId[nodeId] exists and the incoming request has the same approval surface (caps and commands), refresh paired node metadata and remove pending requests for that node instead of creating a new pending approval.
    • Keep the normal approval flow when the node declares new caps/commands.

    After applying that local mitigation and restarting the gateway, I relaunched the macOS app twice:

    • openclaw nodes pending --json stayed []
    • no new node.pair.approve appeared in the gateway log
    • node status returned to paired: true, connected: true

    This seems like it can be fixed safely on the gateway side without auto-approving expanded node capabilities.

  5. locked as resolved and limited conversation to collaborators on Jun 25, 2026
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

    P2Normal backlog priority with limited blast radius.clawsweeper:needs-live-reproClawSweeper needs live local, crabbox, or manual validation to confirm this issue.impact:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🐚 platinum hermitGood issue quality with a plausible reproduction path needing some confirmation.

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions