codex - 💡(How to fix) Fix Data loss: resumed-thread errors due missing rollout JSONL files (state still has threads, files gone) [4 comments, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#21196Fetched 2026-05-06 06:25:04
View on GitHub
Comments
4
Participants
1
Timeline
9
Reactions
0
Author
Participants
Timeline (top)
commented ×4labeled ×4subscribed ×1

Error Message

Attempting to resume a thread failed with a missing rollout file error.

RAW_BUFFERClick to expand / collapse

Environment

  • Date: 2026-05-05 (local timezone)
  • Platform: Codex Desktop (local session data under C:\Users\[redacted]\\.codex)

What happened

Attempting to resume a thread failed with a missing rollout file error.

This was not an isolated thread: all historical thread payloads appear to be missing from disk while metadata rows remain.

Findings

  • state_5.sqlite contains 91 rows in threads.
  • session_index.jsonl contains 1 entry.
  • Only 1 rollout-*.jsonl file exists in session storage.
  • 90 other thread IDs in threads point to missing rollout_path files.
  • The broken path reported in the failure is:
    • C:\Users\[redacted]\.codex\sessions\2026\05\05\rollout-2026-05-05T21-23-50-<redacted>.jsonl

This appears to be a case where durable chat payloads were removed without corresponding metadata cleanup, causing previously available history to become unreachable.

Expected behavior

  • Rollout files should not disappear silently while metadata remains.
  • If files are missing, the system should provide recovery/repair guidance and avoid orphaning threads.

Severity

High (multiple days of user history become inaccessible).

extent analysis

TL;DR

The most likely fix involves reconciling missing rollout files with existing metadata by either recovering the deleted files or removing the corresponding metadata to prevent orphaned threads.

Guidance

  • Investigate the cause of the missing rollout files, such as accidental deletion or a bug in the file management system, to prevent future occurrences.
  • Check for any backup or versioning systems that may contain copies of the missing rollout files, which could be used for recovery.
  • Consider implementing a data integrity check to identify and handle discrepancies between metadata and actual file presence, preventing silent data loss.
  • Develop a repair mechanism that can either restore missing files or safely remove metadata for non-existent files, ensuring data consistency.

Example

No specific code example can be provided without more context on the system's architecture and programming language used. However, the approach would involve iterating through the metadata, checking for the existence of corresponding rollout files, and taking appropriate action based on the system's requirements.

Notes

The solution may require modifications to the system's data management and integrity checking mechanisms. It's also important to consider user notification and feedback mechanisms to inform them about the loss of data and any subsequent recovery or cleanup actions.

Recommendation

Apply a workaround by implementing a data integrity check and repair mechanism to handle missing rollout files and prevent future instances of silent data loss, as the root cause of the issue needs to be addressed to ensure long-term data reliability.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

  • Rollout files should not disappear silently while metadata remains.
  • If files are missing, the system should provide recovery/repair guidance and avoid orphaning threads.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix Data loss: resumed-thread errors due missing rollout JSONL files (state still has threads, files gone) [4 comments, 1 participants]