-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
node 18.14.0 regression: npm config set python python3: npm ERR! python
is not a valid npm option
#6126
Comments
I just ran in an similar issue setting the value tarball with npm 9.3.1 |
Anyone have a workaround other than downgrading npm? |
Here is the line that introduced the breaking change: be642c6#diff-9d8a792f1506f5f271be6e040eb80022ba16209ea7888dd8addd068e779b7e36R163 The first version with this breaking change is The breaking change was documented here: https://github.com/npm/cli/releases/tag/v9.0.0 |
Looks like Node justifies breaking changes in semver minor releases because of a guideline document that exists in the Anyway, if these changes are to be believed, |
Looks like the config option is used by node-gyp: https://github.com/nodejs/node-gyp/tree/v9.3.1#configuring-python-dependency |
* Add Python 3.12 beta 1 to testing * Use packaging instead of distutils * Ignore PLR1714 for now * Add packaging as a dependency * Install Python dependencies in CI * Add another install command * Try setting env var * Rework pwsh script * Try using batch * use npm config set * Work around npm/cli#6126 * Pass file rather than directory * Remove gyp-next self-install * uninstall, not remove * Add -y * Ignore the latest lint rules --------- Co-authored-by: Christian Clauss <cclauss@me.com>
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
Running:
npm config set python python3
Results in this error:
Expected Behavior
There shouldn't be any error; it should work. See documentation: https://docs.npmjs.com/cli/v9/commands/npm-config?v=true#set
This worked as expected and documented until node 18.14.0, in which version this unexpected behavior began.
Steps To Reproduce
docker run -it --entrypoint /bin/bash node:18.14.0
npm config set python python3
and see the aforementioned errorEnvironment
The text was updated successfully, but these errors were encountered: