Repository navigation
fix(reply): keep attachments and actions when reply text was already sent - #129230
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Merged via squash.
|
|
Codex review: needs maintainer review before merge. Reviewed August 25, 2026, 6:17 AM ET / 10:17 UTC. ClawSweeper reviewWhat this changesThe PR updates route-scoped message-tool reply deduplication so already-sent text does not suppress remaining media, interactive content, channel data, locations, or enabled delivery operations. Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readinessKeep open: this member-authored PR repairs a current silent reply-delivery defect with a shared owner-boundary change; it should proceed through normal exact-head CI and maintainer landing review. Priority: P1 Review scores
Verification
Live VerificationCommand: Result: PASS (completed) Assertions:
How this fits togetherMessaging tools can send content directly, while the auto-reply pipeline prepares the final assistant payload for channel delivery. The shared deduplication owner removes only content already sent to the same route before the final payload reaches a channel. flowchart LR
A[Assistant reply payload] --> B[Reply preparation]
C[Message tool send evidence] --> D[Route-scoped deduplication]
B --> D
D --> E[Remaining reply content]
E --> F[Channel delivery]
F --> G[Conversation output]
Before merge
Agent review detailsSecurityNone. PR surfaceSource -7, Tests +78. Total +71 across 2 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Retain one canonical route-scoped dedupe path that removes only already-delivered content while preserving any remaining deliverable reply payload content. Do we have a high-confidence way to reproduce the issue? Yes—source establishes a high-confidence owner-path reproduction: provide a payload whose text matches sent text but whose structured content remains unsent, then run final reply preparation. Is this the best way to solve the issue? Yes—the shared route-scoped dedupe owner is the narrowest maintainable repair because both agent-run and queued follow-up delivery flow through it. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against c29d4f9d6a3e. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
What Problem This Solves
Fixes an issue where assistant replies silently lost attachments, buttons, portable presentations, channel-specific content, locations, or delivery operations when a messaging tool had already sent the reply text. An already-sent legacy attachment could also erase distinct unsent attachment URLs.
Why This Change Was Made
The canonical reply-deduplication owner previously decided whether a complete payload was redundant by checking only its text and attachment fields. Reuse the existing authoritative reply-content predicate instead, preserve untouched plural attachment URLs while removing genuinely duplicated media, and delete the obsolete text-only deduplication wrapper.
Production delta: 19 additions / 26 deletions (net -7). No configuration, protocol, authentication, persistence, or plugin-SDK changes.
User Impact
Already-delivered text is still deduplicated, while every remaining unsent attachment, button, location, channel payload, and enabled delivery operation reaches its intended conversation.
Evidence
OPENCLAW_VITEST_MAX_WORKERS=1 node scripts/run-vitest.mjs src/auto-reply/reply/agent-runner-payloads.test.ts src/auto-reply/reply/reply-payloads.test.ts --reporter=dot— 112 passed, 1 existing Windows-only skip.