-
Notifications
You must be signed in to change notification settings - Fork 45
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
Error running npm install #49
Comments
+1 |
Your first error says:
So check that you have python installed and set up correctly. The second error says:
I'm guessing you are using VS2017? It looks like support for that version was added in node-gyp 3.6.0, so try upgrading your node-gyp. |
Here is my challenge... this is for a web application. Why python would be needed for whatever javascript library is using is it concerning. Ignoring that, I just tried to install that specific version of node-gyp (which is a dependency for who knows what library I'm importing) and get this:
|
I think you probably need to open a ticket on https://github.com/nodejs/node-gyp because it appears your error is happening in there, before the build steps really get to this library. |
For posterity: nodejs/node-gyp#1195 |
I still think this might be an issue with microtime, here is the error I have:
|
@ukphillips The key error in there is:
Without CL.exe, no native modules can be built. Please install the required tools listed here: https://github.com/nodejs/node-gyp#installation (see the Windows section). |
+1 |
I think the issue that affected everyone here is browserify/pbkdf2@ad53c33. That bump essentially screwed over everyone using browserify. I can verify that running the following in an elevated CMD works on Windows (after installing Python 2.7 and setting %PYTHON%):
|
@im1dermike Native node modules use the GYP build system, which is written in Python. If you're using |
@cadsit the latest version of pbkdf2 has microtime listed as an https://github.com/crypto-browserify/pbkdf2/blob/v3.0.11/package.json#L57-L59 |
I second @cadsit's findings. We also initially worked around this breakage by pinning pbkdf2 to an older version: "devDependencies": {
"pbkdf2": "=3.0.9"
} Basically, https://github.com/crypto-browserify/pbkdf2, should have done a larger version bump due to the build implications (@calvinmetcalf). @wadey it's specified as optional on GitHub but it's definitely not optional in npm. From "dependencies": {
"create-hash": "^1.1.2",
"create-hmac": "^1.1.4",
"microtime": "^2.1.3",
"ripemd160": "^2.0.1",
"safe-buffer": "^5.0.1",
"sha.js": "^2.4.8"
}, |
There are also a number of issues already opened about this against pbkdf2. This issue should probably be closed since it's not specifically @wadey's issue. |
and we're fixed |
I'm still relatively new to npm - while this did fix my issue, I'm having a hard time grasping how the change resolved (and created) the problem. pbkdf2 from looking at the dependencies depends on microtime - how did making a change to pbkdf2 affect the ability to install microtime? |
@ukphillips your computer is not set up to compile and build any native C++ modules (like microtime). You didn't notice before because nothing in your project used native modules, but when pbkdf2 added microtime as a dependency you encountered your first native module. So the answer is, your computer could never install microtime, you just didn't notice before. If you want to install native modules, you need to follow these steps: https://github.com/nodejs/node-gyp#installation I just re-ran the automated builds and microtime builds on windows for all current versions of Node.js: https://ci.appveyor.com/project/WadeSimmons/node-microtime/build/88 |
I removed microtime from the pbkdf2 dependencies so that now you were no longer trying to install it |
FYI to everyone that had issues here. The latest release (2.1.4) of microtime now uses node-pre-gyp to provide pre-built binaries for Windows users. |
I can`t understand it.... |
I've also got the similar error when I tried installing vue-funnel-graph-js package in nuxt. I've searched a lot but didn't find a proper solution. I've also tried both with python3 and python2 but still won't work. |
Today, I started getting errors when running
npm install
on my solution. The error referenced "microtime" which I assume is a dependency of one of my packages. This was the original error:I did some researching and trying of suggested solutions. I believe at some point I ran
npm install -g node-gyp
. Now when I try to runnpm install microtime@latest
, I get the following error:The text was updated successfully, but these errors were encountered: