-
-
Notifications
You must be signed in to change notification settings - Fork 79.1k
[feishu] Streaming card sends incremental diff instead of full text to CardKit API #88335
Copy link
Copy link
Open
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Metadata
Metadata
Assignees
Labels
P1High-priority user-facing bug, regression, or broken workflow.High-priority user-facing bug, regression, or broken workflow.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.impact:message-lossChannel message delivery can be lost, duplicated, or misrouted.Channel message delivery can be lost, duplicated, or misrouted.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Bug Description
In card mode with streaming enabled, the Feishu plugin sends incremental text diffs to the CardKit API instead of the full text content. This causes fragmented/flickering display on the client side — each streaming update shows only the new fragment rather than appending to existing text with a typewriter effect.
Root Cause
resolveStreamingCardAppendContent()inmonitor.account-*.jscomputes a diff:This diff is passed to
updateCardContent()→PUT /cardkit/v1/cards/{id}/elements/content/contentas thecontentfield.However, per Feishu CardKit streaming docs:
(Translation: Continuously pass in the full text content to plain_text or markdown elements. The platform automatically calculates the incremental part and renders it character by character with a typewriter effect.)
The API expects the full text each time. The platform itself calculates the delta for typewriter rendering.
Expected Behavior
Each streaming update should send the full accumulated text. The CardKit platform auto-computes the diff for typewriter effect.
Suggested Fix
Environment
Workaround
Setting
streaming: falseon the feishu account config disables streaming and avoids the issue, at the cost of no real-time output.