Skip to content

Codex Desktop emits “remote compact task” model-capacity error during automatic compaction #35911

Open

Description

@mattLummus

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

26.721.41059

What subscription do you have?

Plus

What platform is your computer?

macOS on Apple Silicon, with Codex Desktop connected to an ARM64 Linux devcontainer. Remote environment: Linux 6.12.76-linuxkit aarch64 Codex runtime 0.145.0

What issue are you seeing?

Automatic context compaction failed twice with:
"Error running remote compact task: Selected model is at capacity. Please try a different model."

The UI first displayed “Context automatically compacted” and then displayed the error. Sending another message caused the same sequence to occur again.

I did not change models. The same task later recovered and continued successfully, demonstrating that changing models was neither necessary nor desirable.

This is especially confusing because the error refers to a “remote compact task” and instructs the user to change models.

A Codex contributor previously stated that compaction had moved locally to the normal-turn endpoint to eliminate remote-compaction errors. Reporting this error again per their comment:
#28303 (comment)
"If you see further problems with compaction, please use /feedback and open a new bug report."

What steps can reproduce the bug?

  1. Open a long-running task in Codex Desktop connected to a remote devcontainer.
  2. Use gpt-5.6-sol with medium reasoning effort.
  3. Continue the task until automatic context compaction is triggered.
  4. In this occurrence, the preceding turn used approximately 223,423 of the 258,400-token context window (86.5%).
  5. Send a normal user prompt and allow Codex to continue working.
  6. Observe “Context automatically compacted.”
  7. Observe: “Error running remote compact task: Selected model is at capacity. Please try a different model.”
  8. Send another normal message without changing models.
  9. Observe the compaction message and the same error again.
  10. The task subsequently recovers without changing models.

Session ID:
019fa659-bf28-73b1-8d9c-4ad2eb3e14f7

Approximate occurrence:
2026-07-29 06:30–06:38 UTC

Feedback ID:
[PASTE THE ID RETURNED BY /feedback HERE]

What is the expected behavior?

Automatic compaction should complete using the currently selected model.

If a transient capacity failure occurs, Codex should retry transparently or offer a retry action while preserving the selected model. It should not tell the user to change models when the task can recover without doing so.

The task’s tools, pending command state, and context should remain intact.

Additional information

Selected model: gpt-5.6-sol
Reasoning effort: medium
Codex runtime: 0.145.0
App version: 26.721.41059
Subscription: Plus
Remote environment: Linux 6.12.76-linuxkit aarch64
Task originator recorded as: Codex Desktop
Task source recorded as: vscode

At the token event immediately before the failure:

  • Context use was approximately 86.5%.
  • Account rate-limit use was reported as 0%.
  • No rate-limit-reached type was recorded.

The task eventually recovered after a later compaction attempt. No repository changes or pending command output were lost.

Activity

  1. added
    app
    on Jul 29, 2026
  2. added
    bug
    context
    on Jul 29, 2026
  3. github-actions commented on Jul 29, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  4. mattLummus commented on Aug 29, 2026

    @mattLummus
    Author

    Leaving this open and not closing as duplicate as error message is materially different than other issues filed. That being said it has not happened as of late.

  5. JorgeMenaDev commented on Sep 5, 2026

    @JorgeMenaDev

    Confirming this is still happening today, September 5, 2026, with GPT-6-Astra selected in T3 Code on macOS.

    Local Codex app-server event logs show two separate threads failing with the exact error:

    Error running remote compact task: Selected model is at capacity. Please try a different model.
    

    The compaction failures occurred at 14:39:14 UTC and 14:55:35 UTC. One of those threads also received the ordinary model-capacity error at 14:49:31 UTC.

    For each failure, the native Codex error notification contained codexErrorInfo: "serverOverloaded" and willRetry: false. The subsequent native turn/completed notification reported status: "failed". T3 displayed those same provider errors. These are distinct native error events, excluding duplicate UI/canonical events and completion notifications.

    The locally installed CLI reports codex-cli 0.153.4; we have not independently verified that the affected T3 processes used that exact executable version. Recovery has not been tested. This confirms a current occurrence through Codex app-server in another client, rather than a reproduction of the original Desktop/devcontainer setup.

  6. leezisheng commented on Oct 14, 2026

    @leezisheng

    Codex CLI: Repeated Model Capacity Errors and Remote Compaction Failures Across Long-Running Sessions

    Environment

    • Product: OpenAI Codex CLI
    • Observed version: v0.153.2
    • Operating system: Windows
    • Subscription: ChatGPT Pro
    • Authentication: ChatGPT account login
    • Models tested: GPT-6 Astra, GPT-5.6 Sol, Terra and Luna
    • Setup: Multiple Codex sessions across four computers

    Issue Description

    I have been experiencing frequent and persistent capacity errors in Codex, particularly during long-running sessions and automatic context compaction.

    The errors include:

    Selected model is at capacity. Please try a different model.
    
    Error running remote compact task:
    Selected model is at capacity.
    Please try a different model.
    

    In some cases, the conversation is interrupted and the persistent Goal becomes stalled.

    Observed Behavior

    1. Existing long-running sessions repeatedly fail during remote context compaction.
    2. Switching between different models and reasoning levels does not consistently resolve the issue.
    3. Newly created sessions sometimes work, but they also intermittently encounter capacity errors.
    4. Logging out and logging back into the ChatGPT account has not provided a reliable solution.
    5. Usage quota was still available when the errors occurred.
    6. Network logs have occasionally shown WebSocket timeouts and fallback to HTTPS.

    Impact

    This issue seriously disrupts ongoing engineering projects. Some sessions contain substantial work history, and repeated compaction failures prevent us from continuing these tasks reliably.

    Expected Behavior

    • Temporary capacity errors should be retried automatically where possible.
    • Automatic context compaction should not permanently interrupt a long-running session.
    • Persistent Goals should remain recoverable after transient service errors.
    • Switching models should not be required to recover an unrelated compaction failure.

    Request

    Could the Codex team investigate whether these failures are caused by remote compaction infrastructure, account-level request routing, concurrent sessions, or service capacity management?

    Please also advise on a supported way to recover affected long-running sessions without losing their working context.

    Additional Information

    Affected session IDs, timestamps, sanitized logs and screenshots can be provided privately upon request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appbugcontext

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions