Help: Codex VSCode Plugin Login Issues on Windows 10 - 403 Forbidden & Workspaces Not Found

Hi bros,

I’m facing two issues with the Codex plugin in VSCode on Windows 10:

  1. Token Exchange Failed: After clicking “Sign in with ChatGPT,” I enter credentials and verification code, select a workspace, and get redirected to ‘http:/localhost:1455/auth/callback?… ‘ It shows: “Token exchange failed: token endpoint returned status 403 Forbidden”.
  2. Workspaces Not Found: Sometimes, I get “Workspaces not found in client auth session” instead.

Environment:

  • OS: Windows 10
  • VSCode Version: 1.1.1.1
  • Codex Plugin Version: v0.4.15
  • Browser: Chrome Chromium 134.0.6998.136

Tried:

  • Clearing browser cache/cookies.
  • Using system proxy settings (no effect).
  • Reinstalling Codex plugin.
  • No firewall/antivirus.

Has anyone faced these errors? Any fixes for the 403 Forbidden or “Workspaces not found” issues? Thanks for any help!

have the same issue, but on Mac. @yatoons, any success with ur problem?

same issue,have you solved it

Hi Community, I have a solution for this bug

OS: Ubuntu 20.04
VS Code: APT / .deb version
Browser: Firefox
Network: Optional proxy via Clash Verge
Issue: VS Code Codex login fails
Token exchange failed: token endpoint returned status 403 Forbidden

FIX:

  1. Ensure localhost never goes through proxy

{export NO_PROXY=127.0.0.1,localhost,::1}

  1. If using proxy (Clash / V2Ray), use HTTP port (example 10809)

{
export http_proxy=http://(delete this)127.0.0.1:10809
export https_proxy=http://(delete this)127.0.0.1:10809
}

  1. VS Code settings.json

{
“http.proxy”: “http://(delete this)127.0.0.1:10809”,
“http.noProxy”: “127.0.0.1,localhost,::1”,
“http.proxySupport”: “override”
}

  1. Browser
    Use system proxy
    Under Settings – Network Settings – Use system proxy settings – No proxy for
    {localhost, 127.0.0.1}

You may noticed that after you re-open your pc, the vscode can not be opened properly, for everytime you wanna open your vscode, type
{code --disable-layout-restore --user-data-dir /tmp/vscode-fix &
}

I haven’t fix this issue yet