Skip to content

24.18.0: corepack ignoring(?) proxy environment variables #64499

Description

@tgurr

Version

v24.18.0

Platform

Linux host 7.0.9 #1 SMP PREEMPT_DYNAMIC Wed May 20 14:53:26 CEST 2026 x86_64 GNU/Linux

Subsystem

No response

What steps will reproduce the bug?

With our package manager configured to pass proxy env variables:

http_proxy="http://proxy.domain.corporate:3128"
https_proxy="http://proxy.domain.corporate:3128"
ftp_proxy="http://proxy.domain.corporate:3128"

after upgrading node.js from LTS 22.23.1 to LTS 24.18.0 corepack called by our package manager is no longer able to successfully fetch for example pnpm as it does not use the proxy anymore but tries to connect directly (as can be seen in our firewall logs).

How often does it reproduce? Is there a required condition?

Always

What is the expected behavior? Why is that the expected behavior?

  • Keep working with node 24.18.0 like with 22.23.1 before
  • Have corepack using the configured proxy

What do you see instead?

Failure to fetch:

Adding pnpm@11.13.0 to the cache...
mkdir -p /var/cache/paludis/distfiles/corepack
corepack pack pnpm@11.13.0 -o /var/cache/paludis/distfiles/corepack/pnpm-11.13.0.tar.gz

Error:
  * In program cave perform fetch --hooks --if-supported --managed-output --output-exclusivity with-others --no-terminal-titles =dev-node/pnpm-11.13.0:0::arbor --x-of-y 1 of 1:
  * When fetching 'dev-node/pnpm-11.13.0:0::arbor':
  * When running an ebuild command on 'dev-node/pnpm-11.13.0:0::arbor':
  * Extra fetch failed for 'dev-node/pnpm-11.13.0:0::arbor' (paludis::ActionFailedError)

Internal Error: Error when performing the request to https://registry.npmjs.org/pnpm/-/pnpm-11.13.0.tgz; for troubleshooting help, see https://github.com/nodejs/corepack#troubleshooting
    at fetch (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:12951:11)
    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
    at async fetchUrlStream (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:12981:20)
    at async download (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:13133:18)
    at async installVersion (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:13229:55)
    at async Engine.ensurePackageManager (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:13744:32)
    at async PackCommand.execute (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:14276:34)
    at async PackCommand.validateAndExecute (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:1343:26)
    at async _Cli.run (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:2453:22)
    at async Object.runMain (/usr/x86_64-pc-linux-gnu/lib/node_modules/corepack/dist/lib/corepack.cjs:14560:19)

And also deny logs in the firewall from the host which confirms that corepack tries to fetch things directly without using the proxy.

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions