fix(feishu): wrap markdown tables in code_block tags for post rendering - #22259
Closed
asdlem wants to merge 1 commit into
Closed
fix(feishu): wrap markdown tables in code_block tags for post rendering#22259asdlem wants to merge 1 commit into
asdlem wants to merge 1 commit into
Conversation
Feishu's post md tag drops markdown tables silently. Instead of forcing plain-text mode (which loses bold/links/lists), we: 1. Wrap tables in ``` fences via _convert_tables_to_code_blocks 2. Emit code_block tags in _build_markdown_post_rows for fenced content 3. Route to post mode so surrounding prose keeps its formatting Fixes NousResearch#21778
Contributor
Author
|
Supersedes #22047. Both PRs fix the same regression (tables forcing plain-text mode), but this one goes further:
Same bug fix + better UX for table content. |
This was referenced May 18, 2026
Contributor
Author
|
main now has _MARKDOWN_TABLE_RE fallback to plain text — the white-screen bug is resolved. The code_block approach here is more elegant but functionally redundant. |
19 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Feishu's post
mdtag drops markdown tables silently, while the old workaround (forcingtextmode) loses bold, italic,code, links, and lists.Solution
_convert_tables_to_code_blocks— wraps markdown tables in ``` fences_build_markdown_post_rows— detects ``` fences and emits Feishu's nativecode_blocktags (instead of `md`)_choose_outbound_msg_type— module-level routing: tables→code-fence+post, MD→post, else→text_build_outbound_payload— simplified to delegateResult
Related
Fixes #21778