codex - 💡(How to fix) Fix app-server capReached reports true when output exactly equals outputBytesCap

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…

Fix Action

Fix / Workaround

I have a small local patch covering both command/exec and process/spawn if maintainers think this matches the intended protocol semantics.

Patch branch: https://github.com/mturac/codex/tree/audit/cap-reached-exact-cap

RAW_BUFFERClick to expand / collapse

I found a small edge case in app-server output cap handling.

When output length is exactly equal to outputBytesCap, capReached can be reported as true even though no output was actually truncated.

I tested three cases locally:

  • below cap -> capReached = false
  • exactly at cap -> capReached = false
  • above cap -> capReached = true

The narrow fix is to derive capReached from whether the original chunk was actually shortened, rather than whether the observed byte count equals the cap.

I have a small local patch covering both command/exec and process/spawn if maintainers think this matches the intended protocol semantics.

Patch branch: https://github.com/mturac/codex/tree/audit/cap-reached-exact-cap

Commit: https://github.com/mturac/codex/commit/956b2a8950264c41c25281583fea7746c793d8fb

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

codex - 💡(How to fix) Fix app-server capReached reports true when output exactly equals outputBytesCap