Skip to content

v2.7.0 — manual compact, safer history and side questions

Choose a tag to compare

@CASE-Drakon CASE-Drakon released this 11 Nov 12:17
1e8d8f7

[2.7.0] - 2026-11-11

Added

  • Manual /compact on single-account backends (#159). A claw<N>/*
    backend on the verified launch now declares OpenClaw's public
    manualCompaction contract, a port of the bundled claude-cli backend's:
    the same /compact [instructions] prompt, passed as an argument, accepted
    only when the output carries a compact_boundary system event or
    compact_result: "success". OpenClaw runs the request as claude itself on
    that account's login; the shim is not involved, so multi-clawd records no
    served launch and writes none of its own state. From OpenClaw 2026.11.2 the
    request no longer carries the --permission-mode bypassPermissions that
    full exec mode adds, as on the bundled backend. Covered by a fixture
    claude driven by the host's launch rules; a live /compact against a
    running gateway has not been exercised.

Known limitations

  • Manual /compact stays refused on the pooled backend (#159). clawd/*
    still answers CLI backend "clawd" owns compaction but does not support manual compaction. OpenClaw runs a manual compaction outside the plugin's
    launch path and without naming the session, so the pool cannot make sure it
    lands on the account holding the newest copy of the conversation; after a
    rotation it could compact an older copy and replace the newer turns. The
    refusal starts nothing and changes nothing. Automatic compaction inside a
    turn is unaffected. A legacy-launch single-account backend is refused as
    well. See README, "Manual /compact compatibility".

Fixed

  • Account history could silently lose an event when two launches wrote at
    once.
    A shim that could not take the history.jsonl lock within its
    150 ms wait returned without recording, so explain --history and the
    spread strategy's served-launch count could be one short while every
    process exited 0. Such a writer now parks its event in a 0600
    history.jsonl.pending-* file, and a later writer that takes the lock folds
    parked events into the journal (up to 100 files per write, oldest first)
    and removes the files it folded. The journal replace carries a receipt of
    the files it folded, so a writer that stops before removing them, at any
    point, does not cause an event to be counted twice or brought back after
    the cap has trimmed it. Readers include parked events, with one exception:
    if the journal is replaced during all three of a reader's attempts, it returns
    the last journal alone, which can omit events that are still parked.
    Readers order what they return by event timestamp and stay inside the
    journal's 500-event / 64 KiB bound however many are parked. A journal that
    cannot be read is never replaced,
    and a pending file that cannot be read is not folded; a pending file is
    removed only by a writer that took the lock and found it still its own
    after its write, and only once a committed write names the file as folded:
    the writer that first named it had read it, and a later writer removes such
    a leftover without reading it again. A writer that finds its lock was taken
    over while it was paused backs off: before its write it parks its event
    instead, and after it, it leaves the removals to a later writer (this
    narrows the lock's lease window, tracked in #151; it does not close it: a
    pause between the check and the write, or between the check and a removal,
    is not caught). Pending files are not bounded on their own:
    they accumulate until a writer takes the lock. History still never fails a
    launch; the wait for the lock is still at most 150 ms, and the file work
    after it is synchronous. (#145)

  • History validation no longer coerces values. An event whose kind or
    reason is not exactly one of the allowed strings is rejected, and the
    timestamp is stored in canonical ISO form, so a value that merely prints
    as an allowed one, or a date string carrying free text, cannot reach
    history.jsonl. (#145)

  • Side questions on the pool kept Claude Code's native tools. The pool
    declares sideQuestionToolMode: "disabled", which core trusts (no empty
    tool cap is injected for side questions), but its argv resolver ignored the
    execution mode, so /btw and setup probes ran with native Bash/Edit/Write
    selectable — under bypassPermissions when tools.exec.mode is full.
    resolveExecutionArgs now ports the bundled side-question projection:
    session/resume/fork/effort/tool/MCP-config flags are dropped and
    --safe-mode --tools "" --disallowedTools mcp__* --strict-mcp-config --no-session-persistence --max-turns 1 --permission-mode default is
    appended, in the bundled order (host-owned denial, side-question
    projection, exact cap). Non-side-question runs are unchanged. Verified
    against the 2026.8.1 and 2026.11.1 sources and through the shim on a
    fixture; not observed live. Published v2.6.6 did not include this
    projection. (#142)

  • The history bound now keeps the newest events of the merged history. Readers
    and writers apply the 500-event / 64 KiB bound to journal, parked and new
    events merged in event-time order (ties keep journal, then park order,
    then the new event), not to the journal followed by parked events. A
    backlog of older parked events could otherwise hide a just-recorded launch
    from explain --history and the spread count, and draining it could
    permanently trim newer launches in favour of older parked ones. The
    journal file is now kept in event order. (#145)

Repository

  • Dev-tree dependency floors only. The development install resolves
    undici 8.12.2, @modelcontextprotocol/sdk 1.32.0 and fast-uri 3.1.9.
    The published package still has no dependencies and does not install
    those copies, so this is not a consumer-runtime CVE fix. minimatch stays
    10.2.6. #157 stays open. (#158)