Skip to content

Config sync fails on live OpenClaw config because OPENCLAW_CONFIG_PATH is parsed as strict JSON #515

@itsmiso-ai

Description

@itsmiso-ai

Summary

Mission Control's config sync path appears to parse OPENCLAW_CONFIG_PATH as strict JSON, but real OpenClaw live configs are JSON5/JSONC-style (comments, unquoted keys, trailing commas). This causes sync/registration to fail even when Mission Control is otherwise connected and paired successfully.

What I observed

In a sidecar deployment with Mission Control sharing the live OpenClaw state/config:

  • OPENCLAW_CONFIG_PATH=/home/node/.openclaw/openclaw.json
  • Mission Control is otherwise working enough to:
    • start successfully
    • use SQLite successfully
    • authenticate/login successfully
    • pair/connect to the gateway successfully

But config sync fails with:

Sync failed: Expected property name or '}' in JSON at position 4 (line 2 column 3)

The live OpenClaw config begins in the normal OpenClaw style, e.g.:

{
  agents: {

That is valid JSON5/JSONC-style config, but not strict JSON.

Why this matters

This makes Mission Control incompatible with the actual live OpenClaw config format when using OPENCLAW_CONFIG_PATH against the real mutable config file.

So the integration currently ends up in a weird split state:

  • gateway connectivity works
  • pairing can work
  • but config sync/registration features fail because the config parser expects strict JSON

Expected behavior

One of these should happen:

  1. Mission Control should support OpenClaw config syntax as actually used in the live file (JSON5/JSONC-ish)
  2. Or Mission Control should document and enforce a different input format/path very explicitly
  3. Or config-sync features should gracefully detect unsupported config syntax and disable themselves without noisy failure

Suggested fix

Parse OPENCLAW_CONFIG_PATH with the same config-format expectations OpenClaw itself uses, rather than raw JSON.parse(...) assumptions.

Notes

This is distinct from gateway/device auth and pairing. In my environment, Mission Control could already connect/pair successfully; the failure was specifically in config sync against the live config file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions