FN-5839: prevent stale integration-advance sync prompts
Treat rewritten integration-branch advances as handled when the working tree is already aligned. - Add a new `superseded` resolution for unreachable advance SHAs that remain after history rewrites while HEAD matches the local integration tip. - Update Git status collection logic and route/API status typings to propagate the new resolution state. - Update Git Manager modal messaging and dismiss behavior so handled `superseded` entries do not show a sync CTA. - Extend dashboard route and modal tests, and refresh dashboard guide docs for the new classification behavior. Files changed: docs/dashboard-guide.md | 5 +-- packages/dashboard/app/api/legacy.ts | 2 +- .../dashboard/app/components/GitManagerModal.tsx | 6 ++-- .../components/__tests__/GitManagerModal.test.tsx | 5 ++- .../dashboard/src/__tests__/routes-git.test.ts | 36 ++++++++++++++++++++-- .../dashboard/src/routes/register-git-github.ts | 13 ++++++-- 6 files changed, 55 insertions(+), 12 deletions(-) Fusion-Task-Id: FN-5839 Fusion-Task-Lineage: 6b4afb73-587d-4319-8ad8-f1d5d54bc7bf
This commit is contained in:
@@ -261,12 +261,13 @@ How to react:
|
||||
- Click **Pull** to run Smart Pull (`POST /api/git/smart-pull`), including the stash-conflict flow in `StashConflictModal` when needed
|
||||
- Use the dismiss close button to hide the notice
|
||||
- Treat dirty/untracked warnings as a hint that local changes may be auto-stashed during pull
|
||||
- In Git Manager's "Recent integration-branch advances" panel, entries are classified as `pending`, `reachable`, `subsumed`, or `orphaned`:
|
||||
- In Git Manager's "Recent integration-branch advances" panel, entries are classified as `pending`, `reachable`, `subsumed`, `orphaned`, or `superseded`:
|
||||
- `pending`: actionable (not reflected in HEAD; Sync can help)
|
||||
- `reachable`: commit already reachable from HEAD
|
||||
- `subsumed`: equivalent patch content already landed under a different SHA (history rewrite/re-squash)
|
||||
- `orphaned`: recorded SHA no longer exists locally after history rewrite
|
||||
- **Sync working tree** is shown only when there is at least one `pending` entry and HEAD is not already aligned with the integration tip; handled entries can be dismissed from the panel.
|
||||
- `superseded`: recorded SHA still exists but is unreachable, and HEAD is already aligned with the local integration tip after a history rewrite (handled; no sync action applies)
|
||||
- **Sync working tree** is shown only when there is at least one `pending` entry and HEAD is not already aligned with the integration tip; handled entries (`reachable`/`subsumed`/`orphaned`/`superseded`) can be dismissed from the panel.
|
||||
|
||||
Push follow-up (when shown):
|
||||
- If the integration branch is ahead of `origin`, the banner can show push controls with ahead count
|
||||
|
||||
Reference in New Issue
Block a user