Repository navigation
Conversation
… re-snoozes it on Resume at reset Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ApprovabilityVerdict: Approved at Macroscope's review found this PR approvable — Waking or pinning a thread now clears its stale recovery snooze flag, preventing a later Resume at reset action from hiding it again. The change is limited to explicit thread actions and preserves existing auto-resume settings. You can add or adjust custom eligibility rules. Learn more. |
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Clear recovery snooze on wake and pin apps/server/src/orchestration-v2/Orchestrator.ts, apps/server/src/orchestration-v2/runtimeLayer.test.ts |
Unsnooze and pin clear the snooze flag in existing limit-recovery settings. Tests verify that enabling auto-resume without a snooze value leaves the thread unsnoozed. |
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix
Possibly related issues
pingdotgg/t3code#18731— Reports incorrect thread state after a resume sequence. This change clears stale limit-recovery snooze state when the thread is unsnoozed or pinned; the reported sidebar placement issue is separate.
Suggested reviewers: juliusmarminge, t3dotgg
Merge Risk: 
Minimal · up to 2e12b
-
Waking or pinning clears the recovery snooze flag, preventing Resume at reset from re-snoozing the thread. No material merge risk was identified.
Pre-merge checks: 
4
-
Full details: Description check
-
Explanation
The description includes all required sections. It explains the problem, the change, scope and approval rationale, focused verification results, failed-before and passed-after behavior, and the unverified live-client check.
-
Finishing Touches
-
Generate unit tests (beta)
-
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Problem
A thread stops on a usage limit and you press Snooze until reset. Later you wake it from the sidebar, the thread menu, or the mobile thread list, or you Pin it. Then you press Resume at reset on the banner. The thread disappears back into Snoozed, though all you asked for was auto-resume. After a Pin, the thread ends up pinned and snoozed at the same time.
The cause:
thread.unsnoozeandthread.pinclearsnoozedUntilbut leavelimitRecovery.snoozeset totrue. "Resume at reset" sends{ runId, resetAt, autoResume: true }with nosnoozefield. Thethread.metadata.updatedecider fills the missing field from the stale flag, so it snoozes the thread toresetAtagain.Change
thread.unsnoozeandthread.pinnow clearlimitRecovery.snooze, the same waythread.snoozealready does (limitRecovery: thread.limitRecovery ? { ...thread.limitRecovery, snooze: false } : null). Once something other than limit recovery wakes the thread, recovery no longer owns a snooze. This matches therecoveryOwnsSnoozecheck the web and mobile clients already use.thread.settleis left alone, because #28360 changes that case.Scope and approval
This is a very small, focused fix for an obvious bug, so there is no prior issue. You ask for auto-resume and the server hides the thread instead, and Pin produces a pinned-and-snoozed state that the pin decider otherwise rules out. The fix is two lines, copied from the sibling
thread.snoozecase, plus two rows in an existing test table.Overlap search: #28360 (open) touches only
thread.settle. #22775 (open) covers empty wake runs and projection queries. #28359 (open) covers auto-settle in ThreadSettlementService and ProjectionStore. None of them change thethread.unsnoozeorthread.pindeciders. GitHub searches for "unsnooze limitRecovery" and "snooze limit recovery wake pin" found no other matches (only the original feature, #12687).Verification
wake-then-resumeandpin-then-resumerows toruntimeLayer.test.ts› "usage-limit recovery" › "guards a scheduled usage-limit continuation against %s". Each row snoozes until reset, wakes or pins, presses Resume at reset, and asserts the thread stays awake.main: both rows fail withAssertionError: expected DateTime.Utc(1970-01-01T00:01:00.000Z) to equal null, meaningsnoozedUntilcomes back asresetAt.vp test runonruntimeLayer.test.ts,UsageLimitRecoveryWorker.test.ts,ThreadSettlementService.test.ts, andProjectionStore.test.tspassed 193 of 193 tests in 4 files. This includes the existingindependent-patchesrow, which shows thatsnoozeis still kept while recovery really owns the snooze.vp run check:changed: format, lint, knip, graphql, typecheck (3 packages), and tests all pass.Reviewed with sol-loop: 1 round with GPT-6.1 Sol on high. Sol verdict: approved.
Created with Claude Opus 5.5 in Claude Code (T3 Code).
🤖 Generated with Claude Code