-
-
Notifications
You must be signed in to change notification settings - Fork 80.3k
[Bug]: Telegram-originated turns corrupt session tree — all subsequent messages parented to cache-ttl B-node, causing duplicate renders and delayed re-answers #94930
Copy link
Copy link
Closed
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.bugSomething isn't workingSomething isn't workingbug:behaviorIncorrect behavior without a crashIncorrect behavior without a crashclawsweeper:linked-pr-openClawSweeper found an open linked pull request for this issue.ClawSweeper found an open linked pull request for this issue.clawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.ClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:securitySecurity boundary, credential, authz, sandbox, or sensitive-data risk.Security boundary, credential, authz, sandbox, or sensitive-data risk.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Description
Metadata
Metadata
Assignees
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.bugSomething isn't workingSomething isn't workingbug:behaviorIncorrect behavior without a crashIncorrect behavior without a crashclawsweeper:linked-pr-openClawSweeper found an open linked pull request for this issue.ClawSweeper found an open linked pull request for this issue.clawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.ClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.impact:securitySecurity boundary, credential, authz, sandbox, or sensitive-data risk.Security boundary, credential, authz, sandbox, or sensitive-data risk.impact:session-stateSession, memory, transcript, context, or agent state can drift or corrupt.Session, memory, transcript, context, or agent state can drift or corrupt.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Type
Fields
No fields configured for issues without a type.
Bug type
Behavior bug (incorrect output/state without crash)
Beta release blocker
No
Summary
Every assistant turn in WebChat writes a second identical message(role=assistant) record as a child of the openclaw.cache-ttl session entry, causing WebChat to render each reply twice.
Steps to reproduce
Path: ~/.openclaw/agents/main/sessions/.jsonl
Expected: two consecutive message records with role: "assistant",
identical content, timestamps within ~1 second, and different
parentId values — one being the id of an openclaw.cache-ttl record.
Expected behavior
One assistant message per turn in WebChat.
Actual behavior
Two identical assistant messages rendered per turn. Session JSONL confirms this is not a client-side rendering issue: the JSONL itself contains two
message(role=assistant)entries per turn, forming the tree:The duplicate (B) has a different
idformat (full UUID vs short hex for the primary), a differentparentId, andidempotencyKey: null. Pattern observed on every turn in the session — 6 confirmed pairs.OpenClaw version
2026.6.8 (844f405)
Operating system
macOS 25.5.0 Darwin arm64 (Apple M4)
Install method
npm global
Model
claude-sonnet-4-6
Provider / routing chain
openclaw → meridian (local OAuth proxy) → Anthropic
Additional provider/model setup details
No response
Logs, screenshots, and evidence
All 6 duplicate pairs from session 3ad55650-86b7-4028-b3a3-091c92776fb2: PAIR 1: A id=29dc915b parent=bfcafeb6 ts=10:05:13.618Z len=330 B id=d8566daf-8796-4ded-a6e1-f222380b4de5 parent=28ed4f69 ts=10:05:14.413Z len=330 PAIR 2: A id=7a98a048 parent=4478f66b ts=10:19:26.345Z len=623 B id=7838f911-c874-4b22-969a-16fefeaaa652 parent=bf13e59d ts=10:19:39.422Z len=623 PAIR 3: A id=f9c13c38 parent=0a31d550 ts=10:23:40.840Z len=1088 B id=e720048d-48ff-4a1d-91cd-70e762e04bc2 parent=4e59e4f8 ts=10:23:42.432Z len=1088 PAIR 4: A id=be98e1a7 parent=59d6cd84 ts=10:25:32.038Z len=1613 B id=5b435097-ca71-491a-beb4-b91aafc03e96 parent=fa1c8d57 ts=10:25:33.155Z len=1613 PAIR 5: A id=c71ecced parent=b70a0105 ts=10:29:56.159Z len=401 B id=f1a40b40-060f-487c-b6a3-475fc24a917a parent=3a0ba6f2 ts=10:29:57.087Z len=401 PAIR 6: A id=f55093ea parent=a2240660 ts=10:30:55.783Z len=1193 B id=72b29193-fe0c-4436-a372-198b1c8287b6 parent=0f29a1f4 ts=10:30:56.945Z len=1193 All B records: idempotencyKey=null, content identical to A. Telegram channel unaffected (only primary message A is delivered). streaming.mode tested: "off" and "partial" — both produce duplicates. Plugins: lossless-claw 0.13.1, openclaw-amem, openshell, browser-automation, brave, diffs (all official).Impact and severity
Affected: All WebChat users on 2026.6.8 (reproduced 100% of turns in one session)
Severity: High — every reply is visually doubled, degrading chat usability
Frequency: Always (every assistant turn)
Consequence: User sees every response twice; Telegram users unaffected
Additional information
Not a duplicate of #5964: In #5964, the session JSONL contained no duplicate entries (pure client-side rendering race condition). In this report, the JSONL itself contains two
message(role=assistant)entries per turn — the root cause is in session-tree write logic, not rendering.Not a duplicate of #85771: Same symptom, different root cause. #85771 is a UI rendering bug. This is a backend session-tree write bug where the JSONL itself stores two assistant messages per turn.
Related to #28491: The
openclaw.cache-ttlcustom entry has a known history of bypassing guards. The duplicate assistant message is appended as a child of this entry and may share the same insertion logic.