fix: prevent false cwd split that hides all sessions#40
Merged
matt1398 merged 1 commit intomatt1398:mainfrom Feb 21, 2026
Merged
fix: prevent false cwd split that hides all sessions#40matt1398 merged 1 commit intomatt1398:mainfrom
matt1398 merged 1 commit intomatt1398:mainfrom
Conversation
Sessions without the cwd field (older JSONL format) were creating a separate subproject group, even when all sessions with cwd shared the same value. The orphan subproject got a relative fallback path that failed git identity resolution, causing zero sessions to load on select. Now only counts distinct real cwds when deciding whether to split, treating cwd-less sessions as belonging to the same project.
Owner
|
LGTM! Thanks for the clean fix and the test cases. |
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
cwdfield in JSONL) would show 0 sessions when selected in the dashboardscanProjectwas splitting sessions into subprojects whenevercwdGroups.size > 1, but sessions withoutcwdcreated a separate__decoded__group even when all sessions withcwdshared the same value"my-project") that failed git identity resolution, causing it to land in a separate repository group with broken session loadingTesting
npm run typecheckpassesnpm testpassestest/main/services/discovery/ProjectScanner.cwdSplit.test.tscovering: