openai / openai/codex

Windows Desktop 26.901.6511.0: experimental new_context loses task after successful checkpoint write

Open
#43,709 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

app bug context session windows-os
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

What version of the Codex App are you using (From “About Codex” dialog)?

26.901.6511.0 (app server / CLI 0.153.4)

What subscription do you have?

ChatGPT Plus

What platform is your computer?

Microsoft Windows NT 10.0.26200.0 x64

What issue are you seeing?

After updating Codex Desktop to 26.901.6511.0 on 2026-09-07, I first observed an experimental context-management failure that ends an active long-running task after automatic context rollover.

The important failure path is that the checkpoint write succeeds, but after new_context the controller does not restore it. The replacement history contains only startup instructions, no active task state, and the assistant immediately finishes with a generic response such as:

你好,需要我帮你做什么?

This is not limited to the notes/history endpoint failure reported in #43194. In the strongest occurrence here, notes.append_to_file returned success. The failure was the missing mandatory restore after the reset.

I also observed a second occurrence where the notes request failed and new_context still proceeded. That path overlaps #43194, but it is not the only reproduction in this report.

What steps can reproduce the bug?

This was reproduced twice in the same long-lived Codex Desktop task with experimental context management enabled.

Environment:

  • Model: gpt-5.6-sol
  • Reasoning effort: high
  • History mode recorded in the rollout: paginated
  • The persisted task was originally created with CLI 0.151.0-alpha.7.2, then resumed after updating to app server 0.153.4 / Desktop 26.901.6511.0. This may make migration of an existing long-running task part of the trigger.
Reproduction A: successful checkpoint write, skipped restore
  1. Continue a long-running task until the token-budget fallback requests a checkpoint and context rollover.
  2. notes.append_to_file completes successfully.
  3. new_context completes successfully and reports that a new context window will start without summarizing conversation history.
  4. The next compacted record has an empty message and only five replacement-history items (45,534 visible characters).
  5. Those items contain startup/app instructions and injected environment instructions, but neither the checkpoint identifier nor the active user request/task marker.
  6. No notes.list_files_by_prefix, notes.read_file, or history recovery call occurs after the reset.
  7. The assistant immediately emits 你好,需要我帮你做什么? and completes the turn.
Reproduction B: failed checkpoint write, reset still proceeds
  1. Continue the same long-running task until another rollover.
  2. notes.write_file returns Unable to perform operation: The backend request failed.
  3. The local structured log records a failed POST to https://chatgpt.com/backend-api/codex/alpha/notes/v2/write_file; the surfaced error does not preserve an HTTP status or request ID.
  4. Despite the failed checkpoint write, the model calls new_context.
  5. alpha/notes/v2/thread_hint also fails during the reset.
  6. The replacement history again contains only five startup items and no active task/checkpoint.
  7. The assistant asks what task it should handle and completes the turn.
Successful control in the same task

An earlier rollover in the same task recovered correctly:

  1. The first notes.write_file attempt failed.
  2. The model retried with notes.append_to_file, which succeeded.
  3. After new_context, it called notes.list_files_by_prefix and notes.read_file before continuing the exact active task.

This comparison suggests that recovery currently depends on the model voluntarily retrying and reading the checkpoint. The transition controller does not appear to enforce successful persistence and restoration before allowing the old context to be replaced or a final response to be emitted.

The failed transitions were also expensive: the three model responses around each failure accounted for approximately 0.49M tokens, mostly cached input, before losing the task state.

What is the expected behavior?
  • After new_context, the controller must restore the successful checkpoint before the first normal reasoning step or assistant output.
  • If checkpoint persistence fails, new_context must not discard the current context; retain the old history or use the stable compaction fallback.
  • A post-reset turn must not be allowed to complete with a generic greeting while an active task checkpoint exists.
  • Notes/history failures should expose an HTTP status and request ID for diagnosis.
  • Mandatory rollover should avoid repeatedly replaying a nearly full context for checkpoint/reset attempts.
Additional information
  • First observed immediately after updating Codex Desktop on 2026-09-07. I did not observe this exact successful-write/skipped-restore path before that update.
  • #43194 partially overlaps the backend-failure path, but does not cover this Windows Desktop regression where checkpoint persistence succeeded and restoration was skipped.
  • #36712 and #36642 report a similar generic-response/task-loss symptom, but not this experimental checkpoint lifecycle or the successful control from the same task.
  • I retained the local rollout and structured logs. They include private task content, so I am not attaching them publicly. I can provide narrowly redacted event excerpts or identifiers through a private maintainer channel if requested.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the experimental context-management rollover around new_context, comparing the successful control with the failed transitions in the retained rollout and structured logs. Check the checkpoint operations notes.append_to_file, notes.list_files_by_prefix, and notes.read_file; done means successful checkpoints are restored before output, failed persistence retains the old context, and an active task cannot end with a generic greeting.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend, devtools
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.