Where does the bug appear (feature/product)?
Cursor IDE
Describe the Bug
Cursor’s local Composer revert operation targeted files outside the active chat’s workspace, including another git repository, an ignored .env file, a tracked .gitignore file, and scratch files outside any workspace. The operation ran without a preview or confirmation. Its only direct record was a burst in composer.log; there was no corresponding mutating git command.
A separate but closely related incident two days earlier silently replaced pending, uncommitted background-agent edits at another chat’s discarded-turn boundary. That second incident did not emit a reverting to message line, so it is reported as related evidence rather than asserted to be the same internal code path.
Environment
- Product: Cursor IDE
- Cursor version at the time: 3.26.16, verified from
currentVersion=3.26.16in the session’smain.log - OS: macOS 27.0.1, build 26A434
- Architecture: Apple silicon (
darwin-arm64appears in the Cursor update URL) - Session layout: 12 Cursor window log directories (
window1throughwindow12), Multitask Mode enabled, with multiple background agents running - Model: not recoverable for the revert-to-message incident; the related discarded-turn incident used Claude Opus 5.5
- Request ID: unavailable; this was a local IDE file operation rather than a failed model request
Verified incident: 2026-10-23 23:46:18–23:46:27 EDT
The session’s composer.log contains 127 file-operation entries followed by one completion entry. The file-operation entries break down as follows:
- 42 paths in
<repo-a>: 3Processed file ... for revert operationentries and 39Deleted non existent fileentries - 1 path in
<repo-b>: 1Deleted non existent fileentry - 84 paths under
<scratch>: 84Deleted non existent fileentries
The first three entries explicitly include <repo-a>/.env, <repo-a>/.gitignore, and one source file:
2026-10-23 23:46:18.581 [info] [composer] Processed file file:///<repo-a>/.env for revert operation []
2026-10-23 23:46:18.582 [info] [composer] Processed file file:///<repo-a>/.gitignore for revert operation []
2026-10-23 23:46:18.582 [info] [composer] Processed file file:///<repo-a>/src/<source-file>.py for revert operation []
2026-10-23 23:46:18.583 [info] [composer] Deleted non existent file file:///<repo-a>/<file-1> []
... 123 additional file-operation entries ...
2026-10-23 23:46:27.233 [info] [composer] Completed reverting to message <message-id> []
The exact elapsed time from the first file-operation entry to completion was 8.652 seconds. Searching all available Cursor logs for the message identifier found only the completion line: there was no corresponding starting line, file-list preview, workspace declaration, or chat/composer identifier attached to the operation.
Repository inspection confirms that .env is ignored and .gitignore is tracked. The log therefore proves that the revert operation processed both ignored and tracked files. The report does not claim that every Deleted non existent file entry changed an existing file; those lines prove that the revert operation’s target set crossed repository and workspace boundaries.
Related incident: 2026-10-21 18:31 and 18:37 EDT
A background agent in a linked git worktree had pending edits made through Cursor’s edit tools. At two turn boundaries in another chat:
- At 18:31:35.924–18:31:35.942, the Filesync log recorded 16 uploads covering exactly four pending files. At 18:31:36.285 a turn was added, and at 18:31:36.321 it was removed 36 ms later. The Python extension logged an editor-save-triggered test discovery at 18:31:36.011.
- At 18:37:54.801–18:37:54.809, Filesync recorded four uploads of another pending test file, followed by sync entries for two source files. At 18:37:55.104 a turn was added, and at 18:37:55.137 it was removed 33 ms later. The Python extension logged test discovery at 18:37:54.956.
In both cases, pending Cursor-tool edits were replaced by older contents. Mutating git operations, stash entries, resets, and reflog changes were absent. Edits already committed survived. Two shell-made edits from the same interval also survived, while the pending Cursor-tool edits were the affected set.
No reverting to message entry appears at either discarded-turn time. This establishes a related silent checkpoint/file-sync rollback symptom, but not that both incidents used the same internal implementation.
Steps to Reproduce
Steps to reproduce
These steps are intentionally marked untested because reproducing the issue while active workspaces are open risks further data loss.
- Create two disposable git repositories, A and B, and open both in Cursor.
- In chat 1, create or edit a tracked canary in A, an ignored canary in A, and a canary in B. Send another message so there is an earlier message to revert to.
- From chat 2 or by hand, add distinctive uncommitted lines to all three canaries.
- In chat 1, use “revert to message” on the earlier message.
- Check whether the later lines remain, and inspect
composer.logforProcessed file ... for revert operationorDeleted non existent fileentries naming B or the ignored canary. - For the related pattern, let a background agent make an uncommitted Cursor-tool edit in a linked worktree, then start and immediately cancel or replace a turn in another chat. Check whether the pending edit remains and inspect Filesync, renderer, and Python extension logs.
Reproducibility
- Revert-to-message cross-workspace incident: observed once with direct
composer.logevidence; safe reproduction has not been attempted. - Related discarded-turn rollback: observed twice within one session, 6 minutes 19 seconds apart, with matching Filesync, renderer, and editor-save timestamps.
- Overall: intermittent; the exact trigger is unknown.
Expected Behavior
A chat revert should affect only files that the same chat edited, within that chat’s workspace, and only when those files have not changed since the chat’s edit. Changed files should be skipped and reported. Files in other repositories, files outside the workspace, and ignored files should never be included merely because they were touched by another chat or agent. Before any destructive file restoration, Cursor should show the exact file list and diffs and require confirmation.
Actual behavior
- A revert operation assembled a target set spanning two repositories and scratch paths outside the workspace.
- It processed ignored files, including
.env. - It applied without preview, confirmation, conflict detection, or an on-screen list of affected files.
- The completion log did not identify the originating chat/composer or workspace.
- In the related incident, pending edits from a background agent were silently replaced at another chat’s discarded-turn boundary without a
reverting to messagelog entry.
Operating System
MacOS
Version Information
Version: 3.27.12
VS Code Extension API: 1.128.0
Commit: df132ffba90dfc15a12e6b8f020ba4e5d026c4b0
Date: 2026-10-23T02:27:47.076Z
Layout: IDE
Build Type: Stable
Release Track: Default
Electron: 42.11.16
Chromium: 148.0.7778.280
Node.js: 24.19.0
V8: 14.8.178.38-electron.0
xterm.js: 6.1.0-beta.291
OS: Darwin arm64 27.0.0
For AI issues: which model did you use?
Using Sonnet, Composer and other models.
Additional Information
Impact and severity
Severity: critical data-loss risk. Cursor remains usable only with mitigations such as very frequent commits and an external file-integrity monitor. Uncommitted and ignored files can have no recoverable git copy, and the operation is silent enough that loss may not be discovered until much later.
For the forum’s “Does this stop you from using Cursor?” field: Sometimes — Cursor can be used, but background/multitask work and message reverts are unsafe without external safeguards.
Requested fixes
- Show the exact file list and diffs before applying any revert, and require confirmation.
- Restrict a revert to files the originating chat itself edited, within that chat’s workspace.
- Before restoring, verify that each file is unchanged since that chat’s last edit; skip and report conflicts.
- Never include ignored files unless the originating chat explicitly created or edited them.
- Log a starting line, originating chat/composer id, workspace, full file list, and per-file result.
- Make discarded-turn cleanup incapable of restoring file checkpoints belonging to other chats or agents.
- Provide a setting to disable destructive chat checkpoint restoration for background and multitask sessions.
- Please identify whether a fix or guard already exists and the first version containing it.
Does this stop you from using Cursor
No - Cursor works, but with this issue