openclaw - 💡(How to fix) Fix [Bug]: CLI probe commands (openclaw gateway status) create read-only device pairing record that blocks admin operations [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#71766Fetched 2026-04-26 05:08:42
View on GitHub
Comments
1
Participants
2
Timeline
4
Reactions
0
Author
Participants
Timeline (top)
labeled ×2closed ×1commented ×1

Running CLI probe commands like openclaw gateway status or openclaw status creates a read-only (operator.read) device pairing record in devices/paired.json. This read-only record subsequently blocks any operations requiring operator.admin scope (such as openclaw nodes approve or sub-agent creation), causing a deadlock.

Error Message

  • A scope-upgrade failure should provide clear error messages and unlock guidance User experience impact: A user who runs openclaw gateway status to check things are working will silently poison their installation. Every subsequent command fails with an opaque "pairing required" error. This is likely the most confusing failure mode possible — the act of checking whether the system works breaks the system.

Root Cause

  1. Self-locking deadlock: Once the read-only record exists, the user cannot fix the problem through normal CLI workflows because the CLI itself lacks the admin permissions needed to approve a scope upgrade. Recovery requires manual file deletion (paired.json) + gateway restart — a workaround that no user would discover without seeing the source code or this issue.

Fix Action

Fix / Workaround

  1. Self-locking deadlock: Once the read-only record exists, the user cannot fix the problem through normal CLI workflows because the CLI itself lacks the admin permissions needed to approve a scope upgrade. Recovery requires manual file deletion (paired.json) + gateway restart — a workaround that no user would discover without seeing the source code or this issue.

Code Example

{
"cause": "pairing-required",
"reason": "scope-upgrade"
}
RAW_BUFFERClick to expand / collapse

Bug type

Behavior bug (incorrect output/state without crash)

Beta release blocker

Yes

Summary

Running CLI probe commands like openclaw gateway status or openclaw status creates a read-only (operator.read) device pairing record in devices/paired.json. This read-only record subsequently blocks any operations requiring operator.admin scope (such as openclaw nodes approve or sub-agent creation), causing a deadlock.

Steps to reproduce

  1. Run openclaw gateway status when the CLI device is not paired
  2. Attempt to create a subagent
  3. CLI connects to Gateway WebSocket and triggers device pairing
  4. Pairing is approved, but the CLI only declares operator.read scope
  5. A read-only device record is written to devices/paired.json
  6. Attempt any admin operation (e.g., openclaw nodes approve, create a sub-agent)
  7. Result: gateway closed (1008): pairing required

Expected behavior

  • CLI probe commands should either declare full operator scope, OR
  • The Gateway should allow existing paired devices to upgrade their scope when needed, OR
  • A scope-upgrade failure should provide clear error messages and unlock guidance

Actual behavior

The scope-upgrade reason in logs confirms: an existing device record lacks sufficient permissions, but the upgrade itself requires admin permissions that the existing record doesn't have → deadlock.

OpenClaw version

2026.4.10

Operating system

Windows 11

Install method

npm global

Model

qwen3.6-plus

Provider / routing chain

Additional provider/model setup details

No response

Logs, screenshots, and evidence

{
"cause": "pairing-required",
"reason": "scope-upgrade"
}

Impact and severity

Severity: High / Beta Release Blocker

This bug has a deceptive trigger but critical impact:

  1. Invisible trigger: openclaw gateway status is a benign diagnostic command that users run routinely to check gateway health. There is zero indication that running it has any side effects.

  2. Cascading failure: After the read-only pairing record is created, ALL subsequent admin operations fail:

    • Sub-agent creation (sessions_spawn)
    • openclaw nodes approve / openclaw nodes list
    • openclaw devices list
    • Any CLI command requiring operator.admin scope
  3. Self-locking deadlock: Once the read-only record exists, the user cannot fix the problem through normal CLI workflows because the CLI itself lacks the admin permissions needed to approve a scope upgrade. Recovery requires manual file deletion (paired.json) + gateway restart — a workaround that no user would discover without seeing the source code or this issue.

  4. Reproducible 100%: The bug is consistently reproducible on any fresh install where the CLI device has not yet been paired with full scope.

User experience impact: A user who runs openclaw gateway status to check things are working will silently poison their installation. Every subsequent command fails with an opaque "pairing required" error. This is likely the most confusing failure mode possible — the act of checking whether the system works breaks the system.

Additional information

openclaw gateway status (needs operator.read only) → creates read-only pairing record in paired.json → blocks new pairing requests with higher scopes → admin operations (sub-agent creation, nodes approve) fail with "pairing required" → cannot approve the new pairing because the CLI itself lacks admin permission → DEADLOCK

extent analysis

TL;DR

The most likely fix is to modify the openclaw gateway status command to declare full operator scope or implement a scope-upgrade mechanism that allows existing paired devices to upgrade their scope when needed.

Guidance

  • Verify that the devices/paired.json file contains a read-only record after running openclaw gateway status and confirm that this record is causing the deadlock.
  • Check the logs for the scope-upgrade reason to confirm that the existing device record lacks sufficient permissions.
  • Consider implementing a temporary workaround by manually deleting the paired.json file and restarting the gateway to recover from the deadlock.
  • Investigate modifying the CLI to provide clear error messages and unlock guidance when a scope-upgrade failure occurs.

Example

No code snippet is provided as the issue does not contain sufficient information to suggest a specific code change.

Notes

The provided information suggests that the issue is related to the scope declared by the openclaw gateway status command and the resulting read-only pairing record. However, without more information about the underlying code and implementation, it is difficult to provide a definitive solution.

Recommendation

Apply a workaround by manually deleting the paired.json file and restarting the gateway when a deadlock occurs, as this is the only provided method to recover from the issue. A permanent fix would require modifying the openclaw gateway status command or implementing a scope-upgrade mechanism.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

  • CLI probe commands should either declare full operator scope, OR
  • The Gateway should allow existing paired devices to upgrade their scope when needed, OR
  • A scope-upgrade failure should provide clear error messages and unlock guidance

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING