[Regression] 3.17.8 Windows: dirty Agent Review cache rewrites file EOL on every workspace open

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Where does the bug appear

Cursor IDE — Agent Review / session restore on startup

Describe the Bug

On Windows, leftover Agent Review snapshots are restored when opening a workspace. While restoring the buffer, EOL normalization writes the file back to disk (typically CRLF ↔ LF), even if the user did not edit or save, and even when auto-save is off.

This is a regression. Cursor staff marked the same class of bug fixed around 2026-05:

Related:

Once a file is in this state, every subsequent Cursor launch rewrites its line endings again. Manual unix2dos / files.eol / .editorconfig do not stop the loop. The loop only stops after opening the file and clicking Keep All (or Discard) in Agent Review, which clears the stale snapshot.

Deleting %APPDATA%\Cursor\User\workspaceStorage has been reported as insufficient for this path.

Steps to Reproduce

  1. On Windows, let Agent edit a tracked source file (inline Review / unaccepted Keep All).
  2. Convert or restore the file on disk to the repo’s original EOL (e.g. CRLF) and confirm git status is clean, without clicking Keep All / Discard in Review.
  3. Fully quit Cursor.
  4. Reopen the same workspace (no user edits, no save).
  5. Observe: the previously Agent-touched file is rewritten on disk; git diff shows only EOL changes.

Expected Behavior

Opening a workspace must not rewrite files on disk. Session restore must not apply a stale Review snapshot when disk content already differs only by (or already matches) the intended EOL. If contents are unchanged except cached EOL, do not write.

Actual Behavior

Startup restores the cached Agent Review buffer (often LF), EOL normalization runs, file is written to disk. Git shows EOL-only dirty files. Repeats on every launch until Keep All / Discard.

Version Information

  • Cursor: 3.17.8 (user setup) — latest stable as of 2026-08-22
  • OS: Windows_NT x64 10.0.17763 (Windows Server 2019 / LTSC)
  • Workspace: large C firmware SDK
  • .gitattributes: * -text (Git does not normalize EOL; EOL-only writes show up as real diffs)
  • No project .editorconfig
  • User settings.json does not set files.eol

Settings that do NOT fix it (per prior reports + this workspace)

  • files.eol, .editorconfig
  • converting with unix2dos then restarting
  • cursor.chat.saveUnconfirmedCodeChanges: false (prior report)

Workaround

Open Agent Review → Keep All (or Discard) on affected files → revert EOL-only diffs in Git → quit and reopen. Do not use Undo All (rolls back real disk content).

Request ID

<paste after: chat ... → Copy Request ID>

Additional notes for triage

Cache appears to live in workspace state.vscdb Review/inline-diff overlay, independent of Git. Staff previously said rewrite-on-startup when contents are unchanged should be fixed after 3.15.6; 3.17.8 still rewrites when the restore buffer’s EOL differs from disk.

Steps to Reproduce

  1. On Windows, let Agent edit a tracked source file (inline Review / unaccepted Keep All).
  2. Convert or restore the file on disk to the repo’s original EOL (e.g. CRLF) and confirm git status is clean, without clicking Keep All / Discard in Review.
  3. Fully quit Cursor.
  4. Reopen the same workspace (no user edits, no save).
  5. Observe: the previously Agent-touched file is rewritten on disk; git diff shows only EOL changes.

Expected Behavior

Opening a workspace must not rewrite files on disk. Session restore must not apply a stale Review snapshot when disk content already differs only by (or already matches) the intended EOL. If contents are unchanged except cached EOL, do not write.
Actual Behavior
Startup restores the cached Agent Review buffer (often LF), EOL normalization runs, file is written to disk. Git shows EOL-only dirty files. Repeats on every launch until Keep All / Discard.

Operating System

Windows 10/11

Version Information

  • Cursor: 3.17.8 (user setup) — latest stable as of 2026-08-22
  • OS: Windows_NT x64 10.0.17763 (Windows Server 2019 / LTSC)
  • Workspace: large C firmware SDK
  • .gitattributes: * -text (Git does not normalize EOL; EOL-only writes show up as real diffs)
  • No project .editorconfig
  • User settings.json does not set files.eol

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey @ivan_wl,
The reliable way to break the loop is exactly what you found:

  1. Open the affected file(s) → Keep All (or Discard) in Agent Review to clear the stale Review state.
  2. Start a new chat so nothing’s left pending.
  3. Revert the EOL-only diffs in Git once.

Launches won’t touch those files after that. Going forward, keeping/discarding pending Review edits before you quit or update keeps new files out of this state. One caution: skip Undo All on affected files - it rolls back real content, not just the EOL.

Recent updates stopped the launch-time rewrite of unchanged files, but the case you hit - restored Review state whose line endings differ from disk - still slips through. It’s not anything in your setup; we’ve let the team know and it’s an issue we’re tracking. I’ll follow up here when there’s an update.