Skip to content

fix: feishu reply context truncation + task events NULL data crash - #508

Merged
viettranx merged 2 commits into
nextlevelbuilder:mainfrom
Luvu182:fix/feishu-reply-truncate-and-task-events-null
Mar 27, 2026
Merged

fix: feishu reply context truncation + task events NULL data crash#508
viettranx merged 2 commits into
nextlevelbuilder:mainfrom
Luvu182:fix/feishu-reply-truncate-and-task-events-null

Conversation

@Luvu182

@Luvu182 Luvu182 commented Mar 27, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Feishu reply context: Increase replyContextMaxLen from 500 → 2000. The old limit was too aggressive for CJK/Unicode text (500 bytes ≈ ~250 Vietnamese/Chinese characters), causing reply context to be truncated with ...
  • Task events NULL crash: ListTaskEvents and ListTeamEvents crash with sql: Scan error on column index 5, name "data": unsupported Scan, storing driver.Value type <nil> into type *json.RawMessage when the data column is NULL. Fix with COALESCE(data, '{}')

Test plan

  • Send a long reply message (>500 bytes) on Feishu/Lark and verify the full reply context is preserved
  • Open a team page with task events that have NULL data column — should load without error

Luvu182 added 2 commits March 27, 2026 11:06
500 bytes is too short for CJK/Unicode text (each accented char = 2-3
bytes, so ~250 real characters). Increase to 2000 so reply context is
not aggressively truncated.
ListTaskEvents and ListTeamEvents crash with "unsupported Scan,
storing driver.Value type <nil> into type *json.RawMessage" when the
data column is NULL. Use COALESCE(data, '{}') to return an empty JSON
object instead.
@viettranx
viettranx merged commit 9e74974 into nextlevelbuilder:main Mar 27, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants