Codex CLI 0.149.0 corrupts tool-call arguments and degenerates into gibberish on gpt-5.6-sol
What version of Codex CLI is running?
codex-cli 0.149.0
What subscription do you have?
Pro 5x
Which model were you using?
gpt-5.6-sol, reasoning effort: high
What platform is your computer?
Linux 6.12.0-211.49.1.el10_2.x86_64 x86_64 unknown
What terminal emulator and version are you using (if applicable)?
kitty + zellij with fish shell
Codex doctor report
{
"schemaVersion": 1,
"generatedAt": "1787563614s since unix epoch",
"overallStatus": "ok",
"codexVersion": "0.149.1",
"checks": {
"app_server.status": {
"id": "app_server.status",
"category": "app-server",
"status": "ok",
"summary": "background server is not running",
"details": {
"control socket": "/home/sugar/.codex/app-server-control/app-server-control.sock",
"daemon state dir": "/home/sugar/.codex/app-server-daemon",
"mode": "ephemeral",
"pid file": "/home/sugar/.codex/app-server-daemon/app-server.pid (missing)",
"settings": "/home/sugar/.codex/app-server-daemon/settings.json (missing)",
"status": "not running",
"update-loop pid file": "/home/sugar/.codex/app-server-daemon/app-server-updater.pid (missing)"
},
"remediation": null,
"durationMs": 0
},
"auth.credentials": {
"id": "auth.credentials",
"category": "auth",
"status": "ok",
"summary": "auth is configured",
"details": {
"auth file": "/home/sugar/.codex/auth.json",
"auth storage mode": "File",
"stored API key": "false",
"stored ChatGPT tokens": "true",
"stored agent identity": "false",
"stored auth mode": "chatgpt"
},
"remediation": null,
"durationMs": 0
},
"config.load": {
"id": "config.load",
"category": "config",
"status": "ok",
"summary": "config loaded",
"details": {
"CODEX_HOME": "/home/sugar/.codex",
"config.toml": "/home/sugar/.codex/config.toml",
"config.toml parse": "ok",
"cwd": "/home/sugar",
"enabled feature flags": "shell_tool, view_image, unified_exec, shell_snapshot, code_mode_host, terminal_resize_reflow, sqlite, hooks, enable_request_compression, unbounded_connection_retries, multi_agent, apps, tool_search_always_defer_mcp_tools, tool_suggest, plugins, in_app_browser, in_app_chat, in_app_dictation, in_app_updates, browser_use, browser_use_full_cdp_access, browser_use_external, computer_use, remote_plugin, plugin_sharing, image_generation, resize_all_images, item_ids, skill_mcp_dependency_install, skill_search, mentions_v2, steer, guardian_approval, goals, collaboration_modes, tool_call_mcp_elicitation, auth_elicitation, personality, fast_mode, tui_app_server, remote_compaction_v2, workspace_dependencies",
"feature flag overrides": "none",
"feature flags enabled": "42",
"log dir": "/home/sugar/.codex/log",
"mcp servers": "1",
"model": "gpt-5.6-sol",
"model provider": "openai",
"sqlite home": "/home/sugar/.codex"
},
"remediation": null,
"durationMs": 0
},
"git.environment": {
"id": "git.environment",
"category": "git",
"status": "ok",
"summary": "git version 2.52.0",
"details": {
"PATH git #1": "/usr/bin/git",
"PATH git entries": "1",
"git build options": "git version 2.52.0; cpu: x86_64; no commit associated with this build; sizeof-long: 8; sizeof-size_t: 8; shell-path: /bin/sh; rust: disabled; libcurl: 8.12.1; OpenSSL: OpenSSL 3.5.1 1 Jul 2025; zlib-ng: 2.2.3; SHA-1: SHA1_DC; SHA-256: SHA256_BLK; default-ref-format: files; default-hash: sha1",
"git exec path": "/usr/libexec/git-core",
"git version": "git version 2.52.0",
"repo detected": "false",
"selected git": "/usr/bin/git"
},
"remediation": null,
"durationMs": 23
},
"installation": {
"id": "installation",
"category": "install",
"status": "ok",
"summary": "installation looks consistent",
"details": {
"PATH codex #1": "/home/sugar/.local/bin/codex",
"current executable": "/home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/bin/codex",
"install context": "standalone (unix, package /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl, bin /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/bin, resources /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/codex-resources, path /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/codex-path)",
"managed by bun": "false",
"managed by npm": "false",
"managed by pnpm": "false",
"managed package root": "not set"
},
"remediation": null,
"durationMs": 0
},
"mcp.config": {
"id": "mcp.config",
"category": "mcp",
"status": "ok",
"summary": "MCP configuration is locally consistent",
"details": {
"configured servers": "1",
"disabled servers": "0",
"stdio servers": "1"
},
"remediation": null,
"durationMs": 0
},
"network.env": {
"id": "network.env",
"category": "network",
"status": "ok",
"summary": "network-related environment looks readable",
"details": {
"managed proxy": "not configured",
"proxy env vars": "none",
"respect system proxy": "disabled"
},
"remediation": null,
"durationMs": 0
},
"network.provider_reachability": {
"id": "network.provider_reachability",
"category": "reachability",
"status": "ok",
"summary": "active provider endpoints are reachable over HTTP",
"details": {
"ChatGPT inference URL": "https://chatgpt.com/backend-api/<redacted> reachable (HTTP 405)",
"reachability mode": "ChatGPT auth"
},
"remediation": null,
"durationMs": 312
},
"network.websocket_reachability": {
"id": "network.websocket_reachability",
"category": "websocket",
"status": "ok",
"summary": "Responses WebSocket handshake succeeded",
"details": {
"DNS": "2 IPv4, 2 IPv6, first IPv6",
"auth mode": "chatgpt",
"connect timeout": "15000 ms",
"endpoint": "wss://chatgpt.com/backend-api/<redacted>",
"handshake result": "HTTP 101 Switching Protocols",
"model provider": "openai",
"provider name": "OpenAI",
"proxy env vars": "none",
"reasoning header": "false",
"server model present": "false",
"supports websockets": "true",
"wire API": "responses"
},
"remediation": null,
"durationMs": 707
},
"runtime.provenance": {
"id": "runtime.provenance",
"category": "runtime",
"status": "ok",
"summary": "running standalone on linux-x86_64",
"details": {
"commit": "unknown",
"current executable": "/home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/bin/codex",
"install method": "standalone (unix, package /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl, bin /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/bin, resources /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/codex-resources, path /home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/codex-path)",
"platform": "linux-x86_64",
"version": "0.149.1"
},
"remediation": null,
"durationMs": 0
},
"runtime.search": {
"id": "runtime.search",
"category": "search",
"status": "ok",
"summary": "search is OK (bundled)",
"details": {
"search command": "/home/sugar/.codex/packages/standalone/releases/0.149.1-x86_64-unknown-linux-musl/codex-path/rg",
"search command readiness": "file exists",
"search provider": "bundled"
},
"remediation": null,
"durationMs": 0
},
"sandbox.helpers": {
"id": "sandbox.helpers",
"category": "sandbox",
"status": "ok",
"summary": "sandbox configuration is readable",
"details": {
"approval policy": "OnRequest",
"codex-linux-sandbox helper": "/home/sugar/.codex/tmp/arg0/codex-arg0uZRO4t/codex-linux-sandbox",
"execve wrapper helper": "/home/sugar/.codex/tmp/arg0/codex-arg0uZRO4t/codex-execve-wrapper",
"filesystem sandbox": "restricted",
"network sandbox": "restricted"
},
"remediation": null,
"durationMs": 0
},
"security.endpoint": {
"id": "security.endpoint",
"category": "security",
"status": "ok",
"summary": "endpoint protection is not inspected on this platform",
"details": {
"endpoint products": "not inspected on this platform"
},
"remediation": null,
"durationMs": 0
},
"state.paths": {
"id": "state.paths",
"category": "state",
"status": "ok",
"summary": "state paths and databases are inspectable",
"details": {
"CODEX_HOME": "/home/sugar/.codex (dir)",
"active rollout files": "103 files, 505535741 total bytes, 4908113 average bytes",
"archived rollout files": "66 files, 246596024 total bytes, 3736303 average bytes",
"goals DB": "/home/sugar/.codex/goals_1.sqlite (file)",
"goals DB integrity": "ok",
"log DB": "/home/sugar/.codex/logs_2.sqlite (file)",
"log DB integrity": "ok",
"log dir": "/home/sugar/.codex/log (missing)",
"memories DB": "/home/sugar/.codex/memories_1.sqlite (file)",
"memories DB integrity": "ok",
"queue DB": "/home/sugar/.codex/queue_1.sqlite (file)",
"queue DB integrity": "ok",
"sqlite home": "/home/sugar/.codex (dir)",
"standalone release cache": "6 entries in /home/sugar/.codex/packages/standalone/releases",
"state DB": "/home/sugar/.codex/state_5.sqlite (file)",
"state DB integrity": "ok",
"thread history DB": "/home/sugar/.codex/thread_history_1.sqlite (file)",
"thread history DB integrity": "ok"
},
"remediation": null,
"durationMs": 1041
},
"state.rollout_db_parity": {
"id": "state.rollout_db_parity",
"category": "threads",
"status": "ok",
"summary": "rollout files and state DB thread inventory agree",
"details": {
"default model provider": "openai",
"rollout DB active files": "103",
"rollout DB active rows": "103",
"rollout DB archive mismatches": "0",
"rollout DB archived files": "66",
"rollout DB archived rows": "66",
"rollout DB duplicate DB paths": "0",
"rollout DB duplicate rollout thread ids": "0",
"rollout DB malformed file names": "0",
"rollout DB missing active rows": "0",
"rollout DB missing archived rows": "0",
"rollout DB model providers": "openai=165, my-provider=4",
"rollout DB rows": "169",
"rollout DB scan cap reached": "false",
"rollout DB scan errors": "0",
"rollout DB sources": "subagent:thread_spawn=91, subagent:other=55, cli=12, vscode=11",
"rollout DB stale rows": "0"
},
"remediation": null,
"durationMs": 96
},
"system.disk": {
"id": "system.disk",
"category": "disk",
"status": "ok",
"summary": "sufficient free disk space (368.3 GiB)",
"details": {
"CODEX_HOME available": "368.3 GiB",
"failure threshold": "1.0 GiB",
"warning threshold": "5.0 GiB",
"worktree available": "368.3 GiB"
},
"remediation": null,
"durationMs": 0
},
"system.environment": {
"id": "system.environment",
"category": "system",
"status": "ok",
"summary": "OS language en-US",
"details": {
"EDITOR": "set",
"LANG": "en_US.UTF-8",
"VISUAL": "not set",
"os": "Red Hat Enterprise Linux 10.2.0 [64-bit]",
"os language": "en-US",
"os type": "Red Hat Enterprise Linux",
"os version": "10.2.0"
},
"remediation": null,
"durationMs": 0
},
"terminal.env": {
"id": "terminal.env",
"category": "terminal",
"status": "ok",
"summary": "terminal metadata was detected",
"details": {
"COLORTERM": "truecolor",
"DISPLAY": "present",
"TERMINFO": "/usr/lib64/kitty/terminfo (dir)",
"WAYLAND_DISPLAY": "present",
"color output": "enabled",
"effective locale": "en_US.UTF-8",
"stderr is terminal": "true",
"stdin is terminal": "true",
"stdout is terminal": "true",
"terminal": "kitty",
"terminal size": "202x44"
},
"remediation": null,
"durationMs": 0
},
"terminal.title": {
"id": "terminal.title",
"category": "title",
"status": "ok",
"summary": "terminal title default",
"details": {
"terminal title activity": "true",
"terminal title items": "activity, project-name",
"terminal title project source": "cwd",
"terminal title project value": "sugar",
"terminal title source": "default"
},
"remediation": null,
"durationMs": 0
},
"updates.status": {
"id": "updates.status",
"category": "updates",
"status": "ok",
"summary": "update configuration is locally consistent",
"details": {
"cached latest version": "0.149.1",
"check for update on startup": "true",
"last checked at": "2026-08-24T08:02:38.587922353Z",
"latest version": "0.149.1",
"latest version status": "current version is not older",
"update action": "standalone installer",
"version cache": "/home/sugar/.codex/version.json"
},
"remediation": null,
"durationMs": 644
}
}
}
What issue are you seeing?
During a Codex CLI session, the model entered a corrupted generation state.
It initially produced a normal commentary response, but the following tool calls contained corrupted paths and filenames. Shortly afterward, the TUI started displaying repetitive pseudo-language / gibberish until I interrupted the turn.
This was not only a terminal rendering issue. The corrupted tool-call arguments were persisted in the rollout JSONL as response_item / custom_tool_call records.
The correct working directory was:
/mnt/data/Projects/atme/nori-platform
but Codex generated paths such as:
/u001zeni/no permissions needed
/mnt/data/Projects/atme/nuk
/mnt/data/Projects/atuk
Known skill files such as:
.agents/skills/nori-human-review/SKILL.md
.agents/skills/nori-code-structure/SKILL.md
.agents/skills/nori-specs/SKILL.md
were also repeatedly changed to:
SKUL.md
After the first failed tool call, Codex correctly recognized the problem and said:
The prior preflight command had a bad working directory and a typo in the specs-skill filename, so it failed before reading or changing repository files. I’ve corrected both and am continuing the approved R-058 implementation now.
However, the immediately following tool call corrupted the same working-directory and filename values again.
The TUI later began streaming repetitive gibberish / pseudo-language. That gibberish does not appear as a finalized assistant response_item in the rollout JSONL, likely because I interrupted the turn before the streamed response was committed.
What steps can reproduce the bug?
I do not currently have a minimal deterministic reproducer, but this is the sequence that triggered the issue:
Run a relatively long, tool-heavy Codex CLI session.
Use gpt-5.6-sol with reasoning effort set to high.
Continue working in the same thread after multiple tool calls.
I replied with: ok
Codex produced a normal commentary message.
The next generated tool call contained a corrupted working directory and corrupted filename.
Tool execution failed because the generated paths did not exist.
I interrupted the stuck turn.
I sent: continue
Codex explicitly recognized that the previous working directory and filename were wrong and said it had corrected them.
The immediately following tool call corrupted the same values again.
The TUI subsequently began streaming repetitive gibberish until I interrupted it again.
The corruption therefore appears to happen during model response / tool-call generation rather than inside the shell command itself.
What is the expected behavior?
Codex should preserve known working-directory paths and filenames when generating tool calls.
After identifying an incorrect path or filename and explicitly stating that it has corrected the error, the following tool call should use the corrected values.
The model should also not enter a state where normal assistant output degenerates into repetitive pseudo-language or gibberish.
If generation or the streaming state becomes invalid, Codex should fail or retry cleanly rather than continuing to emit corrupted tool-call arguments or nonsensical output.
Additional information
Environment:
Codex CLI: 0.149.0
Model: gpt-5.6-sol
Reasoning effort: high
Platform: Linux
Originator: codex-tui
Model provider: openai
Context window: 828,400 tokens
At the first observed failure:
last input tokens: 175,386
context window: 828,400
context usage: ~21.2%
At the second failure:
last input tokens: 176,475
context window: 828,400
context usage: ~21.3%
This does not appear to have been caused by approaching the model context-window limit.
The session had approximately 5 million cumulative tokens, but this is cumulative session usage rather than the active context size.
I also did not find obvious stream disconnected, retry, or compaction events around the affected turns in the rollout.
Session/thread ID:
01a03302-0a17-7c33-98b4-a105c0c80024
I can provide:
A screenshot showing the gibberish output in the Codex TUI.
The affected rollout JSONL records.
A sanitized excerpt covering the affected turns.
codex doctor --json output if needed.
<img width="1916" height="798" alt="Image" src="https://github.com/user-attachments/assets/f88d655e-4ebe-4f65-95aa-dc50406d7ab3" />
The most useful rollout section is approximately ordinals 287–323, which contains the normal response, corrupted tool calls, failed executions, interruptions, and the second occurrence of tool-call corruption.
1 Comment
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action