Codex extension should pass `noProxy` option as `NO_PROXY` env when calling CLI

Open 💬 5 comments Opened Nov 17, 2025 by changchinlan

What version of the VS Code extension are you using?

0.4.43

What subscription do you have?

Team

Which IDE are you using?

VS Code

What platform is your computer?

Linux 6.8.0-52-generic x86_64 x86_64

What issue are you seeing?

My organization need to access some of resources through proxy, but not Codex endpoints. I have tried to add chatgpt.com related domains to http.noProxy option, but it does not work. Digging into the minified code I have found that extension.js only passes http.proxy as HTTP_PROXY and HTTPS_PROXY when running Codex CLI. We should pass NO_PROXY too.

What steps can reproduce the bug?

  1. Set VSCode http proxy to some internal proxy.

"http.proxy": "192.168.1.1:3128"

  1. Add ChatGPT related names to noProxy.

"http.noProxy": ".chatgpt.com"

  1. Try to start Codex, send something, you will get Connection failed: error sending request for url...
  2. PATCH the extension.js to pass NO_PROXY, and it works.

What is the expected behavior?

Codex extension works as expected when http.proxy and http.noProxy are set in VS Code.

Additional information

_No response_

View original on GitHub ↗

5 Comments

michel-mexique · 9 months ago

+1

gaby · 8 months ago

I'm running into the same issues, makes using the extension behind a corporate proxy impossible.

gaby · 8 months ago

@etraut-openai Any updates on this?

reoLantern · 7 months ago

+1

michel-mexique · 6 months ago

Seems like Codex for VSCode will respect the HTTP_PROXY and HTTPS_PROXY inside ~/.codex/.env, but still won't acknowledge NO_PROXY. So yeah.... I got around it by setting :

HTTP_PROXY=""
HTTPS_PROXY=""

in ~/.codex/.env, then Ctrl + Shift + P, > Developer : Reload window to refresh VSCode.
Works on VSCode extension version 0.4.71, but don't know for > 0.4.71 since they seem to be trying to nuke open-source models support 🙃