Skip to content

[Bug]: macOS Node Missing system.run.prepare Command #31959

@kongwy

Description

@kongwy

Bug Report: macOS Node Missing system.run.prepare Command

Environment

  • OpenClaw Version: 2026.3.1
  • Gateway Platform: Linux (Ubuntu)
  • Node Platform: macOS 26.3.0 (Mac mini, Mac14,12)
  • Node Version: 2026.3.1

Description

The macOS companion app does not report the system.run.prepare command in its commands list when connecting to the Gateway, causing all nodes.run operations to fail.

Expected Behavior

According to the source code (node-commands-BAFJumuL.js), NODE_SYSTEM_RUN_COMMANDS should include:

  • system.run.prepare
  • system.run
  • system.which

The macOS companion app should report all three commands when connecting to the Gateway.

Actual Behavior

The macOS node only reports:

  • system.run
  • system.which

The system.run.prepare command is missing from the declared commands list.

Impact

  1. nodes.run tool fails: When attempting to execute commands via nodes.run, the Gateway tries to call system.run.prepare first, but the node rejects it with:

    node command not allowed: the node (platform: macOS 26.3.0) does not support "system.run.prepare"
    
  2. Mac-only skills show as unavailable: Skills that require macOS-specific binaries (e.g., things-mac, managing-apple-music, peekaboo, sag) are marked as "missing" in the Gateway web UI, even though:

    • The node is connected and paired
    • getRemoteSkillEligibility() correctly identifies the Mac node
    • The required binaries exist on the Mac
  3. Documentation mismatch: The official documentation states that Mac-only skills should work when a Mac node is connected, but this bug prevents that functionality.

Steps to Reproduce

  1. Install OpenClaw 2026.3.1 on a Linux Gateway
  2. Install OpenClaw 2026.3.1 companion app on macOS
  3. Pair the Mac node with the Gateway
  4. Check the node's declared commands:
    openclaw nodes describe --node <node-id> --json | jq '.commands'
  5. Observe that system.run.prepare is missing
  6. Attempt to run a command via nodes.run:
    openclaw nodes run --node <node-id> --command '["which", "things"]'
  7. Observe the error: node command not allowed: the node does not support "system.run.prepare"

Root Cause Analysis

The macOS companion app's connection logic (node-cli-DiUsrGop.js, line ~1306) correctly spreads NODE_SYSTEM_RUN_COMMANDS:

commands: [
  ...NODE_SYSTEM_RUN_COMMANDS,
  ...NODE_EXEC_APPROVALS_COMMANDS,
  ...browserProxyEnabled ? [NODE_BROWSER_PROXY_COMMAND] : []
]

However, the actual commands sent to the Gateway are missing system.run.prepare. This suggests either:

  1. A build/bundling issue where NODE_SYSTEM_RUN_COMMANDS is incorrectly defined in the macOS build
  2. A runtime filtering issue that removes system.run.prepare before sending the connection request
  3. A version mismatch between the Gateway and companion app code

Workaround

Use SSH or other direct methods to execute commands on the Mac, bypassing nodes.run:

ssh user@mac-ip "things ..."

Additional Context

  • The Gateway's resolveNodeCommandAllowlist() correctly includes system.run.prepare in the macOS allowlist
  • The command handler for system.run.prepare exists in the node CLI code (line 1094)
  • This appears to be a regression or incomplete implementation in version 2026.3.1

Suggested Fix

Ensure the macOS companion app correctly includes all commands from NODE_SYSTEM_RUN_COMMANDS when building the connection parameters. Verify that the bundled/compiled version matches the source code definition.

Metadata

Metadata

Assignees

No one assigned

    Labels

    staleMarked as stale due to inactivity

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions