Repository navigation
fix(feishu): preserve canonical outbound delivery lifecycle - #117223
Conversation
|
Codex review: needs maintainer review before merge. Reviewed August 1, 2026, 1:47 AM ET / 05:47 UTC. ClawSweeper reviewWhat this changesThe PR refactors Feishu outbound text, media, card, and fallback sends so each accepted platform delivery reports through the canonical callback, reply targets survive chunk fanout, and a persistence failure does not trigger a duplicate fallback send. Merge readinessThe patch is still necessary: current Priority: P1 Review scores
Verification
How this fits togetherFeishu receives reply payloads from the plugin SDK and turns them into text, media, card, or comment sends. Each accepted platform send reports a delivery result back to the reply pipeline, which records progress before later chunks or fallible steps continue. flowchart LR
A[Agent reply payload] --> B[Feishu outbound adapter]
B --> C[Reply target fanout]
C --> D[Text media card or comment delivery]
D --> E[Delivery result callback]
E --> F[Reply progress and session record]
Decision needed
Why: The patch changes the channel's delivery-recording order and reply-target propagation; source and proof support it, but the protected Before merge
Agent review detailsSecurityNone. PR surfaceSource +12, Tests +254. Total +266 across 2 files. View PR surface stats
Review metricsNone. Stored data modelPersistent data-model change detected: Technical reviewBest possible solution: Retain one owner-local Feishu delivery lifecycle and have a Feishu owner confirm the current clean merge result before landing this exact tested head. Do we have a high-confidence way to reproduce the issue? Yes—source establishes that current Feishu sends can return a final result without per-accepted-delivery callback reporting, and the PR body supplies real localhost SDK scenarios for the affected text, media, and fanout paths. Is this the best way to solve the issue? Yes—the refactor repairs the Feishu outbound owner where accepted sends, reply fanout, and delivery callbacks meet, rather than adding downstream persistence or retry exceptions. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 6922ddd93610. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Merged via squash.
|
Co-authored-by: Peter Steinberger <[email protected]>
…in-4caff51-20260801 * origin/main: fix(agents): surface /new guidance for thinking-signature replay errors (openclaw#116967) (openclaw#116987) fix(doctor): keep repaired session rows readable (openclaw#117207) fix(feishu): unify outbound delivery lifecycle (openclaw#117223) docs(gateway): document llamacpp toolSchemaProfile for custom llama.cpp endpoints (openclaw#117120) fix(clickclack): thread replies stop being answered past the 100-reply thread window (openclaw#117225) fix(talk): retain bounded relay close owners fix(talk): bound relay transcript persistence
What Problem This Solves
Why This Change Was Made
One private outbound owner is responsible for all three reproduced root causes: duplicated text-only media requests, accepted provider chunks lost before later work fails, and explicitly chosen reply targets lost during provider-expanded Markdown fanout. A bounded refactor establishes one canonical per-platform-delivery path instead of adding independent special-case repairs. The existing Feishu-only production owner grows by 12 lines; no plugin SDK, public config, dependency, authentication, protocol, database schema, or other channel changes.
User Impact
Feishu operators see one text-only message instead of two, retain durable evidence for every accepted text/attachment before a later failure or retry, and keep explicit replies anchored through every expanded chunk. Existing implicit first-only replies, native topic roots, visible upload-failure fallback, degraded voice, original attachment behavior, and account isolation remain intact.
Evidence
67abd59475a3a2c1b8fa2a1bda26c8ce17694117; tree:761f4925dbe80b3c90111684d9515015cf902f0d; current main:4fb19fb8c586b2d7801d1c512a4ac21e4d826505; clean synthetic merge tree:c0510bf04d85a27731420a0855a7d8a8a7881f9a.git diff --check: passed.@larksuiteoapi/[email protected]with real localhost HTTP/auth/upload/message requests: 13/13 scenarios passed, including accepted-chunk persistence, later provider HTTP 400, receipt persistence failure, explicit/implicit replies, topic threads, upload fallback, and degraded voice.tbx_01kyxs681x92k629djyy15fjmw.extensions/feishu/src/doctor.test.tsalready fails identically on both this change's frozen baseb521ce626bfb479ba39e7919445c76e40d1d21aaand the actually tested then-currentmain618f3298c7dc00a41549e4dec41d8412f651624b; every relevant doctor/session-owner path remains byte-identical on currentmain4fb19fb8c586b2d7801d1c512a4ac21e4d826505. Its existing test helper attempts to writeagent:codex:acp:binding:feishu:default:abc123into theagent:mainSQLite session store, which the unchanged canonical owner rejects withSESSION_CANONICAL_KEY_MIGRATION_REQUIRED; the other 12 tests in that existing file pass. This PR changes neither the doctor nor session-owner paths.