Repository navigation
#783 Show the worktree checkout on the first Session Chat frame - #784
Merged
Merged
Conversation
Session Chat seeded its top bar with the folder name and project letter and only learned the session was a worktree checkout after its own inventory fetch (added paths, current project, worktree list and v2 refresh), so the subtitle switched from the letter to the worktree mark a moment after every open. Home now records its added paths and the worktree inventory each one loaded in a shared WorktreeInventoryCache. Session Chat resolves its identity from that cache synchronously when it is created, with the same badge predicate, and keeps the fetch as a refresh: an agreeing answer changes nothing, and a failed or unloaded inventory falls back to the last known one. Session Chat records what it loads too, so a later open is immediate even without Home. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…droid Same cause as on iOS: bind seeded the folder name and project letter, and the worktree mark replaced it only after Session Chat's own inventory fetch, about a second later on the emulator. Home records its added paths and each worktree inventory in a singleton WorktreeInventoryCache; Session Chat resolves its identity from it at bind and keeps the fetch as a refresh that falls back to the last known inventory when a load fails. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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
WorktreeInventoryCacheon iOS and Android: Home writes its added paths and worktree inventories into it, and Session Chat reads it synchronously when it opens, so the first frame is already final. The server fetch still runs as a refresh and only republishes when its answer differs. A failed refresh keeps the cached identity.SessionChatProjectIdentitytype on each platform. iOS no longer resets the identity to the letter when observation restarts.Checks
./gradlew :app:testDebugUnitTest :app:assembleDebugpassed, 2479 tests (1 skipped).ProjectionReconciliationTests.worldAndReconnectPair_yieldsOneGet. That suite is unrelated to this change and passed 8/8 when re-run alone.Issue
Risks / Follow-ups
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmithwith what you need.