Skip to content

Suppress assistant NO_REPLY chat directives - #884

Merged
shanselman merged 1 commit into
openclaw:mainfrom
TurboTheTurtle:fix-windows-no-reply-882
Jun 30, 2026
Merged

shanselman merged 1 commit into
openclaw:mainfrom
TurboTheTurtle:fix-windows-no-reply-882

Conversation

@TurboTheTurtle

@TurboTheTurtle TurboTheTurtle commented Jun 28, 2026 •

Copy link
Copy Markdown
Contributor

Closes #882.

Suppress assistant-only NO_REPLY chat directives in shared gateway live/history ingestion and tray chat hydration/live paths. User messages that literally say NO_REPLY still flow through.

Validation

  • GitHub Build and Test is green for this head.
  • .\build.ps1 — passed.
  • dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore — 2632 passed, 31 skipped.
  • dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore — 1435 passed.
  • Fresh-worktree note: tests were restored once in the isolated validation worktree before rerunning the required --no-restore commands.

Real behavior proof

  • Upstream OpenClaw behavior confirmed: openclaw/openclaw defines SILENT_REPLY_TOKEN = "NO_REPLY" in src/auto-reply/tokens.ts; normalize-reply.ts drops exact silent replies; reply-dispatcher.ts logs exact NO_REPLY finals skipped before delivery; and docs/platforms/mac/webchat.md documents that chat.history omits exact NO_REPLY / no_reply assistant rows.
  • Disposable console harness referencing src/OpenClaw.Shared/OpenClaw.Shared.csproj at 797c8be1 invoked the runtime gateway ProcessMessage path with assistant and user session.message frames.

Command: dotnet run --project /tmp/openclaw-gateway-proof.BsT7VI/openclaw-gateway-proof.BsT7VI.csproj

assistant_NO_REPLY_events=0
total_events_after_user_literal=1
preserved_user_role=user
preserved_user_text=NO_REPLY

@TurboTheTurtle

Copy link
Copy Markdown
Contributor Author

@clawsweeper review

@clawsweeper

clawsweeper Bot commented Jun 28, 2026 •

Copy link
Copy Markdown

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@clawsweeper

clawsweeper Bot commented Jun 28, 2026 •

Copy link
Copy Markdown

Codex review: needs maintainer review before merge. Reviewed June 30, 2026, 12:53 PM ET / 16:53 UTC.

Summary
The branch adds assistant-only NO_REPLY suppression in shared gateway live/history ingestion and tray chat live/history paths, with shared/tray regression tests preserving user literal NO_REPLY text.

Reproducibility: yes. from source inspection: current main emits non-empty assistant session.message/history rows and the tray assistant render path has no NO_REPLY guard. I did not run a live Windows tray repro in this read-only review.

Review metrics: 3 noteworthy metrics.

  • Changed surface: 5 files, +150/-0. The runtime change spans both shared gateway ingestion and tray chat consumers with matching tests.
  • Regression tests: 5 tests added across 2 test projects. Coverage exercises live suppression, history suppression, and preserving a user message that literally says NO_REPLY.
  • Runtime proof: 1 copied live-output harness. The PR body shows current-head gateway output where assistant NO_REPLY is dropped and user literal NO_REPLY is preserved.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #882
Summary: This PR is the open candidate fix for the canonical Windows tray NO_REPLY rendering bug.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🐚 platinum hermit
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • none.

Mantis proof suggestion
A short visual tray proof would help maintainers see the UI-facing symptom is gone, even though terminal proof and tests cover the core behavior. A maintainer can ask Mantis to capture proof by posting this exact PR comment:

@openclaw-mantis visual task: verify Windows tray chat suppresses assistant NO_REPLY frames while preserving a user message that says NO_REPLY.

Risk before merge

  • [P1] This read-only review did not rerun ./build.ps1 or the required Shared/Tray dotnet test commands locally; I relied on the contributor's reported commands and green GitHub Build and Test checks.

Maintainer options:

  1. Decide the mitigation before merge
    Land the narrow suppression after maintainer acceptance of the validation/proof, allowing Chat UI renders NO_REPLY directive as raw text instead of suppressing it #882 to close on merge.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • [P2] No repair lane is needed; the patch appears code-correct and the remaining action is ordinary maintainer review or merge.

Security
Cleared: The diff only adds exact directive filtering and focused tests; it does not change dependencies, scripts, credentials, permissions, or other code execution surfaces.

Review details

Best possible solution:

Land the narrow suppression after maintainer acceptance of the validation/proof, allowing #882 to close on merge.

Do we have a high-confidence way to reproduce the issue?

Yes, from source inspection: current main emits non-empty assistant session.message/history rows and the tray assistant render path has no NO_REPLY guard. I did not run a live Windows tray repro in this read-only review.

Is this the best way to solve the issue?

Yes: exact assistant-only filtering at the shared gateway boundary plus tray-side live/history defenses is a narrow maintainable fix. I did not find an existing config path or duplicate supported implementation that would be safer.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against ad943b9e6fd8.

Label changes

Label justifications:

  • P2: This is a focused normal-priority tray chat rendering bug fix with limited blast radius and a linked bug report.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The PR body contains copied current-head live output from a runtime gateway harness showing assistant NO_REPLY suppression and user literal preservation.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body contains copied current-head live output from a runtime gateway harness showing assistant NO_REPLY suppression and user literal preservation.
Evidence reviewed

What I checked:

  • Repository policy read and applied: AGENTS.md was read fully; its tray/chat proof guidance applies, while the read-only review contract prevented local build/test execution. (AGENTS.md:1, ad943b9e6fd8)
  • Current main shared live gap: Current main extracts non-empty assistant chat text and emits ChatMessageReceived with no NO_REPLY guard before notification/render consumers can receive it. (src/OpenClaw.Shared/OpenClawGatewayClient.cs:3072, ad943b9e6fd8)
  • Current main tray render gap: Current main reaches the assistant render path after role and empty-text checks, so a non-empty assistant NO_REPLY payload can render. (src/OpenClaw.Tray.WinUI/Chat/OpenClawChatDataProvider.cs:1817, ad943b9e6fd8)
  • PR suppression diff: The PR adds ChatMessageInfo.IsSilentAssistantDirective and applies it to chat.history parsing, new-format live chat, legacy live chat, the final emission boundary, and tray history/live defenses. (src/OpenClaw.Shared/OpenClawGatewayClient.cs:547, 797c8be195ff)
  • Regression coverage: The diff adds shared tests for assistant suppression, user literal preservation, and history suppression, plus tray tests for live and history suppression. (tests/OpenClaw.Shared.Tests/OpenClawGatewayClientTests.cs:854, 797c8be195ff)
  • Proof and CI signal: The PR body reports AGENTS-required build/shared/tray commands passed and includes copied runtime gateway harness output showing assistant_NO_REPLY_events=0 while a user NO_REPLY message is preserved; GitHub Build and Test checks are green for the head. (797c8be195ff)

Likely related people:

  • bkudiess: Current-main blame and GitHub commit history attribute the current chat.history/live chat and tray provider regions to recent chat command/model work on the affected files. (role: recent area contributor; confidence: high; commits: a3c5e0bf6fce, d6b1a72f6d23; files: src/OpenClaw.Shared/OpenClawGatewayClient.cs, src/OpenClaw.Tray.WinUI/Chat/OpenClawChatDataProvider.cs, tests/OpenClaw.Tray.Tests/OpenClawChatDataProviderTests.cs)
  • RBrid: Repository history shows substantial native chat timeline/provider work and inline approval flow changes adjacent to the live/history chat rendering path. (role: feature-history contributor; confidence: medium; commits: 08cab69a038c, 5505a85da7df, 4e7982bafb86; files: src/OpenClaw.Tray.WinUI/Chat/OpenClawChatDataProvider.cs, src/OpenClaw.Shared/OpenClawGatewayClient.cs)
  • christineyan4: GitHub history shows recent chat UI/gateway-adjacent work touching the same shared gateway client and tray chat provider surfaces. (role: recent adjacent contributor; confidence: medium; commits: 992da748c31b, 8c9acbcfb5d8, 488f26509ced; files: src/OpenClaw.Shared/OpenClawGatewayClient.cs, src/OpenClaw.Tray.WinUI/Chat/OpenClawChatDataProvider.cs)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P2 Normal priority bug or improvement with limited blast radius. labels Jun 28, 2026
@TurboTheTurtle

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@TurboTheTurtle

Copy link
Copy Markdown
Contributor Author

@openclaw-mantis visual task: verify Windows tray chat suppresses assistant NO_REPLY frames while preserving a user message that says NO_REPLY.

@clawsweeper clawsweeper Bot added proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Jun 28, 2026
@shanselman
shanselman merged commit 65b88d8 into openclaw:main Jun 30, 2026
12 checks passed
@TurboTheTurtle
TurboTheTurtle deleted the fix-windows-no-reply-882 branch June 30, 2026 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Chat UI renders NO_REPLY directive as raw text instead of suppressing it

2 participants