You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(claude): mark a follow-up cancelled by the dead-login Stop as not run (STA-18495) - #49349
When Claude's login is dead or denied, Orca stops Claude's retry loop automatically. That Stop cancels the whole queue, including a follow-up sent during the retries, but it skipped the settlement callback the manual Stop passes. The cancelled follow-up then stayed "sending" until the chat was reopened.
The automatic Stop now passes the same onDispatchSettledLate callback as the manual Stop, so the cancelled follow-up is marked not run right away.
Test
claude-structured-event-delivery.test.ts: a 401 retry at attempt 3 with a queued follow-up settles the follow-up as rejected and not run. Fails without the fix.
Performance
No change. One extra callback, called only for follow-ups the dead-login Stop cancels.
No actionable comments were generated in the recent review.
Walkthrough
Auth-retry cancellation now receives the session ID and event-delivery dependencies. It forwards late dispatch settlements to the optional onDispatchSettledLate callback. A test checks that a 401 api_retry event resolves the replay promise to null, requests cancellation, reports the follow-up as rejected and unrun, and clears the dispatch-waiter list.
Merge Risk: Minimal · up to 39dee
This change marks a follow-up as not run when Claude's automatic Stop cancels the queue after a dead login, so it no longer stays in a sending state. No actionable merge risk was identified.
Pre-merge checks: 3 · 1
Failed checks: 1 inconclusive
Check name
Status
Explanation
Resolution
Description check
The description follows the template's core intent. It explains what changed and why, gives a test note stating that the test fails without the fix, and includes a Performance statement. It links the …
Add an ELI5 section in plain language. Add a Risk section that gives a Level (Low, Medium, or High), names the riskiest part, and describes how to revert. Add a Visual Proof section that states N/A with a reason, since this is a behavior ch…
Passed checks: 3 passed
Check name
Status
Explanation
Title check
The title names the main change: a follow-up cancelled by the dead-login automatic Stop is now marked as not run. The raw summary confirms the change passes the same late-settlement callback used by t…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Title check
Explanation
The title names the main change: a follow-up cancelled by the dead-login automatic Stop is now marked as not run. The raw summary confirms the change passes the same late-settlement callback used by the manual Stop, and the title's scope matches that change. The title is 85 characters, which is slightly long but still specific and readable.
Full details: Description check
Explanation
The description follows the template's core intent. It explains what changed and why, gives a test note stating that the test fails without the fix, and includes a Performance statement. It links the issue (STA-18495) only as 'Fixes STA-18495' and omits the template's 'Fixes #' issue link format. It has no ELI5 section, no Visual Proof section (or an N/A reason), no Risk level, and no Testing checklist ticks. Several template sections are missing, but the core technical content is present.
Resolution
Add an ELI5 section in plain language. Add a Risk section that gives a Level (Low, Medium, or High), names the riskiest part, and describes how to revert. Add a Visual Proof section that states N/A with a reason, since this is a behavior change in the retry path. Use the template's 'Fixes #' issue link format, or confirm the STA-18495 reference is the linked issue. Mark the Testing checklist items that apply, and state which platforms were tested.
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.
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
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.
Fixes STA-18495.
When Claude's login is dead or denied, Orca stops Claude's retry loop automatically. That Stop cancels the whole queue, including a follow-up sent during the retries, but it skipped the settlement callback the manual Stop passes. The cancelled follow-up then stayed "sending" until the chat was reopened.
The automatic Stop now passes the same
onDispatchSettledLatecallback as the manual Stop, so the cancelled follow-up is marked not run right away.Test
claude-structured-event-delivery.test.ts: a 401 retry at attempt 3 with a queued follow-up settles the follow-up as rejected and not run. Fails without the fix.Performance
No change. One extra callback, called only for follow-ups the dead-login Stop cancels.