Skip to content

bug(openclaw-plugin): Windows fails when sessionKey contains path-invalid characters #999

@qin-ctx

Description

@qin-ctx

Bug Description

The OpenClaw OpenViking plugin currently uses the raw OpenClaw sessionKey as the OpenViking session ID. On Windows, session keys containing characters such as : become invalid local filesystem path segments and cause auto-capture/session writes to fail.

Reproduction

  1. Run the OpenClaw OpenViking plugin on Windows.
  2. Use a session whose sessionKey contains Windows-invalid filename characters, such as agent:main:main.
  3. Trigger auto-capture or any session write path.

Actual Behavior

OpenViking fails to append to messages.jsonl with an invalid filename error. Example:

OpenViking request failed [INTERNAL]: Failed to append to file viking://session/default/agent:main:main/messages.jsonl
...
The filename, directory name, or volume label syntax is incorrect

Expected Behavior

The plugin should map external session keys to stable filesystem-safe OpenViking session IDs before writing session data, while preserving a stable mapping for repeated use of the same session key.

Root Cause

The plugin performs a raw 1:1 sessionKey -> session_id mapping, which is not portable across filesystems. Windows rejects : in path components, so the mapped session path becomes invalid.

Scope

This affects OpenClaw plugin flows that rely on OpenViking session persistence, including auto-capture and commit/delete paths.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions