Repository navigation
Improve workspace cleanup list - #7053
Conversation
|
Ready to review this PR? Stage has broken it down into 6 individual chapters for you: Chapters generated by Stage for commit dbccaf4 on Jul 2, 2026 1:18am UTC. |
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThis PR adds a main-process resolver that recalculates worktree activity timestamps from persisted values and local filesystem mtimes, then uses it during workspace scanning. On the renderer side, the workspace cleanup flow now uses extracted candidate-row, background-removal, dialog, and deletion-state modules, with expanded row support and progress-driven deletion UI. New Vitest tests cover the activity resolver, row-data helpers, background removal flow, scan coordination, and queued-deletion state. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (5)
src/main/ipc/workspace-cleanup-activity.ts (1)
24-37: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueRedundant
?? 0afterNumber.isFiniteguard.
Number.isFinite(worktree.createdAt) ? (worktree.createdAt ?? 0) : 0— ifNumber.isFinitereturnstrue,worktree.createdAtis guaranteed non-nullish, making the?? 0unreachable. Not a bug, just slightly confusing.src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts (3)
37-101: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winDocument the status-precedence rationale.
getCandidateStatusencodes a non-obvious priority order (dismissed > ready-tier/archived > first blocker > unpushed-ahead > dirty > review-tier > fallback). A short comment explaining why this ordering was chosen (e.g., why blockers are checked before ahead/dirty state) would help future maintainers avoid breaking the precedence when adding new tiers/blockers.As per coding guidelines, "When writing or modifying code driven by a design doc or non-obvious constraint, add a comment explaining why the code behaves the way it does."
Source: Coding guidelines
103-130: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winHardcoded English strings inconsistent with translate() usage in this file.
formatGitStatus,formatBranchSafetyDetails,formatContextDetails, andgetDirtyGitLabelreturn raw English strings ('Clean git','Uncommitted changes','unpushed commit(s)', etc.) whilegetCandidateStatusin the same file routes every label throughtranslate(). These strings feed the same tooltip/chip UI (seeworkspace-cleanup-candidate-row.tsxLines 158-186, 164-206), so non-English locales will show a mix of translated and untranslated text.Also applies to: 172-199
172-199: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winDuplicate "unpushed commit(s)" formatting.
The pluralized count string is built twice with identical logic (Lines 180-184 and 187-190). Extract a small helper (e.g.
formatUnpushedCommitsLabel(count)) to avoid divergence if the format changes later.♻️ Suggested extraction
+function formatUnpushedCommitsLabel(count: number): string { + return `${count} unpushed commit${count === 1 ? '' : 's'}` +} + export function getDirtyGitLabel(candidate: WorkspaceCleanupCandidate): string | null { if ( candidate.blockers.includes('unknown-base') || candidate.blockers.includes('git-status-error') ) { return null } if (candidate.blockers.includes('unpushed-commits')) { if (candidate.git.upstreamAhead && candidate.git.upstreamAhead > 0) { - return `${candidate.git.upstreamAhead} unpushed commit${ - candidate.git.upstreamAhead === 1 ? '' : 's' - }` + return formatUnpushedCommitsLabel(candidate.git.upstreamAhead) } return 'Unpushed commits' } if (candidate.git.upstreamAhead && candidate.git.upstreamAhead > 0) { - return `${candidate.git.upstreamAhead} unpushed commit${ - candidate.git.upstreamAhead === 1 ? '' : 's' - }` + return formatUnpushedCommitsLabel(candidate.git.upstreamAhead) }src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts (1)
1-38: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAdd coverage for
getCandidateStatusand the remaining formatter helpers.Only
getDirtyGitLabel/shouldShowGitMetadataChipare tested.getCandidateStatushas the most complex branching in the module (dismissed/ready/blockers/ahead/dirty/review/fallback) and has no tests here.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 8103df78-ec6b-454d-aeb5-d2c0bf4906b2
📥 Commits
Reviewing files that changed from the base of the PR and between 126aae7 and 7a214520798fece45933cf913f0d5cbe6ea3e86d.
📒 Files selected for processing (11)
src/main/ipc/workspace-cleanup-activity.test.tssrc/main/ipc/workspace-cleanup-activity.tssrc/main/ipc/workspace-cleanup-scan.tssrc/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
7a21452 to
0ee1a85
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: ca2ef018-d77d-4fe5-a391-6695cfa70bac
📥 Commits
Reviewing files that changed from the base of the PR and between 7a214520798fece45933cf913f0d5cbe6ea3e86d and 0ee1a8589ebe9793c153e985994b6ee720e59b4c.
📒 Files selected for processing (11)
src/main/ipc/workspace-cleanup-activity.test.tssrc/main/ipc/workspace-cleanup-activity.tssrc/main/ipc/workspace-cleanup-scan.tssrc/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
🚧 Files skipped from review as they are similar to previous changes (9)
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsx
- src/main/ipc/workspace-cleanup-activity.test.ts
- src/main/ipc/workspace-cleanup-activity.ts
- src/main/ipc/workspace-cleanup-scan.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts
- src/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsx
0ee1a85 to
490d2b8
Compare
There was a problem hiding this comment.
🧹 Nitpick comments (2)
src/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsx (2)
216-216: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winDocument why in-flight removal skips dialog resets.
This ref guards multiple reset effects while deletion continues in the background; add a short
Why:comment near the ref or first guard so future edits don’t accidentally clear progress/confirmation state. As per coding guidelines, “When writing or modifying code driven by a design doc or non-obvious constraint, add a comment explaining why the code behaves the way it does.”Suggested comment
- const removalInFlightRef = useRef(false) + // Why: removal can continue after the modal closes/reopens, so reset effects + // must not clear confirmation/progress state until callbacks finish. + const removalInFlightRef = useRef(false)Also applies to: 286-295, 340-342
Source: Coding guidelines
1163-1191: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick winKeep pluralized UI strings inside
translate.The new titles/buttons/progress text build English
workspace/workspacesoutside translation, so non-English locales can’t control plural grammar or word order. Prefer singular/plural translated fallbacks or a whole-sentence translation with count interpolation.Also applies to: 1258-1277, 1407-1414
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 41ab5311-c5a0-4feb-915f-a75e49bdf3d2
📥 Commits
Reviewing files that changed from the base of the PR and between 0ee1a8589ebe9793c153e985994b6ee720e59b4c and 490d2b8.
📒 Files selected for processing (11)
src/main/ipc/workspace-cleanup-activity.test.tssrc/main/ipc/workspace-cleanup-activity.tssrc/main/ipc/workspace-cleanup-scan.tssrc/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
🚧 Files skipped from review as they are similar to previous changes (10)
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
- src/main/ipc/workspace-cleanup-scan.ts
- src/main/ipc/workspace-cleanup-activity.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts
- src/main/ipc/workspace-cleanup-activity.test.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts
490d2b8 to
dbccaf4
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: 17289e4d-401e-4601-ab63-a6b85896d8ac
📒 Files selected for processing (15)
src/main/ipc/workspace-cleanup-activity.test.tssrc/main/ipc/workspace-cleanup-activity.tssrc/main/ipc/workspace-cleanup-scan.tssrc/renderer/src/components/sidebar/WorktreeCard.tsxsrc/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsxsrc/renderer/src/store/slices/store-cascades.test.tssrc/renderer/src/store/slices/worktree-helpers.tssrc/renderer/src/store/slices/worktrees.ts
✅ Files skipped from review due to trivial changes (2)
- src/renderer/src/components/sidebar/WorktreeCard.tsx
- src/renderer/src/store/slices/store-cascades.test.ts
🚧 Files skipped from review as they are similar to previous changes (10)
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts
- src/main/ipc/workspace-cleanup-activity.test.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-details.tsx
- src/main/ipc/workspace-cleanup-scan.ts
- src/main/ipc/workspace-cleanup-activity.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts
- src/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsx
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsx (1)
550-562: 📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick winAdd a "why" comment for the queued-phase clear logic.
The condition
deleteState?.isDeleting && deleteState.error === null && deleteState.phase === 'queued'is subtle — it specifically targets candidates whose store delete-state was set toqueuedbymarkWorktreesQueuedForDeletionbut never progressed (e.g. skipped because an ancestor failed, perstartWorkspaceCleanupBackgroundRemoval's ancestor-skip path), so they'd otherwise be stuck showing the sidebar's "Queued for deletion" overlay forever. Without a short comment, this looks like dead/defensive code a future refactor could easily strip out.📝 Suggested comment
for (const failure of result.failures) { nextFailures[failure.worktreeId] = failure.message const deleteState = useAppStore.getState().deleteStateByWorktreeId[failure.worktreeId] + // Why: candidates skipped because a nested workspace failed (or that + // errored before removeCandidates ever ran) never transition past the + // 'queued' phase set by markWorktreesQueuedForDeletion above; clear it + // so the sidebar doesn't show a permanent "Queued for deletion" overlay. if ( deleteState?.isDeleting && deleteState.error === null && deleteState.phase === 'queued' ) {As per coding guidelines, "When writing or modifying code driven by a design doc or non-obvious constraint, add a comment explaining why the code behaves the way it does. Keep comments short — one or two lines, capturing only the non-obvious reason."
Source: Coding guidelines
🧹 Nitpick comments (3)
src/main/ipc/workspace-cleanup-scan.ts (1)
187-210: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winDuplicate persisted-activity calculation.
getPersistedWorkspaceCleanupActivityAtre-implements the sameMath.max(lastActivityAt, createdAt)finite-guard logic already present inresolveWorkspaceCleanupActivityAt(workspace-cleanup-activity.ts, lines 38-39). Consider exporting a single shared helper fromworkspace-cleanup-activity.tsand reusing it here to avoid the two copies drifting.src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.ts (1)
3-5: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueConsider importing the shared delete-state type instead of a local duplicate.
This file re-declares a minimal
DeleteStateshape rather than deriving it from the worktree slice's actual delete-state type. Works today via structural typing, but a future rename ofisDeletingin the source type wouldn't be caught here.src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts (1)
1-352: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick winLGTM! Tests thoroughly cover ordering, ancestor-skip, timeout, and toast-aggregation behavior.
Given the empty-candidates gap flagged in
workspace-cleanup-background-removal.ts(lines 31-41), consider adding a regression test assertingonResultstill fires with{removedIds: [], failures: []}whencandidatesis empty.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID: f26e4032-31ef-49be-ad44-e295cb27d00a
📒 Files selected for processing (25)
src/main/ipc/workspace-cleanup-activity.test.tssrc/main/ipc/workspace-cleanup-activity.tssrc/main/ipc/workspace-cleanup-scan.tssrc/main/ipc/workspace-cleanup.test.tssrc/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-labels.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.test.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsxsrc/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.test.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.tssrc/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsxsrc/renderer/src/i18n/locales/en.jsonsrc/renderer/src/i18n/locales/es.jsonsrc/renderer/src/i18n/locales/ja.jsonsrc/renderer/src/i18n/locales/ko.jsonsrc/renderer/src/i18n/locales/zh.jsonsrc/renderer/src/store/slices/store-cascades.test.tssrc/renderer/src/store/slices/workspace-cleanup.test.tssrc/renderer/src/store/slices/workspace-cleanup.tssrc/renderer/src/store/slices/worktree-helpers.tssrc/renderer/src/store/slices/worktrees.ts
✅ Files skipped from review due to trivial changes (2)
- src/renderer/src/i18n/locales/ja.json
- src/renderer/src/i18n/locales/es.json
🚧 Files skipped from review as they are similar to previous changes (4)
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx
- src/renderer/src/store/slices/worktree-helpers.ts
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsx
- src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
Co-authored-by: Orca <[email protected]>
- Fail a queued removal that now needs a force the user never approved (confirm-time approvedCandidates snapshot compared in preflight) - Reword the 120s removal timeout to say removal continues in background - Wire suppressPreservedBranchToast into cleanup removals - Stop statting a repo after the first activity metadata timeout - Document the WSL 9P best-effort stat gap; drop unused locale key Co-authored-by: Orca <[email protected]>
Rebasing onto latest main pushed the combined store-slice test over the 800-line cap. Extract shared fixtures into a test harness and split the suite into scan-progress and removal-preflight files instead of adding a forbidden max-lines suppression.
a4aa7fc to
303f295
Compare
|
Reviewed and de-staled this end to end. Rebase / conflicts: branch was 457 commits behind Verification: full typecheck, oxlint on all changed files, max-lines ratchet, 360 affected tests, and localization catalog/coverage all pass. Perf: all claimed fixes verified to hold — abort-signal forwarding to Code review: two independent reviewers, both clean. One accepted low nit: a nested removal that exceeds the 120s timeout is tallied as a hard failure even though it keeps running in the background (conservative/safe, rare edge). Electron validation: exercised live with real backdated worktrees (no faked data) — compact rows, expand/collapse, the stay-open deletion progress modal ( Merging once checks are green. |
Clean auto-merge, no conflicts (109 files, +7490 from main). Brought in: - Codex WSL runtime status hooks (#7969); WSL/SSH agent path resolution past shell aliases (#7867); WSL source-control path separators (#7966); WSL GitLab-auth wake fix (#7967); WSL Codex usage RPC refresh (#7567/#7658) - Improve workspace cleanup list (#7053) + background removal - mobile: per-host connection log + Tailscale wedge recovery (#7984/#7980), wake slept agents on mobile worktree open (#7906) - Harden layout validation, watcher lifecycle, connection robustness (#7924) - Disable experimental worktree card style by default (#7977) Perf-branch structure preserved (clean auto-merge). typecheck 0 errors; lint 0 errors. CI is the release gate (local runs skipped per env lag). Co-authored-by: Orca <[email protected]>
* Improve workspace cleanup list Co-authored-by: Orca <[email protected]> * Address workspace cleanup review feedback Co-authored-by: Orca <[email protected]> * Fix workspace cleanup perf findings Co-authored-by: Orca <[email protected]> * Avoid stale cleanup progress cache Co-authored-by: Orca <[email protected]> * Complete workspace cleanup perf fixes Co-authored-by: Orca <[email protected]> * Fix worktree list option forwarding Co-authored-by: Orca <[email protected]> * Address workspace cleanup review nits Co-authored-by: Orca <[email protected]> * Fix workspace cleanup removal review findings - Fail a queued removal that now needs a force the user never approved (confirm-time approvedCandidates snapshot compared in preflight) - Reword the 120s removal timeout to say removal continues in background - Wire suppressPreservedBranchToast into cleanup removals - Stop statting a repo after the first activity metadata timeout - Document the WSL 9P best-effort stat gap; drop unused locale key Co-authored-by: Orca <[email protected]> * Split workspace-cleanup slice test to satisfy max-lines Rebasing onto latest main pushed the combined store-slice test over the 800-line cap. Extract shared fixtures into a test harness and split the suite into scan-progress and removal-preflight files instead of adding a forbidden max-lines suppression. --------- Co-authored-by: Orca <[email protected]> Co-authored-by: Brennan Benson <[email protected]>
Summary
x/n deleted, and only toast when deletion completes or fails.Queued for deletion.git worktree list, making streamed cleanup progress avoid count-only row copies plus repeated full candidate-index rebuilds, preventing stale queued progress from recreating the scan-local index after final completion, and clearing cleanup enrichment cache on final completion.Testing
pnpm exec vitest run --config config/vitest.config.ts src/main/ipc/workspace-cleanup-activity.test.ts src/main/ipc/workspace-cleanup.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.test.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.test.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/renderer/src/store/slices/store-cascades.test.ts src/renderer/src/components/sidebar/WorktreeCard.hosted-review-refresh.test.tsxpnpm exec vitest run --config config/vitest.config.ts src/main/repo-worktrees.test.ts src/main/ipc/workspace-cleanup-activity.test.ts src/main/ipc/workspace-cleanup.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.test.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.test.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/renderer/src/store/slices/store-cascades.test.ts src/renderer/src/components/sidebar/WorktreeCard.hosted-review-refresh.test.tsxpnpm exec vitest run --config config/vitest.config.ts src/main/repo-worktrees.test.ts src/renderer/src/store/slices/workspace-cleanup.test.tspnpm exec vitest run --config config/vitest.config.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.tspnpm exec vitest run --config config/vitest.config.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/main/repo-worktrees.test.ts src/main/ipc/workspace-cleanup.test.tspnpm exec vitest run --config config/vitest.config.ts src/relay/git-handler.test.ts src/main/providers/ssh-git-provider.test.ts src/main/repo-worktrees.test.ts src/main/ipc/workspace-cleanup-activity.test.ts src/main/ipc/workspace-cleanup.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.test.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.test.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/renderer/src/store/slices/store-cascades.test.ts src/renderer/src/components/sidebar/WorktreeCard.hosted-review-refresh.test.tsxpnpm exec oxlint src/main/repo-worktrees.ts src/main/repo-worktrees.test.ts src/renderer/src/store/slices/workspace-cleanup.ts src/renderer/src/store/slices/workspace-cleanup.test.tspnpm exec oxlint src/relay/git-handler.ts src/relay/git-handler.test.ts src/renderer/src/store/slices/workspace-cleanup.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/main/repo-worktrees.ts src/main/repo-worktrees.test.tspnpm exec oxlint src/main/ipc/workspace-cleanup-scan.ts src/main/ipc/workspace-cleanup-activity.ts src/main/ipc/workspace-cleanup-activity.test.ts src/renderer/src/components/workspace-cleanup/WorkspaceCleanupDialog.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-background-removal.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-labels.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row.test.tsx src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-candidate-row-data.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-removal-candidates.test.ts src/renderer/src/components/workspace-cleanup/workspace-cleanup-status-pill.tsx src/renderer/src/store/slices/workspace-cleanup.ts src/renderer/src/store/slices/workspace-cleanup.test.ts src/renderer/src/store/slices/worktree-helpers.ts src/renderer/src/store/slices/worktrees.ts src/renderer/src/store/slices/store-cascades.test.tspnpm run verify:localization-catalog && pnpm run verify:localization-coveragepnpm exec tsgo --noEmit -p config/tsconfig.node.jsonpnpm run tc:webgit diff --checkScreenshots
AI Review Report
$perfsubagent audited commitddd4525c2and found two perf issues: dropped local cleanup-scan abort signals and O(N²) renderer append progress. Both were fixed in4f169a85b; follow-up perf verification found a stale-cache edge fixed in80635eb0a, then SSH relay cancellation and enrichment-cache retention gaps fixed in414ee6768.ddd4525c2: linked gitdir activity metadata, background-removal timeout guard, result-callback isolation, and aggregate failure descriptions.Security Audit
Notes