fix: remove truncated preview from inbound system events#67761
fix: remove truncated preview from inbound system events#67761jaredgalloway wants to merge 1 commit into
Conversation
Greptile SummaryRemoves the 160-character truncated message body preview from Confidence Score: 5/5Safe to merge — focused, well-tested fix with no behavioral regressions on the changed path. All three changed files make the same targeted, correct change. The preview variable is kept only where it has real consumers (debug log on line 806 in MS Teams, debug log on line 829 and return field on line 844 in Slack), and is cleanly removed in Mattermost where it had no other uses. No dead code is introduced. Extension tests passed on all three plugins and the build is clean. No files require special attention. Reviews (1): Last reviewed commit: "fix: remove truncated preview from inbou..." | Re-trigger Greptile |
|
Thanks for the context here. I swept through the related work, and this is now duplicate or superseded. Keep open. The patch is the right narrow fix for a source-reproducible Slack/Teams inbound message bug, but the PR is currently conflicting, lacks required real transport proof, and still carries a release-owned CHANGELOG edit. Canonical path: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. So I’m closing this here because the remaining work is already tracked in the canonical issue. Review detailsBest possible solution: Close this stale PR. The latest review rated it F, the branch still lacks merge-ready proof, and there has been no human follow-up after the durable review. Do we have a high-confidence way to reproduce the issue? Yes. Source inspection on current main shows Slack and Teams still enqueue a 160-character preview into model-visible system-event labels while separately preserving the full inbound body; I did not run a live Slack or Teams scenario in this read-only review. Is this the best way to solve the issue? Yes for the fix direction, but the submitted branch is not merge-ready. The narrow maintainable solution is to remove message content from arrival-only system-event labels, then refresh the branch, remove the changelog edit, and add real transport proof. Security review: Security review cleared: The diff changes channel event-label text, focused tests, and a changelog line; it does not touch dependencies, CI, secrets, auth, package resolution, or code-execution surfaces. AGENTS.md: found and applied where relevant. What I checked:
Likely related people:
Codex review notes: model internal, reasoning high; reviewed against c40db057da33. |
System events were including a truncated 160-char preview of the message body, leading to model confusion when the full message was delivered separately. The model would sometimes reference the truncated header instead of the full body. Now system events only contain the notification label (e.g., "Slack DM from Alice") without the message content. The preview is retained for debug logging where applicable. Fixes openclaw#67503
8091d60 to
4db272b
Compare
|
Prepared this one for maintainer review/CI.\n\nChanges made on top of the original patch:\n- Rebased onto current |
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
|
This pull request has been automatically marked as stale due to inactivity. |
|
ClawSweeper applied the proposed close for this PR.
|
Summary
Removes the truncated 160-char message preview from system event headers for Slack, MS Teams, and Mattermost channels.
Problem
System events were including a truncated preview of the message body:
This caused the model to sometimes reference the truncated header instead of the full message body, leading to responses like "your message got cut off at 'day o'" when the full message was delivered correctly.
Solution
System events now only contain the notification label without message content:
The system event's purpose is notification ("a message arrived"), not content delivery. The full message body is delivered separately in the user turn.
Changes
extensions/slack/src/monitor/message-handler/prepare.ts— remove preview from system event (keep for debug logging/type compat)extensions/msteams/src/monitor-handler/message-handler.ts— remove preview from system event (keep for debug logging)extensions/mattermost/src/mattermost/monitor.ts— remove preview from system eventTesting
pnpm test:extension slack— ✅ 641 tests passedpnpm test:extension msteams— ✅ 862 tests passedpnpm test:extension mattermost— ✅ 316 passed (1 timeout failure unrelated to changes)pnpm build— ✅Fixes #67503