Codex Desktop shows "No changes reverted" and skips tracked file when using Undo

Open 💬 1 comment Opened Jun 16, 2026 by wbygit

Title:
Codex Desktop shows "No changes reverted" and skips tracked file when using Undo

Description:
The following details were collected and anonymized by Codex during local debugging.

Environment

  • OS: Windows
  • Codex Desktop package: OpenAI.Codex_26.609.9530.0_x64__2p2nqsd0c76g0
  • Codex CLI / app-server: codex-cli 0.140.0-alpha.2
  • Browser / in-app browser backend after update: 26.609.71450
  • Browser / in-app browser backend before update: 26.609.41114
  • Primary runtime selected/latest: codex-primary-runtime 26.614.11602
  • Shell: PowerShell
  • Mode: local thread, workspace-write
  • Repo: private Git repository on Windows

Summary

Codex Desktop fails to undo a simple Codex-created change to an existing tracked text file. The file is in a private repository, so the path and contents are omitted.

The app shows "No changes reverted", skips the tracked file, and leaves the working tree modified.

Steps To Reproduce

  1. Start a local Codex thread in a Git repo on Windows.
  2. Ensure the working tree is clean.
  3. Ask Codex to make a tiny edit to an existing tracked text file, for example adding one HTML comment near the top of the file.
  4. Confirm git diff -- <tracked-file> shows only that one added line.
  5. Click Codex Desktop's Undo button for the change.

Expected Behavior

The Codex-created change should be undone, or the app should show a concrete actionable error.

Actual Behavior

The app shows this error in English UI:

No changes reverted
There were issues reverting some files
Skipped (1)

README.md

In Chinese UI, the same dialog appears as:

未还原任何更改
还原部分文件时出错
已跳过(1 个)

README.md

The change remains in the working tree:

 M <tracked-file>

The diff contains only a single added line, similar to:

@@ -1,4 +1,5 @@
 <existing first line>
+<!-- codex undo retest after update -->
 <existing second line>
 <existing third line>

EOL state after Codex edit:

git ls-files --eol <tracked-file>
i/lf    w/mixed attr/ <tracked-file>

Previous Reproduction Before Update

A previous reproduction on the same type of tracked file produced this direct log error:

source=thread_diff
git cat-file -s <object-hash>
exitCode=128
failureReason=command_failed

Re-running the same command manually produced:

fatal: git cat-file: could not get object info

Current Reproduction After Update

The same UI failure still happens after updating to:

OpenAI.Codex_26.609.9530.0
codex-cli 0.140.0-alpha.2
browser backend 26.609.71450

In the current reproduction, the UI failure is the same, but I did not find the same explicit git cat-file error in the visible app logs.

Possibly Related Issue

Possibly related to #23693, but this is a different failure mode.

In #23693, the rollback diff was not symmetric with the original edit. In this case, Codex Desktop's Undo fails outright, skips the tracked file, and leaves the working tree modified.

Notes

  • A separate test with a newly-created untracked file reverted successfully.
  • The failure appears specific to an existing tracked file, at least when Codex's edit leaves the worktree file in w/mixed EOL state.
  • Git clients can still revert the file normally with:

``powershell
git restore -- <tracked-file>
``

  • The repository itself does not appear corrupted.
  • I am omitting the original file path, file name, and logs because they contain private repository information.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗