Hacktoberfest 2026:維護者為十月標記出來的 issue,仍然開放、適合新手。 瀏覽 Hacktoberfest issue

An HTML-only inbound email reaches its trigger with HTML character references left in the text

已關閉
#806 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

@RaphaelFakhri 已經在處理了。

開始於 2026年10月18日。

  • #807 來自 @RaphaelFakhri —— 未關閉

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
25/100
Issue 類型
缺陷
描述清晰度
描述清楚
活躍度
停滯
技術堆疊
typescript
領域
backend

研究方向

Start in server/src/responsibilities/email.ts at extractEmailText and trace the HTML branch that strips tags and collapses whitespace. Reproduce with the HTML-only sample in the issue, then check whether the extracted text decodes its character references to match the expected output. Issue #807 is already an open linked pull request.

由索引模型根據 Issue 內容生成。

描述

An email trigger (SES -> SNS -> /sns) reads an HTML-only mail through extractEmailText in server/src/responsibilities/email.ts. The HTML branch strips <style>, <script> and every tag, then collapses whitespace. It never decodes character references, so the payload text the Bot receives keeps them as written.

A mail whose only part is:

Content-Type: text/html; charset=utf-8

<p>Q3&nbsp;numbers for AT&amp;T: margin &lt; 5%, we&#8217;re &quot;on&nbsp;track&quot;</p>

reaches the Bot as:

Q3&nbsp;numbers for AT&amp;T: margin &lt; 5%, we&#8217;re &quot;on&nbsp;track&quot;

Expected

Q3 numbers for AT&T: margin < 5%, we’re "on track"

Outlook and most HTML editors write &nbsp;, &amp; and numeric references such as &#8217; throughout a message, so an HTML-only mail is read, quoted and summarised with these sequences in it.

Reproduce

import { extractEmailText } from "./server/src/responsibilities/email";
extractEmailText("Content-Type: text/html\r\n\r\n<p>AT&amp;T&nbsp;ok</p>");
// "AT&amp;T&nbsp;ok"

Found on main at 12c3a69.

主要語言
TypeScript
星號
6.6k
分支
914
平均合併
22 小時 56 分鐘
30 天內合併 PR
141

環境準備

  • 提供 Dockerfile 或 Docker Compose 檔案
  • 有 Pull Request 範本
  • 沒有貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

CopilotKit/OpenBot 的其他 Issue

查看 CopilotKit/OpenBot 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。