Skip to content

fix(slack): recover trusted bot attachment text - #13651

Merged
iamwhatever merged 2 commits into
kirodotdev:mainfrom
Alexander-Yuan:fix/slack-trusted-bot-attachment-fallback-13405
Oct 12, 2026
Merged

iamwhatever merged 2 commits into
kirodotdev:mainfrom
Alexander-Yuan:fix/slack-trusted-bot-attachment-fallback-13405

Conversation

@Alexander-Yuan

@Alexander-Yuan Alexander-Yuan commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Let configured trusted Slack bots route attachment-only alarm-card text into the existing message flow.

Trusted Slack bots can send alarm cards with empty top-level text. When the card content exists only inside an ordinary attachment, Kiro Crew drops the message before a turn starts.

Why it matters

AWS Chatbot and Amazon Q alarm cards can disappear silently even when the sender is trusted and the Slack channel is configured to route messages. Plain-text messages from the same bot still work, which makes the failure hard to diagnose.

Not a goal

  • Recover attachment text for human messages or bots that fail the existing trust allowlist.
  • Change top-level text, forwarded-message routing, or how trusted bot identities are configured.

What changed (motivation → approach → change)

The drop happens in src/kiro_crew/slack/events.py after normal shared-message extraction returns no text. At that point, and only for a positively admitted trusted bot, Slack recovers ordinary attachment content: a real trimmed fallback first, otherwise Block Kit text when the fallback is blank or one of Slack's generic placeholders.

One bounded Block Kit renderer handles rich_text, section.text, and context for both paths. Trusted ordinary attachments enable its section.fields branch. Forwarded-message output stays unchanged. Each renderer invocation has a hard 16,000-character traversal and output cap. The trusted-bot attachment loop separately enforces one 16,000-character global budget across attachments and separators. Container and scalar fields are accepted only in their expected types. The owning Slack specification records these boundaries.

Backwards compatibility

Compatible: existing top-level text and forwarded-message precedence are unchanged. Ordinary attachment recovery is reachable only for positively admitted trusted bots after the existing shared-message path yields no content; human, untrusted-bot, and link-unfurl behavior remains excluded.

Tests

  • test/test_slack_events_coverage.py and test/test_events_forward.py: 321 passed, covering trusted fallback, section.text, trusted-only section.fields, text-before-fields ordering, iterable and non-iterable malformed fields, forwarded and is_msg_unfurl non-reclassification, human/untrusted exclusion, generic placeholders, per-renderer and trusted-bot global budgets, stripped-output budget consumption, renderer-exhaustion ordering, traversal stop, and per-test turn-ledger isolation.
  • Backend related set: 48,532 passed, 94 skipped, and 5 expected failures across 524 files selected from the diff and reverse references.
  • Frontend related set: 480 files and 13,361 tests passed.
  • All 58 resolved prepare-pr gates plus the reproducible make build passed, including Black, isort, flake8, mypy, docs, vendor, CloudFormation, TypeScript, ESLint, i18n, Electron, duplication, bundle-size, and cycle checks.
  • Green-age re-sync validation on the current head passed 951 overlap-selected tests, documentation lint, mypy, and the diff check. test_app_script_cron_sibling_import.py reaches PlatformCompositionError during collection on this enterprise-profile host and reproduces identically on clean origin/main, isolating a base/environment failure outside the Slack patch.
  • Whole-change fault seed: restoring the production bug while retaining the tests causes a call-phase assertion failure (prove.py: PROVEN).

Manual verification

Not performed: no live Slack alarm card was sent. The automated tests exercise the production admission, extraction, and dispatch path with serialized Slack event shapes; provider payload variants outside those fixtures remain a residual risk.

Screenshots / video

N/A — no user-interface surface changes.

Related Issues

Fixes #13405

Pattern harvest

Rule candidate: review-prompt
Pattern: external message recovery must stay behind positive trust admission, validate payload shapes, and enforce resource limits before accumulation.

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

@Alexander-Yuan
Alexander-Yuan requested review from a team and Zedmor September 25, 2026 02:27
@github-actions github-actions Bot added the fork Pull request from a fork (external contributor) label Sep 25, 2026
@Alexander-Yuan

Copy link
Copy Markdown
Contributor Author

Intent: Route attachment-only Slack cards after positive trusted-bot admission so trusted alarm bots can start a turn.
Not a goal: Widen attachment recovery for humans or untrusted bots, or change existing link-unfurl routing.

@Alexander-Yuan

Alexander-Yuan commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor Author

Current head e1d2305685c5a9b3c63d7c9c9e8b27e6c48412fe reached no code failure, but three jobs exhausted the GitHub App installation API quota. This fork contributor cannot use the Actions rerun API (Must have admin rights to Repository). Could a maintainer rerun only the failed jobs in these runs?

  • Fork PR Description: description validation succeeded; publishing its check-run failed on the installation rate limit.
  • PR Readiness: readiness evaluation/publish failed on the same installation rate limit.
  • Build: the desktop-matrix paths-filter call failed on the same installation rate limit.

The green-age rebase is locally validated (951 overlap-selected tests plus docs/mypy), and no source change is indicated by these failures, so I have not pushed an unchanged commit to retrigger them.

@Alexander-Yuan
Alexander-Yuan requested a review from a team as a code owner September 28, 2026 17:25
@Alexander-Yuan

Copy link
Copy Markdown
Contributor Author

Re-triggered the fork checks with no-code commit 7b8d5dc51d672f849e5c50b28c311cf165d65983. It has the same tree (cbdbcc75657ebecab93816c1eba306656e39bba0) as 0d33429fb389e534f9ed5d2545b57fc8e7ae9cc9; only the commit metadata changed.

This fresh suite is intended to determine whether the GPT, Opus, security-scope, internal-content, Build, and CI lanes now run without the prior GitHub App quota / runner-infrastructure failures. If GitHub requests approval for the fork workflows, please approve this run.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Sep 28, 2026
@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5, fork) — 🟡 CONCERNS

Design-level review of 40e8cf86c95a31927f9eebdc6f37cd69826f20c8 via the fork AI-review pipeline — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: CONCERNS

The renderer that every human forward and pasted table goes through was rebuilt into a lazy budget engine, a far larger change than this trusted-bot fix needs.

Watch

  • Shared-path rewrite beyond the stated goal. The description lists "Change top-level text, forwarded-message routing" under Not a goal. The diff still replaces the result[:_MAX_RECOVERED_TEXT_CHARS] slice in _extract_blocks_text with _BoundedBlockText, _until_full, _table_row_fragments, and a private _with_budget overload that returns a (str, int, bool) tuple. That renderer handles every human forward and pasted table → its behaviour now depends on how the lazy iterators interact (leading-whitespace skipping, separators opened by the first non-empty fragment, exhaustion flags) → a future fix to forward rendering has to reason about a budget protocol that only the trusted-bot path needs. Slack already limits event payload size, so traversing past 16k characters was never a real cost.
    Clears when: either _extract_trusted_bot_attachment_text renders each attachment with the existing renderer and slices against the remaining budget, with _extract_blocks_text gaining only include_section_fields; or the description names the harm that lazy traversal removes and lists the shared-path and _string_field hardening changes in its Backwards compatibility section.

Suggestions

  • Drop _with_budget and its overloads. For a fallback-or-blocks attachment, len(candidate) is enough to charge against the outer budget.

[DESIGN-REVIEWED] 40e8cf8

Description read

[DESCRIPTION-READ] 671395635a80a214d0298d1603b66f7cf33252fb68eeefdfc10689c4417c6f72

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5, fork) — 🟡 CONCERNS

Premise-level review of 40e8cf86c95a31927f9eebdc6f37cd69826f20c8 via the fork AI-review pipeline — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

First-Principles-Verdict: CONCERNS

The fix needs only a gated attachment loop. The lazy-budget rewrite of the shared Block Kit renderer has no named harm, and the old output slice already capped it.

Not justified as shipped

  • Item 3 — oversized: the description says "Each renderer invocation has a hard 16,000-character traversal and output cap". Base already capped output with return result[:_MAX_RECOVERED_TEXT_CHARS]. No linked defect shows that traversing an oversized Slack payload caused harm. The machinery is _BoundedBlockText, _until_full, _table_row_fragments, two @overloads and _with_budget. _with_budget=True and limit each have 1 caller, _extract_trusted_bot_attachment_text.
    Subtraction: delete the budgeted traversal and keep base _extract_blocks_text plus include_section_fields. In the trusted loop, slice each candidate to the remaining budget and the joined result to _MAX_RECOVERED_TEXT_CHARS.
    Clears when: the machinery is removed, or a reported defect or measured cost shows that unbounded traversal harms the gateway.

What this change ships

Inventory (6 items) — 4 justified

Intent: let alarm cards from trusted Slack bots that carry text only in attachments start a turn instead of vanishing. FIX (#13405).

  1. A trusted bot's ordinary attachment fallback or blocks are now routed as message text — justified
  2. section.fields text is recovered, for trusted ordinary cards only — justified
  3. The shared Block Kit renderer is rewritten as a lazy, budgeted traversal for the forwarded path too — oversized
  4. Non-string scalars in blocks, attachments and top-level text are ignored everywhere, the human path included — rides along
  5. A per-test fresh turn-ledger fixture replaces inline resets — justified
  6. Slack-gateway spec documents the recovery — justified

[FIRST-PRINCIPLES-REVIEWED] 40e8cf8

Description read

[DESCRIPTION-READ] 8a04f06b1e37b6edaaa57e0057275ab887cb868cf6a8ae2a636b2422a4c6c2b5

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review (fork) — ✅ no blocking findings

Reviewed 40e8cf86c95a31927f9eebdc6f37cd69826f20c8 via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] 40e8cf8

@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review (fork) — ✅ no blocking findings

Reviewed 40e8cf86c95a31927f9eebdc6f37cd69826f20c8 via the fork AI-review pipeline; updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 40e8cf8

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Sep 28, 2026
@Alexander-Yuan
Alexander-Yuan force-pushed the fix/slack-trusted-bot-attachment-fallback-13405 branch from 7b8d5dc to f88e148 Compare September 29, 2026 19:09
@Alexander-Yuan

Copy link
Copy Markdown
Contributor Author

Rebased: main advanced from 48b040c549c02602b502726b85a1f609c56e7144 to df0ea7909cafa0fa8762e844bf4babc98e282d46 with no overlap in this PR’s three files. git range-diff shows the feature patch is unchanged; all 58 local profile gates passed on f88e148eec382999d37cee7aca4e605a0bdadf3a, and CI is re-running.

@Alexander-Yuan

Copy link
Copy Markdown
Contributor Author

fixed
Exact SHA f88e148eec382999d37cee7aca4e605a0bdadf3a slices recovered fallback and Block Kit fragments before retention, counts formatting prefixes and separators in the same 16,000-character budget, and stops traversal when that budget is full.
Fault-seeded regressions fail against the prior unbounded path; the current head passes 288 directly affected tests and the 46,443-test backend related set.

@github-actions github-actions Bot added readiness: checking Automated validation is still running readiness: action required A blocking check or review needs attention and removed readiness: action required A blocking check or review needs attention readiness: checking Automated validation is still running labels Sep 29, 2026
@Alexander-Yuan
Alexander-Yuan force-pushed the fix/slack-trusted-bot-attachment-fallback-13405 branch from f88e148 to 35bfea6 Compare October 2, 2026 07:50
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention readiness: checking Automated validation is still running labels Oct 2, 2026
@iamwhatever
iamwhatever force-pushed the fix/slack-trusted-bot-attachment-fallback-13405 branch from d684a12 to 8785f5e Compare October 9, 2026 10:59
@iamwhatever

Copy link
Copy Markdown
Contributor

[operator: iamwhatever]

Rebased onto current main and pushed 8785f5e61.

GPT 6.1 blocking F1 (autouse fixture on shared monkeypatch): fixed. _fresh_trusted_bot_turn_ledger now requests _floor_monkeypatch. This also clears the Semgrep test-autouse-shared-monkeypatch finding, which flagged the same line.

GPT 6.1 advisory (renderer docstring claims a work bound): fixed in the same push. The docstring now says only that the recovered output never exceeds the cap.

First Principles CONCERNS (items 2-5) and Design suggestion (simpler budget): acknowledged, no code change in this PR. The size, scope and design trade-off is the author's and maintainers' call. Both lanes marked it advisory, and Opus 5.5 found nothing blocking. If a maintainer wants the smaller version (drop section.fields and the streaming budget, slice once at _MAX_RECOVERED_TEXT_CHARS), that can be a follow-up or a request on this PR.

Design: check a real AWS Chatbot payload: still open. No live alarm card has been sent; the tests use built Slack event shapes, as the PR body says.

@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 9, 2026
@iamwhatever

Copy link
Copy Markdown
Contributor

[operator: iamwhatever]

E2E (stub ACP backend, offline) failed on 8785f5e61 in one spec: playwright/member-memory.spec.ts:596 (V2 email memory edit). The failure is apiRequestContext.put: Timeout 10000ms exceeded, so the test's API call timed out rather than an assertion failing. This PR touches only src/kiro_crew/slack/events.py, its two Slack test files and the Slack gateway spec, so it cannot reach the memory UI or its API.

The E2E lane is also red on main now: CI run 37917922913 at 33b67aced failed one different spec (session-tags-e2e.spec.ts:740), with 324 passed. Every other check on this head is green. The failed E2E job has been re-run.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 9, 2026
@iamwhatever

Copy link
Copy Markdown
Contributor

This lets alarm cards from allowlisted Slack bots (AWS Chatbot, Amazon Q) whose text sits only in an ordinary attachment start a turn, instead of being dropped. The fix sits at the drop point in src/kiro_crew/slack/events.py. I tried to get past the trust check. The new _extract_trusted_bot_attachment_text runs only behind the existing from_trusted_bot decision, which this diff does not change, and only after the shared extraction returns nothing. Human messages, untrusted bots, is_share and is_msg_unfurl attachments all stay excluded, so I found no bypass. I am holding for three reasons. It widens what third-party-controlled content from trusted bots reaches the agent's prompt, which is security-adjacent. It rewrites the shared Block Kit renderer that forwarded and human messages also use (_BoundedBlockText, _until_full, the _string_field guards). And the current-head (8785f5e) First Principles CONCERNS is unanswered: it argues the streaming budget renderer and section.fields exceed the goal when base's slice cap already bounds the output. Please answer or apply those subtractions, then have a maintainer sign off on the trusted-bot input widening. Checks are green and base is main. — crew-pr-reviewer

iamwhatever
iamwhatever previously approved these changes Oct 9, 2026

@iamwhatever iamwhatever left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deep security re-review of a held PR (I tried to break it). Alarm cards from allowlisted bots (AWS Chatbot, Amazon Q) put their text only in an ordinary attachment. Base dropped them; this PR now routes them, using the attachment fallback first and its Block Kit text second. I tried to get past the trust check. The new _extract_trusted_bot_attachment_text runs only when from_trusted_bot is true, and trusted_bot_admission (unchanged) requires a positive bot_id match, never trusts our own id and fails closed when our own id is unknown. A human message, an untrusted bot, and is_share/is_msg_unfurl attachments (even with a string value like "false", which counts as true and is skipped) all stay out. Tests pin each case (test_human_attachment_fallback_stays_excluded, test_trusted_bot_shared_attachment_is_skipped_before_content). Link previews cannot reach the new path: the recovery runs only when text is empty or a Slack placeholder, and Slack adds unfurls later as message_changed, which the subtype gate drops first. Prompt injection: an alarm description written by anyone who can edit a CloudWatch alarm now reaches the agent unfenced, with the same authority an allowed user has. But base already passes a trusted bot's text field the same way, so this is the same trust class with more volume, not a new hole. The shared renderer rewrite keeps base output for forwards and human messages: no section.fields unless the caller asks, the same strip and the same 16,000 cap. 321 Slack tests pass locally on 8785f5e. Hold reason status: the security widening still needs an owner pick (below). The renderer rewrite is checked and safe. The First Principles CONCERNS got a plain-comment reply on 10-09 (left to the maintainer), not a target=first-principles disposition. It is advisory, and readiness is passed. No conflict, no CHANGES_REQUESTED, all checks green. Non-blocking: optional, smaller: apply the First Principles subtraction. Drop _BoundedBlockText/_until_full/the _with_budget overloads and include_section_fields in src/kiro_crew/slack/events.py, join per-attachment results and slice once at _MAX_RECOVERED_TEXT_CHARS. Also confirm the shape with a real AWS Chatbot payload, which is still unchecked. On the owner decision: Accept the widening. A bot on slack.trusted_bot_ids already gets full user-level turns from its text field. Treating its attachment-only card the same way is what the allowlist already promises, and the turn cap and review-channel denial still apply. Land before #11220, as the author proposed. Risk: medium. — crew-pr-reviewer

@iamwhatever
iamwhatever enabled auto-merge (squash) October 9, 2026 20:08
@github-actions github-actions Bot added the merge conflict Branch has merge conflicts with its base — author must resolve before merge label Oct 10, 2026
@iamwhatever
iamwhatever force-pushed the fix/slack-trusted-bot-attachment-fallback-13405 branch from 8785f5e to fb9f980 Compare October 11, 2026 06:08
auto-merge was automatically disabled October 11, 2026 06:08

Head branch was pushed to by a user without write access

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: passed Eligible automated validation passed for the current revision merge conflict Branch has merge conflicts with its base — author must resolve before merge labels Oct 11, 2026
@iamwhatever
iamwhatever force-pushed the fix/slack-trusted-bot-attachment-fallback-13405 branch from fb9f980 to 40e8cf8 Compare October 11, 2026 06:30
@github-actions github-actions Bot added readiness: checking Automated validation is still running and removed readiness: action required A blocking check or review needs attention labels Oct 11, 2026
@iamwhatever

Copy link
Copy Markdown
Contributor

Rebased onto main at head 40e8cf86c95a31927f9eebdc6f37cd69826f20c8. Main's #18786 added table blocks to _extract_blocks_text; this PR rewrote that function as a bounded renderer, so the two collided. The resolution keeps both: table rows now render inside the same budget (_table_row_fragments), and _route_message keeps the trusted-bot fallback and then appends table text as main does. All of main's table tests pass unchanged, plus two new ones (blank-row parity, budget cap).

Dispositions for the two CONCERNS on this head (advisory, no code change):

First Principles, item 3 (bounded traversal "no named harm") — rebutted, same answer as on 35bfea6f: join-then-slice still walks and allocates the whole untrusted payload before slicing. Measured on one 100,000-field payload: bounded render 0.79 ms / ~19 KB peak, join-then-slice 10.71 ms / ~10.9 MB, for the same 16,000-char output. The trusted-bot loop also needs the consumed/exhausted state to stop reading later attachments, which a plain slice cannot give.

Design Review, shared-path rewrite — the output contract of the shared path is unchanged: same lines, same \n join, same strip, same 16,000-char cap. Every pre-existing test in test/test_events_forward.py (forwards and tables) passes with no edits. The only visible difference is that an oversized payload stops being read once the cap is spent. _with_budget is private and used by one caller on purpose, to keep one renderer instead of two.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 11, 2026

@iamwhatever iamwhatever left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR fixes the root cause of #13405: alarm cards from allowlisted bots such as AWS Chatbot and Amazon Q were dropped when their text sat only in an ordinary attachment. They now start a turn. I read the whole src/kiro_crew/slack/events.py diff. I tried to get past the trust check. _extract_trusted_bot_attachment_text runs only when from_trusted_bot is already true and the shared-message path found nothing. is_share and is_msg_unfurl attachments are skipped, so human messages, untrusted bots and link unfurls cannot reach it. The recovered text goes into the same text variable that bot's top-level text uses today, so this adds no new class of untrusted input. For the shared renderer rewrite, I traced _BoundedBlockText and _table_row_fragments against base: leading-whitespace stripping, empty-line skipping, empty-cell " | " placement and the 16,000-character cap all give the same output. The one difference is a trailing-whitespace strip after the cap. Base is main, the head is mergeable and checks are green. The current-head Design and First Principles CONCERNS have written answers, backed by a measured cost of join-then-slice. The only review left is my own earlier, dismissed one, and the head has changed since my HOLD. — crew-pr-reviewer (deep re-check)

@iamwhatever
iamwhatever enabled auto-merge (squash) October 11, 2026 17:35

@bolichen97 bolichen97 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maintainer approval after a full diff read on head 40e8cf86c9.

Sensitive change review

  • Rule changed: _route_message (src/kiro_crew/slack/events.py ~L2595-2602). Before: text = _extract_shared_text(event) or fallback. After: same, plus if not text and from_trusted_bot: text = _extract_trusted_bot_attachment_text(event) before the or fallback. Net effect: trusted-bot attachment content that previously never reached the agent now does.
  • What makes a bot "trusted": from_trusted_bot is set only by trusted_bot_admission(bot_id, cfg.slack.trusted_bot_ids) in _on_event (main L1180) — positive match against the operator allowlist, own bot id never trusted, fail-closed when self id is unverified. The PR does not touch admission, the SEL audit, the review-channel denial, or the per-thread turn cap; recovery runs before those gates so they still apply to the recovered text. Default trusted_bot_ids=[] means the new path is unreachable out of the box.
  • Untrusted text still excluded: for from_trusted_bot=False the new branch is skipped, _extract_shared_text still only reads is_share/is_msg_unfurl attachments, and link-preview attachments on human messages remain dropped (test_human_attachment_fallback_stays_excluded). The trusted recovery itself skips is_share/is_msg_unfurl attachments so content the forwarded path declined cannot be reclassified.
  • Worst case if wrong: a listed trusted bot (e.g. AWS Chatbot) relaying attacker-influenced alarm text becomes agent input — but that bot's plain-text messages were already admitted as input, so the injection surface is the same principal, only more of its payload. Bounded by the 16,000-char global budget and the existing turn cap.
  • Evidence checked: full diff of all 4 files; main-branch _on_event/_route_message for where from_trusted_bot originates; renderer refactor compared line-by-line with the old join/strip semantics (list prefix, quote prefix, empty-line suppression, table " | " joining, leading/trailing strip) — equivalent for the forwarded path; existing test test_malformed_table_rows_are_skipped ("| ok") still holds under the new lazy row renderer. CI: all check runs success/skipped (two "neutral" advisory reviews).
  • Undo: revert the PR; no config/data migration.

@iamwhatever
iamwhatever merged commit 10350b7 into kirodotdev:main Oct 12, 2026
150 of 151 checks passed
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fork Pull request from a fork (external contributor)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

slack: trusted-bot messages with content only in attachments (AWS Chatbot alarm cards) are silently dropped

3 participants