1. Skill Overview
This skill is built for macOS Parallels smoke test workflows. Its core objective is to verify that OpenClaw can complete two-way Discord message exchange inside a genuine macOS virtual machine. It simulates a full end-to-end deployment workflow from scratch: provision OpenClaw on a clean macOS snapshot, inject Discord Bot credentials, then run a closed-loop "send-reply-read" validation cycle.
Core Principle: Discord tokens and configuration files are never committed to source control. All credentials are injected dynamically at runtime. Temporary test messages are auto-cleaned after testing, and the virtual machine is shut down automatically.
2. Core Capabilities
2.1 End-to-End Closed-Loop Validation Flow
The skill executes a standardized four-step roundtrip test:
| Step | Action | Validation Criteria |
|---|---|---|
| ① Guest Send | OpenClaw running inside the macOS VM sends a message to the target Discord channel | Message is successfully dispatched to the channel |
| ② Host Receive | The host test runner observes the outgoing message in the Discord channel history | The sent message appears in visible channel logs |
| ③ Host Reply | The host posts a reply message within the same Discord channel | Reply message submits successfully |
| ④ Guest Read | The OpenClaw instance in the VM fetches and reads the host’s reply via the message read API | The reply content is present in the read output |
Pass Standard: The summary report marks
discord=pass. The unique nonce sent from the VM appears in channel history, and the host’s reply is fully captured in OpenClaw’s message read output.2.2 Execution Command
Recommended invocation method:
export OPENCLAW_PARALLELS_DISCORD_TOKEN="$( ssh peters-mac-studio-1 'jq -r ".channels.discord.token" ~/.openclaw/openclaw.json' | tr -d '\n' )"
pnpm test:parallels:macos \
--discord-token-env OPENCLAW_PARALLELS_DISCORD_TOKEN \
--discord-guild-id 1456350064065904867 \
--discord-channel-id 1456744319972282449 \
--json
2.3 Snapshot Management
- Target base snapshot: Clean state closest to fresh macOS 26.3.1 installation
- Snapshot resolution priority: Prefer clones tagged
*-poweroff*to enable disk-only snapshot restoration without suspended state - CPU incompatibility handling: If restore logs output
PET_QUESTION_SNAPSHOT_STATE_INCOMPATIBLE_CPU, discard suspended state, create a replacement*-poweroffsnapshot, and re-run the test - Auto-boot: Script automatically launches the restored powered-off snapshot instance
2.4 Configuration & Command Standards
- Discord config: Configured entirely inside the guest VM; no hardcoded tokens or committed config files
- Message subcommand execution: Use the official OpenClaw wrapper for
message send/read; rawnode openclaw.mjs message ...cannot resolve lazy-loaded subcommands identically - JSON config writing: Write
channels.discord.guildsas a single JSON object via--strict-jsoninstead of dot-separatedconfig setpaths — numeric snowflake IDs are misinterpreted as array indices with dot notation - Remote script execution rule: Avoid
prlctl enter/expectfor long Discord setup scripts (line breaks corrupt multi-line commands). Useprlctl exec --current-user /bin/sh -lc ...instead
2.5 Post-Test Cleanup
- Message cleanup: All temporary smoke-test Discord messages are deleted upon test completion
- VM shutdown: After a successful Discord roundtrip pass, the macOS guest VM is halted via
prlctl stop "macOS Tahoe". Manual ad-hoc Discord inspection sessions also require manual VM shutdown.
⚠️ Critical Warning: Never leave a pre-configured Discord VM running. It will continuously poll and post messages in the
#maintainer channel, spamming Discord long after test execution finishes.2.6 Troubleshooting Workflow
- Log storage path:
/tmp/openclaw-parallels-smoke.* - Roundtrip flaky failure debugging: Inspect
fresh.discord-roundtrip.loganddiscord-last-readback.jsonin the working directory first - Machine-readable output: Append the
--jsonflag to retrieve structured test summary data
2.7 Parallel Execution & Load Constraints
- 3-OS full scan workflows: Shared build locks are safe for parallel runs, but snapshot restoration remains the major Parallels performance bottleneck
- High host load mitigation: If the host machine is already resource saturated, serialize Windows/Linux restore-heavy re-runs to avoid resource contention
3. Primary Use Cases
- macOS Parallels smoke validation
Verify end-to-end two-way Discord messaging functionality for OpenClaw inside a real macOS virtual machine.
- Pre-release macOS compatibility gate
Confirm Discord channel integration operates correctly on macOS before Beta / Stable production releases.
- Discord channel regression testing
Run the closed-loop roundtrip test after any Discord channel code modifications to ensure bidirectional communication remains unbroken.
- Snapshot restore & automation pipeline validation
Validate reliability of Parallels snapshot recovery logic and automated provisioning scripts for macOS environments.
- CI/CD pipeline integration
Execute automated macOS Discord end-to-end validation as a mandatory stage in release pipelines.
4. Critical Guiding Principles
- No committed credentials: Discord tokens are injected at runtime via environment variables and never persisted to config files or source code
- Mandatory VM shutdown post-test: Automatically halt the virtual machine after a passing proof run to prevent persistent Discord bot spam
- Avoid
prlctl enter: Long multi-line commands get corrupted by line breaks; useprlctl execfor remote guest execution - JSON config writing rule: Snowflake IDs are parsed as array indices under dot-separated config paths; always use
--strict-jsonto write guild data as a single root object - Rebuild snapshots on CPU incompatibility: Discard suspended VM state and generate new poweroff snapshots when encountering
PET_QUESTION_SNAPSHOT_STATE_INCOMPATIBLE_CPU - Serialize restore jobs under high host load: Snapshot recovery is a resource bottleneck; avoid parallel execution of restore-heavy test suites
Summary
Parallels Discord Roundtrip is a dedicated smoke-test skill for validating full bidirectional Discord channel communication within OpenClaw’s macOS Parallels virtual machines. It automates a closed-loop workflow: guest message send → host receive → host reply → guest message read, providing objective proof of Discord channel operability on native macOS virtualized environments. This skill is intended for OpenClaw maintainers to run pre-release macOS compatibility checks, perform Discord feature regression testing, and validate end-to-end Parallels automation pipelines.