Repository navigation
fix(discord): keep long table labels bold across messages - #205328
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThis PR closes and reopens bold formatting when a long Discord table label crosses a message boundary. Example: Send a bullet-rendered table with a 1,997-character first-column label and State: Ok.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR addresses a concrete formatting gap still present on main; source review found no definite introduced defect. Reviewed head: Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherDiscord delivery converts Markdown tables to labeled bullets, then the Discord chunker produces bounded message payloads for bot and webhook sends. flowchart LR
A[Markdown reply] --> B[Discord Markdown formatter]
B --> C[Table bullet labels]
C --> D[Discord source range chunker]
D --> E[Bot or webhook sender]
E --> F[Discord messages]
Technical reviewBest possible solution: Keep the repair in Discord's existing source-range renderer, preserving label text, message limits, and current code-formatting behavior. Do we have a high-confidence way to reproduce the issue? The table producer emits a 2,001-unit bold span for a 1,997-character label, while main splits without balancing strong delimiters; this establishes the source path, but no target code was executed during this read-only review. Is this the best way to solve the issue? The approach uses the existing Discord boundary owner and declared Markdown parser dependency; simplification review found no definite unnecessary production machinery or unrelated change. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 52715199483c. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +76, Tests +75. Total +151 across 2 files. Added test files: 0. View PR surface stats
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed November 25, 2026, 7:19 AM ET / 12:19 UTC. |
|
Merged via squash.
|
* commit '92569e37ab84a8cb1e4a12c3dcbb45acb97977c9': fix: distinguish Desktop sources without wrapping their names or IDs (#203747) fix(ui): Greek sigma searches miss matches outside Sessions and Files (#189518) fix: keep agent skill names on one line beside their switches (#203734) test(cron): admit scheduled occurrences in cron fixtures and fix Node 24 toHex in Vitest (#205383) fix: keep the Agents menu usable after copying an ID (#203739) fix(whatsapp): preserve code table spaces across message chunks (#205327) refactor(cron): admit legacy scheduled requesters through operator admission (#205346) fix: keep silent Codex turns healthy with running commands (#196062) test(update): verify the recorded preparation failure (#205363) fix(test): prove sibling imports on the active update path fix(chat): complete mentions without leaving part of the name behind (#205326) fix(test): restore Side chat hydration and retry checks (#205376) refactor: plugin-run turns get owner status from commands.ownerAllowFrom, like text messages (#205373) chore(ui): refresh control ui locales (#205378) fix: keep Telegram rich <details> and list blocks in one message when replies stream in chunks (#205318) refactor(gateway): one refusal owner with a required next step (#205337) fix(discord): keep long table labels bold across messages (#205328) feat: invitation, sharing and participant controls in the Control UI (#204920) fix(test): distinguish stamped Skill Library upgrade policies fix(markdown): preserve trailing inline-code spaces in plain-text tables (#205317)
…05328) Co-authored-by: Vincent Koc <[email protected]>
What Problem This Solves
With Discord tables rendered as bullets, a long first-column label could cross the 2,000-character message limit. Each message then carried only part of the bold markup. A 1,997-character label became italic and exposed a literal asterisk in an independent Markdown parse.
User Impact
Long labels stay bold across the message boundary. Their text and the fields that follow remain in order. A 1,996-character label still fits intact in the first message.
Why This Change Was Made
The formatter already produces the intended bold span. The Discord chunker now recognizes a parsed standalone bold label and accounts for closing and reopening it when measuring each message. Thanks to @jakepresent for reporting the broader Discord Markdown splitting problem and exploring an earlier repair. Earlier report · Earlier proposal
Evidence
Captured serialized requests from the ordinary guild-channel sender using a synthetic REST transport. At label lengths 1,996, 1,997 and 1,998, the two messages measured 2,000/11, 2,000/17 and 2,000/18 UTF-16 units. Parsing each message independently preserved every label character in bold and exposed zero literal stars. Both the original generated failure and its shrunk example passed. Additional captures covered an escaped star in a two-row table, ordinary text, escaped markup, inline code and fenced code.
Formatting and whitespace checks passed. Hosted Vitest for the Discord sender is pending. The capture covers outgoing content and parsed formatting. Live Discord client appearance is unverified.