codex - 💡(How to fix) Fix Session quota consumed without any user interaction (just opening sessions drains 18-24%) [1 comments, 2 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#19076Fetched 2026-04-24 06:01:20
View on GitHub
Comments
1
Participants
2
Timeline
9
Reactions
1
Author
Timeline (top)
cross-referenced ×3labeled ×3closed ×1commented ×1

Root Cause

Possible root causes:

  1. CLI session init automatically indexes the repo (+150 staged files) and sends context to the API before any user prompt
  2. Background polling or health-check loop sends model API requests during idle sessions
  3. If a previous session had corrupted context (e.g. empty base64 image per #19069), background retries silently drain quota
  4. /status command itself may be triggering a model API call instead of just reading a local cache

Code Example

5h limit:     76% left  (resets 03:00 on 23 Apr)
Weekly limit: 77% left  (resets 17:51 on 28 Apr)
RAW_BUFFERClick to expand / collapse

Environment

  • Codex CLI version: codex-cli v0.123.0
  • Subscription: Plus
  • Model: gpt-5.3-codex (reasoning: low, summaries: auto)
  • Platform: macOS (Intel iMac 2020)

What version of Codex are you using?

codex-cli v0.123.0 — confirmed via /status command output

What subscription do you have?

Plus

What issue are you seeing?

Session quota (both 5h and weekly limits) is being consumed without any user interaction. Simply opening a CLI session — without typing a single prompt — drains significant quota immediately. The bug also reproduces using the Codex CLI, not just the Mac App.

Observed quota drops:

  • Opened 1-2 sessions with no prompts → -18% on 5h limit, -22% on weekly limit immediately
  • Ran /status twice (no other commands) → -6% more on 5h limit in under 1 minute
  • Total lost to zero user work: ~24% of 5h limit and ~23% of weekly limit

Current state after /status only:

5h limit:     76% left  (resets 03:00 on 23 Apr)
Weekly limit: 77% left  (resets 17:51 on 28 Apr)
<img width="1234" height="682" alt="Image" src="https://github.com/user-attachments/assets/9b660264-9279-4374-bd6d-3cf2f5b194d7" /> <img width="1297" height="556" alt="Image" src="https://github.com/user-attachments/assets/3fe0dd5a-338b-475c-b06c-07291a5c2f19" />

Steps to Reproduce

  1. Update codex-cli and authenticate with a Plus/Pro account
  2. Activate the option Memories
  3. Run codex in any local repository (e.g. one with staged changes)
  4. Do NOT type any prompt — just run /status to check quota
  5. Wait ~1 minute and run /status again
  6. Observe the quota indicator has dropped significantly between the two /status calls

Expected Behavior

Quota should not be consumed unless the user explicitly sends a prompt or authorizes an agent action. Running /status or simply having an open idle session should consume zero quota.

Actual Behavior

  • Opening a session immediately consumed ~18-24% of limits with no prompt sent
  • Running /status twice consumed an additional ~6% of the 5h limit
  • No agent task, shell command, or file operation was triggered by the user
  • Context usage in the session showed 100% remaining (empty context), yet quota was being consumed in the background
  • The session ID 019db868-e008-7c02-94d4-e0081182aeca was the only active session

Additional Context

This issue reproduces on both the Codex Mac App and the Codex CLI (codex-cli v0.123.0), confirming it is not UI-specific but a core agent/API issue.

Related issues:

  • #19069 — Session limit reached without doing anything (background retry loop on invalid base64 image)
  • #18972 — Quota limits % used without any requests (closed as duplicate, but the bug persists)

The silent background consumption makes it impossible to use the subscription effectively — the weekly limit can be exhausted before any real work is done.

Possible root causes:

  1. CLI session init automatically indexes the repo (+150 staged files) and sends context to the API before any user prompt
  2. Background polling or health-check loop sends model API requests during idle sessions
  3. If a previous session had corrupted context (e.g. empty base64 image per #19069), background retries silently drain quota
  4. /status command itself may be triggering a model API call instead of just reading a local cache

extent analysis

TL;DR

The issue can be mitigated by disabling the "Memories" option or investigating background API calls triggered by the Codex CLI session initialization or the /status command.

Guidance

  • Investigate if the "Memories" option is triggering background indexing of the repository, causing quota consumption.
  • Check if the /status command is sending model API requests instead of reading a local cache, and consider optimizing or caching its behavior.
  • Look into potential background polling or health-check loops that might be consuming quota during idle sessions.
  • Review related issues (#19069 and #18972) for possible connections to the problem, especially regarding corrupted context or background retries.

Example

No code snippet is provided as the issue seems to be related to the Codex CLI's behavior rather than a specific code implementation.

Notes

The root cause of the issue is not explicitly stated, and the provided information suggests multiple possible explanations. Further investigation into the Codex CLI's behavior, especially regarding session initialization, background tasks, and the /status command, is necessary to pinpoint the exact cause.

Recommendation

Apply a workaround by disabling the "Memories" option or optimizing the /status command behavior, as these seem to be directly related to the quota consumption issue. This approach allows for immediate mitigation of the problem while further investigation into the root cause continues.

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…

Still need to ship something?

×6

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

Back to top recommendations

TRENDING