Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Agent ingress HTML-escapes message bodies and silently truncates long bodies

Đã đóng
#53,224 1 bình luận 0 reaction 1 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

@rekram1-node đang làm issue này rồi.

Từ ngày 4/10/2026.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

Description

Message bodies arriving at opencode agents via the Slack bridge are corrupted in two silent ways. Nothing errors; the text is just wrong when it lands in agent context, beads, PRs, and shell commands.

Defect 1 — HTML entity escaping (silent, length-preserving)

Message bodies are HTML-escaped on ingress: < → &lt;, > → &gt;, & → &amp;.

Evidence (2026-09-30):

  • An agent sent a raw <main> inside a plain-text sentence; the receiving agent quoted it back still escaped — confirms escaping affects Slack messages themselves, not just downstream tooling.
  • Inbound scope blocks reached agents with &lt;main&gt; and &amp; already escaped.
  • Ruled out: voltron slack-post delivery path, model output — this is a normalising transform on ingress in the harness/context-assembly layer.

Impact: any agent copying an HTML tag, shell metacharacter (>, |, &), or comparison operator out of a bridge message pastes corrupted text into code, beads, PRs, or shell commands. Silent wrong-state.

Defect 2 — long-body truncation (lossy)

Long message bodies are cut off, usually mid-block. Observed three times in one session:

  1. A task group (4 items) arrived entirely absent — heading survived, content did not.
  2. Groups C, D, E of a 138-line source file arrived absent (lines 85–138).
  3. A closing rationale cut mid-sentence.

System details

  • OpenCode version: 1.18.34
  • Operating system: macOS 27.0
  • Slack bridge/client setup: custom fleet bridge (voltron/scripts/slack-post) delivering agent messages into opencode agent sessions; corruption observed on ingress into the agent context layer, after bridge delivery (bridge itself verified clean — entity forms present in agent-received bodies, not in bridge output)

Steps to reproduce

  1. Send any message containing <, >, or & through the Slack bridge to an opencode agent; observe the entity form in the agent's received body.
  2. Send a body above some length threshold; observe truncation mid-block.

Expected behavior

Message bodies arrive byte-identical: raw <, >, & preserved; long multi-block bodies complete.

Ask

  1. Locate the ingress/context-assembly path where entities are escaped and where bodies are truncated.
  2. Preserve raw text on ingress (or provide an explicit escape contract agents can rely on).
  3. Fix or remove the truncation limit — silent mid-block loss destroys task scope.
  4. Regression test: body with <, >, &, and a >2k multi-block message arrives byte-identical.

Cross-reference

  • Linear: MG-1550 (metrograph-ai)
  • Folded bead: MG-1552 (closed, scope merged into MG-1550)
  • Original investigation ruled out: voltron delivery path, model output
Ngôn ngữ chính
TypeScript
Star
221k
Fork
29.6k
Merge trung bình
5 giờ 22 phút
Pull request đã merge (30 ngày)
531

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của anomalyco/opencode

Tất cả issue của anomalyco/opencode

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.