Repository navigation
Keep repository indicators in sync with loaded status - #23089
Merged
Merged
Conversation
Update the repository indicator whenever status is loaded, including Changes-tab refreshes, and publish removal when status is unavailable. Co-authored-by: Copilot App <[email protected]> Copilot-Session: c1803488-50c0-4ac9-870a-be2b126f0664
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues were identified for the repository indicator synchronization changes.
No open issues 🎉
What changed in this PR
Addresses #22997 by keeping repository picker indicators synchronized with status loaded for the Changes tab, without changing background refresh timing for other repositories.
Changes:
- Updates indicators inside
_loadStatus()before publishing state, and clears cached indicators when status is unavailable. - Removes the redundant refresh-path update and makes the indicator helper synchronous.
- Adds regression coverage for dirty/clean transitions, ahead/behind values, and unavailable status.
| File | Description |
|---|---|
app/test/unit/stores/app-store-indicators-test.ts |
Tests indicator synchronization through section changes and unavailable-status handling. |
app/src/lib/stores/app-store.ts |
Centralizes indicator updates in status loading and publishes cleared indicators. |
Review effort: Balanced
sergiou87
approved these changes
Oct 30, 2026
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.
Closes #22997
Description
_loadStatus()loads status, before publishing application state. Previously, a History → Changes refresh could display modified files while the repository picker still showed no uncommitted-changes dot._refreshRepository(), and make the synchronous indicator helper explicitly synchronous.Screenshots
Both captures follow the same Playwright scenario: start with a clean repository, select History, modify a tracked file externally without changing window focus, switch to Changes, verify Desktop displays the added line, and open the repository picker.
Validation
Validation and after-artifacts cover the code committed as
db2e01cd66ddd3dac94d4cd902314aa6835b0bde; the baseline captures use unchanged production code. The temporary Playwright spec was removed after capture and is not included in this PR.yarn test app/test/unit/stores/app-store-indicators-test.ts app/test/unit/ui/repository-list-item-test.tsx— passed, 9 tests. Both new behavioral regressions were observed failing before the fix.yarn test:e2e:build:unpackaged— passed for baseline and fixed builds, with existing SDK/bundler warnings.INDICATOR_PHASE=before DESKTOP_E2E_APP_MODE=unpackaged npx playwright test --config app/test/e2e/playwright.config.ts app/test/e2e/issue-22997.e2e.ts— passed; confirmed Desktop recognized the changed file while the visible repository row lacked its dot.INDICATOR_PHASE=after DESKTOP_E2E_APP_MODE=unpackaged npx playwright test --config app/test/e2e/playwright.config.ts app/test/e2e/issue-22997.e2e.ts— passed; confirmed the dot appears for the recognized change and clears after restoring the file and reloading Changes.yarn lint:fixandyarn lint— passed.yarn tsc --noEmit -p tsconfig.json— passed.yarn test— 2,282 passed, 6 failed, 2 skipped. The same six failures were reproduced with production files unchanged usingyarn test app/test/unit/git/checkout-test.ts app/test/unit/git/push-test.ts app/test/unit/git/rev-parse-test.ts app/test/unit/parse-files-to-be-overwritten-test.ts: uninitialized-submodule checkout, three local-remote push tests, initialized bare-repository detection, and parsing files from a pull error.Team-authored review
Evidence: See Screenshots and Validation.
Review path: Lightweight review. This synchronizes existing status-display state; it does not change authentication, permissions, destructive Git operations, or release infrastructure.
Release notes
Notes: [Fixed] Keep the repository list's uncommitted-changes indicator in sync when refreshing the Changes tab.