Codex extension (VS Code & Cursor) fails to load chat pane after recent update

Resolved 💬 8 comments Opened Aug 30, 2025 by saucony Closed Aug 30, 2025

What version of Codex is running?

all newest versions on both cursor and vs code. the documentation and support ai chat says that using the older versions is not recommended since they automatically get depreciated. I still tested them to see if they work nonetheless

Which model were you using?

all / NA

What platform is your computer?

Darwin 24.6.0 arm64 arm

What steps can reproduce the bug?

Since Aug 28–29, 2025, I’ve been unable to load the Codex chat/side panel in both Cursor and VS Code. The extension either shows a perpetual spinner or fails with service worker errors. This behavior started immediately after the extension auto-updated (v0.4.0). Rolling back to v0.3.1 did not resolve it.

Environment
• macOS (Apple Silicon, Sequoia)
• Cursor latest build (as of Aug 29, 2025)
• VS Code (latest stable)
• OpenAI Codex extension versions tested:
• v0.4.0 (auto-updated, broken)
• v0.3.1 (manually pinned, still broken)

Errors observed
• Cursor webview console:
• Found unexpected service worker controller … Waiting for controllerchange.
• No service worker controller found. Waiting for controllerchange.
• ERR Failed to get ServiceWorkerRegistration objects: InvalidStateError
• VS Code console:
• “Error starting conversation”
• Git context errors: Error fetching branches: Could not determine default branch
• Undo button greyed out after Codex applies edits (Cursor).

Troubleshooting already attempted

  1. Ran Cursor’s built-in network diagnostics → all green (HTTP/2, TLS, DNS fine).
  2. Disabled VPN/proxy (not in use).
  3. Toggled Disable HTTP/2 (both on and off).
  4. Cleared Electron/Chromium caches:

• ~/Library/Application Support/Cursor/{Service Worker, Cache, IndexedDB, WebStorage, Code Cache, GPUCache}
• globalStorage/openai.chatgpt

  1. Launched with --disable-extensions.
  2. Created fresh profile dirs with --user-data-dir and --extensions-dir.
  3. Disabled Git context in Composer; confirmed git installed (git version 2.49.0).
  4. Reinstalled Codex extension multiple times, including pinning v0.3.1.
  5. Tested in empty folders (to rule out repo chat DB corruption).
  6. Verified same failure in VS Code Codex extension (not just Cursor).
  7. Checked GitHub issues and forums — multiple new Codex extension issues reported Aug 29 (e.g., “Error starting conversation”, reasoning settings ignored, 413 Payload Too Large).

Expected behavior
• Codex sidebar/chat should load and register its service worker normally.
• Should accept prompts and apply code edits in local files.

Actual behavior
• Chat pane never finishes loading (Cursor & VS Code).
• Webview stuck with SW controller mismatch or no controller.
• Repeated [composer] Error in submitPromptDryRun: ConnectError: [invalid_argument] Error.

Impact
• Cannot use Codex for any local file edits or conversations.
• Affects both Cursor and VS Code environments, suggesting the extension update is broken, not local setup.

Request
• Please confirm if v0.4.0 introduced a regression.
• Is there a known workaround or hotfix for the service worker/webview controller mismatch?
• Should users pin to a prior version (if available), or is a patch imminent?

What is the expected behavior?

the expected behavior is that the codex extension loads, but it is stuck in the loading bard that moves left and right.

What do you see instead?

_No response_

Additional information

vscode json settings:
"chatgpt.openOnStartup": true,
"chatgpt.apiBase": ""

codex was working prior to the updates from 24+ hours ago

View original on GitHub ↗

8 Comments

saucony · 10 months ago

This was resolved — root cause was a misformatted config.toml, fixed by replacing JSON with valid TOML

Root Cause

Codex was stuck in “Activating…” because the CLI crashed on startup.
The Output panel showed:

Failed to parse config.toml: TOML parse error at line 1, column 1
1 | {
| ^
invalid key-value pair, expected key

That revealed that ~/.codex/config.toml was actually JSON (I had migrated my mcp setup from cursor and claude without thinking)
(it started with { … }) instead of valid TOML. Since the extension calls the Codex CLI during activation, it never finished activating.

Steps taken

  1. Captured activation state

• Opened Developer: Show Running Extensions → Codex showed “Activating…”.
• Opened Output → Log (Extension Host) and Output → Codex → saw repeated TOML parse errors.

  1. Inspected Webview + Console

• Used Developer: Open Webview Developer Tools for the Codex panel.
• Ran:

navigator.serviceWorker.controller
navigator.serviceWorker.getRegistrations().then(r => r.map(x => x.scope))

• Confirmed the webview itself was fine (service worker activated), so the failure was in the extension backend, not the webview layer.

  1. Traced to config parsing

• The error stack in the Output panel (codex_core::config) pointed to the CLI’s TOML parser.
• Checked ~/.codex/config.toml with sed -n '1,40p' ~/.codex/config.toml → saw JSON ({ … }) instead of TOML.

  1. Backed up and rewrote config

• Moved the bad file:

mv ~/.codex/config.toml ~/.codex/config.toml.bak

• Replaced it with a valid TOML config (using [mcp_servers.*] tables instead of JSON braces).

  1. Restarted VS Code

• Relaunched VS Code.
• Codex immediately activated successfully.
• Verified in Developer: Show Running Extensions → Codex now shows Activated.
• No more TOML parse errors in the Output panel.

Resolution

The issue was caused by a malformed ~/.codex/config.toml (JSON instead of TOML).
Fixing the file to proper TOML format resolved the CLI parse error and allowed the Codex extension to activate normally.

eugeneoshepkov · 10 months ago

We need a reliable way to output malformed .toml error in the extension itself. I was stuck with the same issue, thinking that it's something on Codex (or Cursor) side

amirsajjadrahmani · 9 months ago

same issue!

eitai2001 · 8 months ago

I found the solution for me to be this (thanks to ChatGPT!):
Install/repair the two runtimes Codex most likely needs, then relaunch Cursor:

Microsoft Visual C++ Redistributable (x64, 2015–2022)

Microsoft Edge WebView2 Runtime (Evergreen)

On Windows you can do it quickly via winget in an Admin PowerShell:

winget install --id Microsoft.VCRedist.2015+.x64 -e --source winget
winget install --id Microsoft.EdgeWebView2Runtime --exact --source winget

Repleno · 8 months ago
winget install --id Microsoft.EdgeWebView2Runtime --exact --source winget

holy macaroly your awesome brother! Thanks!

Aspirewastaken · 7 months ago

I HATE CODEX IT WONT FIX NO MATTER WHAT ON MAC

VissoIT · 5 months ago

I solved by installing/ Repairing Microsoft Visual C++

YXGuan · 5 months ago
I found the solution for me to be this (thanks to ChatGPT!): Install/repair the two runtimes Codex most likely needs, then relaunch Cursor: Microsoft Visual C++ Redistributable (x64, 2015–2022) Microsoft Edge WebView2 Runtime (Evergreen) On Windows you can do it quickly via winget in an Admin PowerShell: winget install --id Microsoft.VCRedist.2015+.x64 -e --source winget winget install --id Microsoft.EdgeWebView2Runtime --exact --source winget

Thank you thank you. Somehow this also helped fix my issue