Skip to content

fix(chat): count automated turns per conversation only - #1765

Merged
dcramer merged 2 commits into
mainfrom
fix/automated-turn-limit-conversation-scope
Sep 2, 2026
Merged

dcramer merged 2 commits into
mainfrom
fix/automated-turn-limit-conversation-scope

Conversation

@sentry-junior

@sentry-junior sentry-junior Bot commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

The 10 automated-turn pause was counting every event task in a Slack channel together. That paused always-on bots after ~10 fires anywhere in the channel.

Change

  • count and pause only on the Conversation
  • remove the destination/channel counter
  • stop pre-checking event-task ingest against that channel budget
  • pause notice always says “in this thread”

Resource watches still pause after 10 automated turns in the same conversation with no user message. Separate event-task fires no longer share one channel budget.

Requested by David Cramer.

--

View Junior Session [Sentry]

Event tasks were sharing one channel-wide destination counter, so always-on
triage bots paused after 10 fires across unrelated jobs. Count and gate only
on the Conversation, including each event-task dispatch conversation.

Co-Authored-By: David Cramer <[email protected]>
@vercel

vercel Bot commented Sep 2, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
junior-docs Ready Ready Preview Sep 2, 2026 7:53pm UTC

Request Review

@github-actions

github-actions Bot commented Sep 2, 2026 •

Copy link
Copy Markdown
Contributor

1 screenshot change — 1 changed · 0 added · 0 removed

Review screenshots in Frameshift

Locations · Desktop
Locations · Desktop
Changed

Drop the destination-wide consecutive-turn counter. Count and pause only on
the Conversation. Event-task fires no longer share one channel budget.

Co-Authored-By: David Cramer <[email protected]>
@sentry-junior sentry-junior Bot changed the title fix(chat): scope automated-turn limit to conversations fix(chat): count automated turns per conversation only Sep 2, 2026
@dcramer
dcramer marked this pull request as ready for review September 2, 2026 19:52
@github-actions github-actions Bot added the risk: medium PR risk score: medium label Sep 2, 2026
@dcramer
dcramer merged commit d4ca884 into main Sep 2, 2026
41 checks passed
@dcramer
dcramer deleted the fix/automated-turn-limit-conversation-scope branch September 2, 2026 20:13
dcramer added a commit that referenced this pull request Oct 2, 2026
The chat runtime and event-automations READMEs said event-automation
dispatches count toward the consecutive automated-turn limit on their
Destination. That counter was removed on purpose in #1765. A shared
channel budget paused unrelated always-on automations after about 10
fires. Each dispatch now runs in its own Conversation, so the limit
applies only to Watches. Both READMEs now say this. Code is unchanged.

The self-trigger risk from the issue still exists: nothing stops an
event automation whose own work causes another matching event. A fix for
that should be scoped to one automation, not a Destination, and is left
for a follow-up.

Fixes #2002

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 <[email protected]>

This branch was successfully deployed

1 active deployment
Preview – junior-docs — f0ffc10b Deployed Sep 2, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: medium PR risk score: medium

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant