openai / openai/codex

Managed network proxy injects unsupported npm_config_http_proxy

Open Beginner friendly
#44,854 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug CLI connectivity
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

Codex version

0.154.0

Platform

macOS, Codex CLI managed network proxy enabled

Problem

Every npm or npx command prints:

npm warn Unknown env config "http-proxy". This will stop working in the next major version of npm. See `npm help npmrc` for supported config options.

The managed network proxy injects both npm_config_http_proxy and NPM_CONFIG_HTTP_PROXY. npm normalizes these to http-proxy, which is not a supported npm config key. The supported npm proxy keys are proxy and https-proxy.

Reproduction
  1. Start a Codex session with the managed network proxy enabled.
  2. Run npx vitest --version or npm --version.
  3. Observe the warning above.

Clearing both unsupported variables for one command removes the warning. Registry access still works through the supported proxy variables that Codex also injects.

Expected behavior

Codex should retain HTTP_PROXY, HTTPS_PROXY, npm_config_proxy, npm_config_https_proxy, and their uppercase forms, but stop injecting npm_config_http_proxy and NPM_CONFIG_HTTP_PROXY.

Additional context

#4193 reported the same warning and was closed without a linked fix. The current 0.154.0 release still reproduces it. npm 12.0.2 still warns, so this remains an active forward-compatibility issue rather than an immediate npm 12 failure.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Search the Codex CLI code that injects managed-proxy environment variables, focusing on npm_config_http_proxy and NPM_CONFIG_HTTP_PROXY. Reproduce with npx vitest --version or npm --version; done means those unsupported variables are absent while the listed supported proxy variables remain and npm no longer warns.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js
Domain
cli, networking
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.