Codex Diff resolves missing review artifacts and crashes in editor-diff-page
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Start at the editor-diff-page error boundary and trace how review artifacts under .git/refs/codex/turn-diffs/captures/... and checkpoints/... are resolved and read through fs/readFile. Reproduce the missing-artifact case in both workspace contexts; done means the diff renders when possible or shows a recoverable missing-review state instead of crashing.
Written by the indexing model from the issue text.
Description
Summary
Codex Diff fails to load in the VS Code/VSCodium extension because the review view attempts to read a missing internal file/artifact, then crashes in editor-diff-page.
The visible failure pattern is:
Request failed ... method=fs/readFile ... \"No such file or directory (os error 2)\"- followed immediately by an
editor-diff-pageerror boundary
This appears to be a review-artifact / thread-state resolution bug. Multi-root workspaces seem to make it easier to trigger, but I also reproduced the same failure from a single-folder workspace window.
Environment
- Codex VS Code extension:
openai.chatgpt@26.721.30844 - IDE:
VSCodium 1.126.04524 - Platform: Linux x64
What issue are you seeing?
Opening Codex Diff / Review changes can fail completely.
Instead of rendering the review diff, the extension logs a failed internal file read and the diff webview crashes. This makes the review flow unusable even though Git itself is fine.
I also observed that chats are not repo-specific: the same chat can be reopened from another folder/window. That may be relevant, because the failing diff looks like it is being resolved against stale or mismatched thread/workspace state.
Steps to reproduce
I have seen this in both of these situations:
Path A: multi-root trigger
- Open a VS Code/VSCodium workspace with more than one root folder.
- Use the Codex extension normally.
- Make or review a change.
- Open Codex Diff / Review changes.
- Observe that the diff fails to load and the review view crashes.
Path B: single-folder window after thread reuse
- Open a single-folder workspace/window.
- Reopen or continue an existing Codex chat.
- Open Codex Diff / Review changes.
- Observe the same
fs/readFilefailure andeditor-diff-pagecrash.
Expected behavior
Codex Diff should either:
- render the review diff successfully, or
- show a recoverable error if the underlying review artifact is missing
It should not crash the entire review view.
This is especially important because the IDE docs describe Codex as letting users review changes beside your code.
Actual behavior
- Codex Diff fails to load
- extension logs
fs/readFilewithNo such file or directory (os error 2) - the diff UI crashes in
editor-diff-page
Log evidence
Repeated failures of the same kind:
Request failed conversationId=none ... error={"code":-32603,"message":"No such file or directory (os error 2)"} ... method=fs/readFile
Immediately followed by:
error boundary ... editor-diff-page ...
I also saw a later Git watcher failure under Codex's own review/checkpoint refs:
[git-repo-watcher] Git repo watcher failed errorCode=ENOENT errorMessage=\"ENOENT: no such file or directory, scandir '.../.git/refs/codex/turn-diffs/checkpoints/...'\"
That makes it look like the diff/review flow is referencing a missing internal checkpoint artifact, not just a normal workspace file.
Additional observations
- Multi-root workspace support is already a known weak area in the extension.
- However, this specific bug is not cleanly explained as multi-root only, because I also saw the same crash from a single-folder window.
- The more precise pattern seems to be:
- chat/thread context can be reopened across workspace/folder boundaries
- Codex Diff then tries to load review artifacts that do not exist in the current context
- missing artifact ->
fs/readFilefailure ->editor-diff-pagecrash
I also saw signs of thread/UI state drift in logs during the same general period, including:
- conversations being resumed in different workspace contexts
- later
Item not found in turn stateerrors in the same extension family of session problems
That may be related, although the core bug here is the deterministic Codex Diff crash on missing review artifacts.
Why this seems like a state-resolution bug
This does not look like normal Git diff failure.
The extension is using its own internal review/checkpoint storage under:
.git/refs/codex/turn-diffs/captures/....git/refs/codex/turn-diffs/checkpoints/...
Those refs exist on disk, but the extension later attempts to read or watch checkpoint content that is missing. Combined with the non-repo-specific chat reuse behavior, this strongly suggests the diff viewer is resolving against stale or mismatched review/thread/workspace state.
Expected fallback behavior
If the backing review artifact is missing, the extension should not crash the diff page. It should instead show a clear recoverable state such as:
- review artifact missing, please reopen review
- chat/workspace context changed, regenerate review
- this review is no longer available for the current workspace
Related reports
#35058Codex Diff crashes with Oops, an error has occurred in VS Code on macOS#2909Support for multi-root workspaces#35073VS Code extension crashes in multi-root workspaces on Windows#24263Renderer reload / turn-state desync causingItem not found in turn state
This report is closest to #35058 because the log signature matches exactly, but I am including the workspace/thread-context observations because they may help explain why the missing file lookup happens.
- Dominant language
- Rust
- Stars
- 125k
- Forks
- 19.5k
- Avg merge
- 1m
- Merged PRs (30d)
- 1k
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from openai/codex
-
enhancement remote
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
bug CLI windows-os
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
macOS sandbox blocks hw.optional.arm64 sysctl, causing Flutter to misdetect Apple Silicon as x64 Openbug CLI sandbox
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
bug CLI TUI
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
CLI config enhancement skills
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
kwakseongjae/auto-hwp#319 ·
-
area:cli bug filter-quality good first issue priority:medium
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 1/5 Under an hour Newbie friendliness 72/100
bevyengine/bevy#25861 ·
-
comp-datalake
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
ClickHouse/ClickHouse#121222 ·
-
A-linter
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
oxc-project/oxc#26863 ·