Repository navigation
fix(core): Steer a thread's !! reply into the running Turn - #5179
Open
sentry-junior[bot] wants to merge 3 commits into
Open
sentry-junior[bot] wants to merge 3 commits into
sentry-junior[bot] wants to merge 3 commits into
Conversation
Core held every thread message with no mention for the decision after the Turn, `!!` too, and the decision could skip it. Main marks a `!!` reply as interrupt input, and its running Turn takes it at its next step, or yields to it when another person sent it. While a Turn runs, core now appends the reply as interrupt input with main's processing reaction, and placement joins it or supersedes the running Turn.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
|
Found 4 test failures on Blacksmith runners: Failures
|
…k.ts slack-webhook.ts passed 1,000 lines after main merged in.
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-v2-3x.png)
With passive routing, core held every thread message with no mention for the reply decision after the Turn (
slack-webhook.ts), a!!reply too, and the decision could skip it. On main,buildSlackInboundMessagemarks a!!reply as interrupt input:!!: the running Turn's steering drain takes it at the next step, with the processing reaction.!!: the running Turn yields at its next boundary. The next Run supersedes it (supersedeTurnForInput), so it ends with no reply, and that Run decides the!!reply with the passive decision. A reply Turn answers both messages, because the first one is still unanswered in history.What changes: while a started Turn runs (not waiting), core appends a
!!thread reply as interrupt input instead of holding it. It also adds main's processing reaction and a Slack receipt (slackReceipt, now passed throughappendAndEnqueueInboundMessage). Placement then joins the author's own running Turn, or supersedes another person's. With no running Turn, the reply is held for the decision as before, as on main.Remaining difference: when another person sends
!!, core runs the new Turn with no passive decision. Where main's decision would skip that reply, main answers neither message, and core answers both. Matching that would take a way to supersede a Turn without placing an input.The
turn-lifecycle:slack-bang-bang-overriderow note describes both paths. Once #5169 is on main, a later merge of main into this branch drops that PR'sknown-core-gapmark on the row.via @thomasjiangcy.
--
View Session [Sentry]