Repository navigation
fix: detect new sessions in existing project dirs + scan local-agent-mode sessions - #180
Merged
vakovalskii merged 1 commit intoApr 17, 2026
Conversation
…mode sessions Two session discovery bugs fixed: 1. Cache invalidation: _sessionsNeedRescan() only checked PROJECTS_DIR top-level mtime, so new sessions added to existing project subdirs were invisible until history.jsonl changed or server restarted. Now also tracks each subdir mtime. 2. Claude desktop local-agent-mode: sessions stored in ~/Library/Application Support/Claude/local-agent-mode-sessions/ were never scanned. Added detectLocalAgentModeClaudeDirs() (macOS only) to find embedded .claude dirs and include them in EXTRA_CLAUDE_DIRS.
vakovalskii
added a commit
that referenced
this pull request
Apr 17, 2026
…lytics tabs Merged PRs: - #182 (@rrr3try): Show Claude Code recap (away_summary) as session title - #181 (@NovakPAai): Block bulk delete for filter-hidden sessions - #180 (@NovakPAai): Detect new sessions in existing dirs + local-agent-mode - #179 (@NovakPAai): Message sort toggle in session drawer + default setting - #86 (@NovakPAai): Sub-tabs in Cost Analytics (Overview/Breakdown/History) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
vakovalskii
added a commit
that referenced
this pull request
Apr 17, 2026
…lytics tabs (#183) Merged PRs: - #182 (@rrr3try): Show Claude Code recap (away_summary) as session title - #181 (@NovakPAai): Block bulk delete for filter-hidden sessions - #180 (@NovakPAai): Detect new sessions in existing dirs + local-agent-mode - #179 (@NovakPAai): Message sort toggle in session drawer + default setting - #86 (@NovakPAai): Sub-tabs in Cost Analytics (Overview/Breakdown/History) Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Summary
Two session discovery bugs that cause sessions to be invisible in the dashboard:
Bug 1: Cache never invalidates for new sessions in existing projects
_sessionsNeedRescan()only tracked the top-level~/.claude/projects/mtime. When a new session starts in an already existing project directory, only the subdirectory mtime changes — not the parent. This caused the cache to extend indefinitely, hiding new sessions untilhistory.jsonlchanged or the server restarted.Fix: also track mtime of each project subdirectory in
_projectsSubDirMtimes.Bug 2: Claude desktop local-agent-mode sessions not scanned
Sessions started via Claude desktop app's local agent mode are stored in:
This directory was never scanned — all those sessions were invisible.
Fix: added
detectLocalAgentModeClaudeDirs()(macOS only) that walks the local-agent-mode-sessions tree and collects embedded.claudedirs intoEXTRA_CLAUDE_DIRS.Test plan
~/Library/Application Support/Claude/local-agent-mode-sessions/for session files → verify they appear in dashboard