Skip to content

Telegram rich messages: /status card collapses into one run-on line (newlines lost) on 2026.6.9 #95538

Description

@ai-hpc

Summary

On OpenClaw 2026.6.9 with channels.telegram.richMessages: true, the /status (session status) card is delivered as a single run-on paragraph. Every status field is jammed inline on one line instead of one field per line. With rich messages off, the same card renders correctly with one field per line.

Environment

  • OpenClaw: OpenClaw 2026.6.9 (c645ec4)
  • Channel: Telegram direct chat
  • channels.telegram.richMessages: true
  • Status line itself confirms: Telegram rich messages: on · Bot API 10.1 sendRichMessage enabled

Observed behavior

The /status card arrives as one inline blob (newlines between fields are lost):

🦞 OpenClaw 2026.6.9 (c645ec4) ⏱️ Uptime: gateway 39s · system 7d 4h 🧠 Model: anthropic/claude-opus-4-8 · 🔑 oauth (claude-cli) 🗄 Cache: 92% hit · 36k cached, 3.0k new 📚 Context: 0/1.0m (0%) · 🧹 Compactions: 0 🧵 Session: agent:main:telegram:direct:... • duration 29s • updated just now Telegram rich messages: on · Bot API 10.1 sendRichMessage enabled ⚙️ Execution: direct · Runtime: OpenClaw Default · Think: off · Fast: off 🔌 Plugins: OK 🪢 Queue: steer (depth 0)

Expected behavior

Each status field on its own line, as it renders when rich messages are off:

🦞 OpenClaw 2026.6.9 (c645ec4)
⏱️ Uptime: gateway 39s · system 7d 4h
🧠 Model: anthropic/claude-opus-4-8 · 🔑 oauth (claude-cli)
🗄 Cache: 92% hit · 36k cached, 3.0k new
📚 Context: 0/1.0m (0%) · 🧹 Compactions: 0
🧵 Session: agent:main:telegram:direct:... • duration 29s • updated just now
Telegram rich messages: on · Bot API 10.1 sendRichMessage enabled
⚙️ Execution: direct · Runtime: OpenClaw Default · Think: off · Fast: off
🔌 Plugins: OK
🪢 Queue: steer (depth 0)

Likely root cause

The status card is assembled as plain text with single \n between fields (buildStatusText / buildStatusMessage in dist/status-text-*.js). When richMessages is on, the text is delivered via the rich path:

sendChunkedTextbuildRichTextPlansplitTelegramRichMessageTextChunksrichRawApi.sendRichMessage({ rich_message: buildTelegramRichMessage(chunk.text, chunk.textMode, ...) }) (dist/send-DRU0vBJ-.js ~L1214–1243).

If chunk.textMode is markdown, a single newline is treated as a soft break and collapses adjacent lines into one paragraph — exactly the observed run-on. The plain-text (sendMessage) path preserves single newlines, which is why rich-off renders correctly.

So the status card (built for plain text) needs hard line breaks when routed through the rich/markdown renderer — e.g. preserve single \n as hard breaks in the status-card rich path, or emit the card with explicit hard breaks / a preformatted block when richMessages is on.

Impact

The /status card is one of the most frequently viewed surfaces and is unreadable as a single run-on line for Telegram users who have rich messages enabled (now the shipped default-path direction per #94885). Other multi-line text built with single \n may be affected by the same collapse.

Possibly related

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Normal backlog priority with limited blast radius.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions