Skip to content
This repository has been archived by the owner on Aug 11, 2022. It is now read-only.

Multiple case-sensitive PATH env variables defined in Windows #20959

Open
1 of 9 tasks
hokiedsp opened this issue Jun 11, 2018 · 0 comments
Open
1 of 9 tasks

Multiple case-sensitive PATH env variables defined in Windows #20959

hokiedsp opened this issue Jun 11, 2018 · 0 comments
Labels

Comments

@hokiedsp
Copy link

I'm opening this issue because:

  • npm is crashing.
  • npm is producing an incorrect install.
  • npm is doing something I don't understand.
  • npm is producing incorrect or undesirable behavior.
  • Other (see below for feature requests):

What's going wrong?

During install, my module under development utilizes a batch file in Windows to run a series of executables. One modifies environmental PATH setting while another uses the modified setting. In the latest version of npm, my module no longer installs successfully. Upon further investigation, I determined the issue: npm sets 3 PATH variables during its run-time---Path, path, and PATH.

Windows env variables are supposedly case-insensitive, thus breaks bat/cmd file which rely on path settings. The path that the second exe is reading isn't the one set by the first exe, and I have no control over these binaries. Also, because Windows does not recognize case-sensitivity, I have no way to detect this within my batch file AFAIK.

I believe this is a recently introduced issue as my install code used work in the past but I'm not sure exactly which version of npm this behavior was introduced.

How can the CLI team reproduce the problem?

Include "console.log(process.env)" in an install script of a module (say install.js), and compare the output between two runs: "npm install" and "node ./install.js"

supporting information:

  • npm -v prints: 6.1.0
  • node -v prints: v10.3.0
  • npm config get registry prints: https://registry.npmjs.org/
  • Windows, OS X/macOS, or Linux?: Windows
  • Container:
    • I develop using Vagrant on Windows.
    • I develop using Vagrant on OS X or Linux.
    • I develop / deploy using Docker.
    • I deploy to a PaaS (Triton, Heroku).
@kenany kenany added the windows label Jun 11, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants