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
Handoff: let idle compaction run when the handoff's model instance cannot run; fix the 'not remembered' test #608
Follow-up from the review of #605 (#605 (comment)). #605 corrected the docs; this is the code side and one test gap.
Let idle compaction run when the handoff cannot run (major in the review, came with fork(handoff): one owner per thread; project-off tests (#361) #583). When the handoff's modelSelection names a provider instance that was removed, the send fails before any run (ProviderAdapterRegistryLookupError), so there is no retry and nothing shows in the thread. Idle compaction is skipped for that thread for good, with only server-log lines. Fix: the compaction wrapper (handoffOwner.ts) treats a thread as handoff-owned only if the handoff can run: check settings.modelSelection?.instanceId (when set) with upstream's own resolveProjectProviderInstanceEnabled and a registry lookup. HandoffService uses the same rule (one source), so the two never disagree. Also trace the "turned off but still registered" case. Update docs/fork/handoff.md ("A handoff that cannot run") to match.
The "is not remembered" test cannot fail (handoffOwner.test.ts:281). Each compaction(...) call builds a fresh HandoffOwner.make, so a result remembered inside one wrapper would not show (the reviewer's mutant D: a Set of missing thread ids inside make keeps all 102 tests green). Build the wrapper once and report the run twice, clearing threadMissing between the two reports.
State question for the fix: runs again, settings changed half-way, instance removed and then added back, old settings with no modelSelection.
Activity
Handoff retry: also check the run's own instance (#608)
Handoff: let idle compaction run when the handoff's instance cannot r…
Handoff: let idle compaction run when the handoff's instance cannot r…