-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Why do I need Python? #1176
Comments
bufferutil is not required by node-sass. You need Python and a C++ to be able to compile native modules. Normally node-sass fetches the binary for you, if you are on a supported platform - as you see above, it downloaded fine. But your particular problem is about https://github.com/websockets/bufferutil and not node-sass. |
My apologies. |
No problem! I hope you got it working anyway. |
Well since this was a royal pain and this is the first Google result... Here goes nothing. If you keep getting errors on Ubuntu about python3 and python2.7 is installed and passing familiar python3 error
less familiar error with the suggested --python "fix"
"node-sass": "4.5.3" |
Native Node JS extensions like node-sass are compiled via npm which uses node-gyp. Python is required by node-gyp. We supply a bunch of precompiled binaries with out releases so you don't have to compile them yourself. During the npm install process a binary is downloaded for your system. If you're on a system we haven't pre-compiled binaries for then npm will try to compile it for you, which is where python comes in. Since you're one linux there should be a binary for you. This likely means you're running very old version of node-sass. You should always update to the latest version of a package. Please open a new issue if you continue to encounter errors with [email protected]. |
I'm getting the same error on Windows 10 x64. That should probably be one of the precompiled binaries considering how common it is. |
Using the --force flag will compile the binary locally which is why you need python. Rebuild without force should fetch the appropriate binary if it's not already present locally. |
@phawxby your issue is unrelated. You're likely using an old version of node-sass with node 8. Update to 4.5.3. |
You are correct. For some reason I was stuck on 4.5.2 |
I get the following output when installing [email protected]:
Do I really have to install Python, or is this a bug?
The text was updated successfully, but these errors were encountered: