You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
telegram: rich messages render $…$ as math and collapse single newlines #1109
Since 4.41, postMessage({ markdown }) goes through sendRichMessage with the markdown passed unchanged (resolveRichMessage). Telegram's rich-message parser differs from the CommonMark the adapter assumes elsewhere:
$…$ is inline math. MU ~$950 (-3.3% from $983.23). TSLA ~$403 renders 950(−3.3from983.23)… as a formula, and % inside it starts a TeX comment that drops the rest of the span.
A single \n is a soft break, so line-per-item text (• a\n• b) becomes one paragraph. The MarkdownV2 path kept those lines.
\$ and trailing-backslash hard breaks both render correctly in sendRichMessage. Verified with the Bot API directly. Still present in 4.43.0.
Suggested fix: escape $ outside code, and either emit hard breaks for soft line breaks or document that callers must.
Activity