Skip to content

fix: preserve quoted replies in text sends#302

Open
clawsweeper[bot] wants to merge 3 commits into
mainfrom
clawsweeper/issue-openclaw-wacli-301
Open

fix: preserve quoted replies in text sends#302
clawsweeper[bot] wants to merge 3 commits into
mainfrom
clawsweeper/issue-openclaw-wacli-301

Conversation

@clawsweeper

@clawsweeper clawsweeper Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Summary

  • construct complete quoted-reply context from the referenced stored message
  • set the quoted participant correctly for incoming and own outgoing messages
  • reject missing or unsupported quote targets before sending
  • preserve reply fields through the sync --follow IPC delegate

Why

send text --reply-to currently emits only a stanza ID and optional participant. WhatsApp accepts and delivers the message but can omit the recipient-side quote box because QuotedMessage is absent. Direct-message lookups can also miss silently and still report a successful send.

Validation

  • table-driven DM and group quote-context tests
  • incoming and own-outgoing participant tests
  • missing-row and unsupported-content failure tests proving no send occurs
  • IPC request JSON round-trip coverage for reply fields
  • ordinary text-send regression coverage
  • full repository gate
  • redacted recipient-side proof for direct and IPC-delegated sends

Closes #301

Thanks @odilorg for the detailed report and live reproduction evidence.

@clawsweeper clawsweeper Bot added clawsweeper Tracked by ClawSweeper automation clawsweeper:autogenerated PR created automatically by ClawSweeper clawsweeper:autofix Maintainer opted this PR into bounded ClawSweeper-reviewed autofix without merge labels Jul 13, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. P2 Normal priority bug or improvement with limited blast radius. merge-risk: 🚨 compatibility 🚨 Merging this PR could break existing users, config, migrations, defaults, or upgrades. merge-risk: 🚨 message-delivery 🚨 Merging this PR could drop, duplicate, misroute, suppress, or wrongly target messages. labels Jul 13, 2026
@clawsweeper

clawsweeper Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor Author

Codex review: needs maintainer review before merge. Reviewed July 13, 2026, 6:26 PM ET / 22:26 UTC.

Summary
The PR builds complete quoted-message context for text sends, derives participants for incoming and own outgoing messages, preserves reply fields through IPC delegation, and adds focused regression tests.

Reproducibility: yes. The linked issue provides a concrete direct-message and IPC reproduction, and current-main source shows that reply context lacks QuotedMessage; this review did not independently run a live WhatsApp account.

Review metrics: 3 noteworthy metrics.

  • Changed surface: 3 files; 278 additions, 4 deletions. The patch remains concentrated in text-send behavior and its regression coverage.
  • Test expansion: 189 test additions. The added coverage exercises participant selection, failure paths, compatibility behavior, IPC serialization, and ordinary sends.
  • Required checks: 3 successful checks. Tests, Linux release builds, and Docker validation completed successfully on the reviewed head.

Root-cause cluster
Relationship: fixed_by_candidate
Canonical: #301
Summary: This PR is the explicit candidate fix for the linked quoted-reply delivery issue.

Members:

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

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🌊 off-meta tidepool
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.

Next step before merge

  • [P2] No repair job is indicated; the active PR can proceed through normal exact-head maintainer review and merge gating.

Security
Cleared: The Go send-logic and test changes do not alter dependencies, workflows, permissions, secrets, package resolution, or downloaded code.

Review details

Best possible solution:

Land the focused implementation after normal exact-head maintainer review so stored targets render complete quotes while the documented unsynced group fallback remains compatible.

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

Yes. The linked issue provides a concrete direct-message and IPC reproduction, and current-main source shows that reply context lacks QuotedMessage; this review did not independently run a live WhatsApp account.

Is this the best way to solve the issue?

Yes. Building complete context from stored messages while preserving the explicit unsynced-group fallback is the narrowest compatible correction, and the current head adds focused coverage for both paths.

AGENTS.md: found and applied where relevant.

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

Label changes

Label justifications:

  • P2: The PR fixes silently lost quoted-reply semantics in a bounded send workflow while ordinary message text continues to deliver.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This is an autogenerated ClawSweeper bot repair PR, so the external-contributor proof gate does not apply; the body also reports redacted recipient-side direct and IPC validation.
Evidence reviewed

What I checked:

  • Current-main defect: Current main creates reply context with a stanza ID and optional participant but does not populate QuotedMessage, matching the linked report's silently missing recipient-side quote. (github.com) (cmd/wacli/send.go:432, b1eb33538df3)
  • PR implementation: The current branch constructs text reply context from stored message data, supplies the linked account identity for own outgoing quotes, and retains a compatibility path for explicitly identified unsynced group replies. (cmd/wacli/send.go:223, b92d1917c684)
  • Regression coverage: The branch covers incoming and outgoing DM/group participants, missing and unsupported stored targets, the preserved unsynced group fallback, ordinary text sends, and IPC reply-field serialization. (cmd/wacli/send_test.go:303, b92d1917c684)
  • Re-review continuity: The earlier P1 finding about preserving the documented unsynced group-reply workflow was repaired; the latest completed ClawSweeper review of this exact head passed with no findings. (cmd/wacli/send.go:456, b92d1917c684)
  • Validation state: GitHub reports the PR cleanly mergeable, with the test, Linux release-build, and Docker checks successful on the current head. (b92d1917c684)
  • Repository contract: The public send documentation describes quoted replies and the explicit sender parameter used when replying to an unsynced group message. (wacli.sh) (docs/send.md:33, b1eb33538df3)

Likely related people:

  • dinakars777: The repository identifies this person as the current maintainer, and the prior review routed the send-command compatibility decision to them. (role: current repository maintainer; confidence: high; files: cmd/wacli/send.go, cmd/wacli/send_test.go, docs/send.md)
  • steipete: The repository identifies this person as the creator and former maintainer, making them relevant to the historical send CLI contract. (role: creator and former maintainer; confidence: medium; files: cmd/wacli/send.go, docs/send.md)
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.
Review history (3 earlier review cycles)
  • reviewed 2026-07-13T21:51:40.981Z sha 706d774 :: found issues before merge. :: [P1] Preserve the documented unsynced group-reply path
  • reviewed 2026-07-13T22:00:46.556Z sha 706d774 :: found issues before merge. :: [P1] Preserve the documented unsynced group-reply path
  • reviewed 2026-07-13T22:13:17.334Z sha b92d191 :: passed. :: none

@clawsweeper

clawsweeper Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor Author

🦞🧹
ClawSweeper autofix is enabled.

  • Head: 706d774b1da4
  • Label: clawsweeper:autofix
  • Action: exact-head review queued (workflow sweep.yml, event repository_dispatch).
  • Flow: review this head, repair/rebase only if needed, then re-review the exact repaired head until no actionable findings remain.

This is fix-only; I will not merge this PR.

Re-review progress:

@clawsweeper

clawsweeper Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor Author

🦞✅
ClawSweeper autofix is complete for this exact head.

Source: clawsweeper[bot]
Feedback: structured ClawSweeper verdict: pass (sha=b92d1917c684c1d960b3245ea4f165a111dc5db3)
Head: b92d1917c684

No actionable findings remain. I removed the repair-loop label and left the PR open for maintainer review and merge.

Automerge progress:

  • 2026-07-13 22:02:26 UTC review requested repair 706d774b1da4 (structured ClawSweeper needs-human verdict with repairable P-severity findings...)
  • 2026-07-13 22:06:29 UTC review queued b92d1917c684 (after repair)
  • 2026-07-13 22:15:10 UTC review passed b92d1917c684 (structured ClawSweeper verdict: pass (sha=b92d1917c684c1d960b3245ea4f165a111dc5...)

@clawsweeper clawsweeper Bot added 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: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. merge-risk: 🚨 message-delivery 🚨 Merging this PR could drop, duplicate, misroute, suppress, or wrongly target messages. merge-risk: 🚨 compatibility 🚨 Merging this PR could break existing users, config, migrations, defaults, or upgrades. clawsweeper:autofix Maintainer opted this PR into bounded ClawSweeper-reviewed autofix without merge labels Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clawsweeper:autogenerated PR created automatically by ClawSweeper clawsweeper Tracked by ClawSweeper automation P2 Normal priority bug or improvement with limited blast radius. 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.

send text --reply-to: message delivers but the quote is silently dropped (0.11.1)

0 participants