Dashboard › cli › idle.ts eviction: upstream uses per-fun…
019e6b25-30e4-73e9-b734-780aa7612053| Project | Hits | Last recalled |
|---|---|---|
| opencode-lore | 1 | 12d ago |
Upstream (main branch) puts session eviction logic directly in idle.ts rather than a centralized evictSession() in pipeline.ts. idle.ts imports cleanup functions individually: evictSession as evictGradientSession from @loreai/core; also deleteSessionAuth, clearAuthStale from ./auth; deleteSessionCosts from ./cost-tracker; deleteBillingPrefix from ./cch; clearWarmupAuthDisabled from ./cache-warmer. The startIdleScheduler signature uses onEvict?: (sessionID: string) => void (upstream) vs onEvictSession?: (sessionID: string) => boolean (branch). Upstream inline onEvict in pipeline.ts cleans 5 Maps: headerSessionIndex, ltmSessionCache, ltmPinnedText, stableLtmCache, cwdWarned. When merging, adopt upstream's per-function approach and add any missing cleanup calls.