Conversation
High priority fixes: - Fix token count mismatch: token counting now includes file headers and markdown fences to match actual copy output format exactly - Fix missing useEffect dependencies: add includeBinaryPaths, tok, and onBatch to useTokenCounts dependencies - Fix preview file race condition: add request ID tracking to prevent displaying wrong file content when switching quickly - Fix debounce cleanup: add cancel() method and call it on unmount to prevent setState after unmount warnings - Fix Rust rename/copy handling: properly track old_path and new_path for renames and copies instead of misclassifying them - Fix non-UTF8 file handling: use lossy UTF-8 conversion for files with encodings like Latin-1 instead of erroring Medium priority fixes: - Fix template overwrite: add confirmation dialog before replacing user's custom instructions with template - Fix desktop resetRepo semantics: add clarifying comments that dispose() is reusable and service instance persists Quality improvements: - Move PROMPT_TEMPLATES outside component to avoid recreation on every render - Remove SelectedFilesPanel key prop to prevent unnecessary remounts and state loss when selection changes
- Fix diff computation race condition: add request ID tracking to prevent stale diff results from overwriting current branch selection when user switches branches quickly - Fix token counting error handling: log errors instead of throwing from useEffect to prevent unhandled promise rejections and app crashes - Fix rename detection in git_diff: call find_similar() to enable proper rename and copy detection instead of showing as delete+add pairs
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1a8a5f6579
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| git2::Delta::Renamed => { | ||
| // For renames, store the new path as primary and old path separately | ||
| (new_path.clone().unwrap_or_default(), "rename", old_path) |
There was a problem hiding this comment.
Handle new rename/copy statuses in UI diff flow
The diff now emits "rename" (and "copy") statuses, but the front-end only recognizes FileDiffStatus = 'modify' | 'add' | 'remove' | 'unchanged' (see packages/core/src/types.ts) and useFileTree casts diff types into that union. As a result, renamed/copied files will fall through the “unchanged” handling in copyAllSelected/token counting, which fetches content at the new path from the base ref and often yields empty output, so users won’t see the rename/copy diff and may think the file is unchanged. This only shows up when the diff includes renames/copies, but it means the new statuses aren’t actually supported end‑to‑end.
Useful? React with 👍 / 👎.
|
🎉 This PR is included in version 2.0.2 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
No description provided.