C:UsersWakilieDownloadsBoy>npm install
grpc@1.22.2 install C:UsersWakilieDownloadsBoynode_modulesgrpc
node-pre-gyp install —fallback-to-build —library=static_library
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.22.2/node-v83-win32-x64-unknown.tar.gz
node-pre-gyp WARN Pre-built binaries not found for grpc@1.22.2 and node@14.0.0 (node-v83 ABI, unknown) (falling back to source compile with node-gyp)
gyp ERR! find Python
gyp ERR! find Python Python is not set from command line or npm configuration
gyp ERR! find Python Python is not set from environment variable PYTHON
gyp ERR! find Python checking if «python» can be used
gyp ERR! find Python — «python» is not in PATH or produced an error
gyp ERR! find Python checking if «python2» can be used
gyp ERR! find Python — «python2» is not in PATH or produced an error
gyp ERR! find Python checking if «python3» can be used
gyp ERR! find Python — «python3» is not in PATH or produced an error
gyp ERR! find Python checking if the py launcher can be used to find Python 2
gyp ERR! find Python — «py.exe» is not in PATH or produced an error
gyp ERR! find Python checking if Python is C:Python27python.exe
gyp ERR! find Python — «C:Python27python.exe» could not be run
gyp ERR! find Python checking if Python is C:Python37python.exe
gyp ERR! find Python — «C:Python37python.exe» could not be run
gyp ERR! find Python
gyp ERR! find Python **********************************************************
gyp ERR! find Python You need to install the latest version of Python.
gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
gyp ERR! find Python you can try one of the following options:
gyp ERR! find Python — Use the switch —python=»C:PathTopython.exe»
gyp ERR! find Python (accepted by both node-gyp and npm)
gyp ERR! find Python — Set the environment variable PYTHON
gyp ERR! find Python — Set the npm configuration variable python:
gyp ERR! find Python npm config set python «C:PathTopython.exe»
gyp ERR! find Python For more information consult the documentation at:
gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
gyp ERR! find Python **********************************************************
gyp ERR! find Python
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Python installation to use
gyp ERR! stack at PythonFinder.fail (C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gyplibfind-python.js:307:47)
gyp ERR! stack at PythonFinder.runChecks (C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gyplibfind-python.js:136:21)
gyp ERR! stack at PythonFinder. (C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gyplibfind-python.js:225:16)
gyp ERR! stack at PythonFinder.execFileCallback (C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gyplibfind-python.js:271:16)
gyp ERR! stack at exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.errorhandler (child_process.js:322:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:274:12)
gyp ERR! stack at onErrorNT (internal/child_process.js:468:16)
gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:84:21)
gyp ERR! System Windows_NT 10.0.18363
gyp ERR! command «C:Program Filesnodejsnode.exe» «C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js» «configure» «—fallback-to-build» «—library=static_library» «—module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node» «—module_name=grpc_node» «—module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown» «—napi_version=6» «—node_abi_napi=napi» «—napi_build_version=0» «—node_napi_label=node-v83»
gyp ERR! cwd C:UsersWakilieDownloadsBoynode_modulesgrpc
gyp ERR! node -v v14.0.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute ‘C:Program Filesnodejsnode.exe C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js configure —fallback-to-build —library=static_library —module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node —module_name=grpc_node —module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown —napi_version=6 —node_abi_napi=napi —napi_build_version=0 —node_napi_label=node-v83’ (1)
node-pre-gyp ERR! stack at ChildProcess. (C:UsersWakilieDownloadsBoynode_modulesgrpcnode_modulesnode-pre-gyplibutilcompile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:315:20)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1051:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
node-pre-gyp ERR! System Windows_NT 10.0.18363
node-pre-gyp ERR! command «C:Program Filesnodejsnode.exe» «C:UsersWakilieDownloadsBoynode_modulesgrpcnode_modulesnode-pre-gypbinnode-pre-gyp» «install» «—fallback-to-build» «—library=static_library»
node-pre-gyp ERR! cwd C:UsersWakilieDownloadsBoynode_modulesgrpc
node-pre-gyp ERR! node -v v14.0.0
node-pre-gyp ERR! node-pre-gyp -v v0.13.0
node-pre-gyp ERR! not ok
Failed to execute ‘C:Program Filesnodejsnode.exe C:Program Filesnodejsnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js configure —fallback-to-build —library=static_library —module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node —module_name=grpc_node —module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown —napi_version=6 —node_abi_napi=napi —napi_build_version=0 —node_napi_label=node-v83’ (1)
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modulesfsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {«os»:»darwin»,»arch»:»any»} (current: {«os»:»win32″,»arch»:»x64″})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.22.2 install: node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.22.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:UsersWakilieAppDataRoamingnpm-cache_logs2020-07-10T18_34_12_204Z-debug.log
C:UsersWakilieDownloadsBoy>npm install -g npm
C:UsersWakilieAppDataRoamingnpmnpm -> C:UsersWakilieAppDataRoamingnpmnode_modulesnpmbinnpm-cli.js
C:UsersWakilieAppDataRoamingnpmnpx -> C:UsersWakilieAppDataRoamingnpmnode_modulesnpmbinnpx-cli.js
- npm@6.14.6
added 435 packages from 877 contributors in 75.236s
C:UsersWakilieDownloadsBoy>npm install
grpc@1.22.2 install C:UsersWakilieDownloadsBoynode_modulesgrpc
node-pre-gyp install —fallback-to-build —library=static_library
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp WARN Tried to download(404): https://node-precompiled-binaries.grpc.io/grpc/v1.22.2/node-v83-win32-x64-unknown.tar.gz
node-pre-gyp WARN Pre-built binaries not found for grpc@1.22.2 and node@14.0.0 (node-v83 ABI, unknown) (falling back to source compile with node-gyp)
gyp ERR! find Python
gyp ERR! find Python Python is not set from command line or npm configuration
gyp ERR! find Python Python is not set from environment variable PYTHON
gyp ERR! find Python checking if «python» can be used
gyp ERR! find Python — «python» is not in PATH or produced an error
gyp ERR! find Python checking if «python2» can be used
gyp ERR! find Python — «python2» is not in PATH or produced an error
gyp ERR! find Python checking if «python3» can be used
gyp ERR! find Python — «python3» is not in PATH or produced an error
gyp ERR! find Python checking if the py launcher can be used to find Python 2
gyp ERR! find Python — «py.exe» is not in PATH or produced an error
gyp ERR! find Python checking if Python is C:Python27python.exe
gyp ERR! find Python — «C:Python27python.exe» could not be run
gyp ERR! find Python checking if Python is C:Python37python.exe
gyp ERR! find Python — «C:Python37python.exe» could not be run
gyp ERR! find Python
gyp ERR! find Python **********************************************************
gyp ERR! find Python You need to install the latest version of Python.
gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
gyp ERR! find Python you can try one of the following options:
gyp ERR! find Python — Use the switch —python=»C:PathTopython.exe»
gyp ERR! find Python (accepted by both node-gyp and npm)
gyp ERR! find Python — Set the environment variable PYTHON
gyp ERR! find Python — Set the npm configuration variable python:
gyp ERR! find Python npm config set python «C:PathTopython.exe»
gyp ERR! find Python For more information consult the documentation at:
gyp ERR! find Python https://github.com/nodejs/node-gyp#installation
gyp ERR! find Python **********************************************************
gyp ERR! find Python
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Python installation to use
gyp ERR! stack at PythonFinder.fail (C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gyplibfind-python.js:307:47)
gyp ERR! stack at PythonFinder.runChecks (C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gyplibfind-python.js:136:21)
gyp ERR! stack at PythonFinder. (C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gyplibfind-python.js:225:16)
gyp ERR! stack at PythonFinder.execFileCallback (C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gyplibfind-python.js:271:16)
gyp ERR! stack at exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.errorhandler (child_process.js:322:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:274:12)
gyp ERR! stack at onErrorNT (internal/child_process.js:468:16)
gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:84:21)
gyp ERR! System Windows_NT 10.0.18363
gyp ERR! command «C:Program Filesnodejsnode.exe» «C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js» «configure» «—fallback-to-build» «—library=static_library» «—module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node» «—module_name=grpc_node» «—module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown» «—napi_version=6» «—node_abi_napi=napi» «—napi_build_version=0» «—node_napi_label=node-v83»
gyp ERR! cwd C:UsersWakilieDownloadsBoynode_modulesgrpc
gyp ERR! node -v v14.0.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute ‘C:Program Filesnodejsnode.exe C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js configure —fallback-to-build —library=static_library —module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node —module_name=grpc_node —module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown —napi_version=6 —node_abi_napi=napi —napi_build_version=0 —node_napi_label=node-v83’ (1)
node-pre-gyp ERR! stack at ChildProcess. (C:UsersWakilieDownloadsBoynode_modulesgrpcnode_modulesnode-pre-gyplibutilcompile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:315:20)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1051:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:287:5)
node-pre-gyp ERR! System Windows_NT 10.0.18363
node-pre-gyp ERR! command «C:Program Filesnodejsnode.exe» «C:UsersWakilieDownloadsBoynode_modulesgrpcnode_modulesnode-pre-gypbinnode-pre-gyp» «install» «—fallback-to-build» «—library=static_library»
node-pre-gyp ERR! cwd C:UsersWakilieDownloadsBoynode_modulesgrpc
node-pre-gyp ERR! node -v v14.0.0
node-pre-gyp ERR! node-pre-gyp -v v0.13.0
node-pre-gyp ERR! not ok
Failed to execute ‘C:Program Filesnodejsnode.exe C:UsersWakilieAppDataRoamingnpmnode_modulesnpmnode_modulesnode-gypbinnode-gyp.js configure —fallback-to-build —library=static_library —module=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknowngrpc_node.node —module_name=grpc_node —module_path=C:UsersWakilieDownloadsBoynode_modulesgrpcsrcnodeextension_binarynode-v83-win32-x64-unknown —napi_version=6 —node_abi_napi=napi —napi_build_version=0 —node_napi_label=node-v83’ (1)
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modulesfsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {«os»:»darwin»,»arch»:»any»} (current: {«os»:»win32″,»arch»:»x64″})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.22.2 install: node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.22.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:UsersWakilieAppDataRoamingnp
Hello Guys, How are you all? Hope You all Are Fine. Today I Just want to use bcrypt in my nodejs project but as I added bcrypt to my package.json I am facing following error Error: Could not find any Python installation to use in NodeJS. So Here I am Explain to you all the possible solutions here.
Without wasting your time, Let’s start This Article to Solve This Error.
Contents
- How this Error Occurs ?
- How To Solve Error: Could not find any Python installation to use Error ?
- Solution 1: For Windows users
- Solution 2: For docker
- Solution 3: Use bcryptjs instead of bcrypt
- Summary
How this Error Occurs ?
I Just want to use bcrypt in my nodejs project but as I added bcrypt to my package.json I am facing following error.
gyp ERR! find Python Python is not set from command line or npm configuration
gyp ERR! find Python Python is not set from environment variable PYTHON
gyp ERR! find Python checking if “python” can be used
gyp ERR! find Python You need to install the latest version of Python.
gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
gyp ERR! find Python you can try one of the following options:
gyp ERR! configure error gyp ERR! stack Error: Could not find any Python installation to use
- How To Solve Error: Could not find any Python installation to use Error ?
To Solve Error: Could not find any Python installation to use Error If You are using windows and You are facing this error then Just run this command administrator privileges in your cmd: npm install –global –production windows-build-tools Now, your error must be solved. Second solution is Just add this line in your docker file before Npm Install: RUN apk add –update python make g++ && rm -rf /var/cache/apk/*
- Error: Could not find any Python installation to use
To Solve Error: Could not find any Python installation to use Error If You are using windows and You are facing this error then Just run this command administrator privileges in your cmd: npm install –global –production windows-build-tools Now, your error must be solved. Second solution is Just add this line in your docker file before Npm Install: RUN apk add –update python make g++ && rm -rf /var/cache/apk/*
Solution 1: For Windows users
If You are using windows and You are facing this error then Just run this command administrator privileges in your cmd.
npm install --global --production windows-build-tools
Now, your error must be solved.
Solution 2: For docker
Just add this line in your docker file before Npm Install.
RUN apk add --update python make g++
&& rm -rf /var/cache/apk/*
Solution 3: Use bcryptjs instead of bcrypt
Just Use bcryptjs instead of bcrypt.
With bcryptjs there are no errors. Neither with standard node docker images nor node alpine docker images. Now your error should be solved.
Summary
It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you?
Also, Read
- ERROR in ./node_modules/ngx-window-token/fesm2015/ngx-window-token.mjs. Can’t import the named export ‘InjectionToken’ from non EcmaScript module
Dung Do Tien Sep 02 2021 599
Hello, yesterday I was upgraded my project Angular from version 7 to 11 and have some packages conflict.
I tried to use npm audit fix
command to help resolve packages conflict, but I get an exception throw is Error: Could not find any Python installation to use.
npm ERR! gyp ERR! stack Error: Could not find any Python installation to use
npm ERR! gyp ERR! stack at PythonFinder.fail (E:ProjectPhilipMainSource_NewAdminSourceadminDVG.APA.CMSClientnode_modulesnode-gyplibfind-python.js:302:47)
npm ERR! gyp ERR! stack at PythonFinder.runChecks (E:ProjectPhilipMainSource_NewAdminSourceadminDVG.APA.CMSClientnode_modulesnode-gyplibfind-python.js:136:21)
npm ERR! gyp ERR! stack at PythonFinder.<anonymous> (E:ProjectPhilipMainSource_NewAdminSourceadminDVG.APA.CMSClientnode_modulesnode-gyplibfind-python.js:200:18)
npm ERR! gyp ERR! stack at PythonFinder.execFileCallback (E:ProjectPhilipMainSource_NewAdminSourceadminDVG.APA.CMSClientnode_modulesnode-gyplibfind-python.js:266:16)
npm ERR! gyp ERR! stack at exithandler (child_process.js:397:5)
npm ERR! gyp ERR! stack at ChildProcess.errorhandler (child_process.js:409:5)
npm ERR! gyp ERR! stack at ChildProcess.emit (events.js:400:28)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:275:12)
npm ERR! gyp ERR! stack at onErrorNT (internal/child_process.js:467:16)
npm ERR! gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:82:21)
And below is my environment :
Angular CLI: 11.2.14
Node: 14.17.5
OS: win32 x64
Angular: 11.2.14
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, localize, platform-browser
... platform-browser-dynamic, router
Ivy Workspace: Yes
Package Version
---------------------------------------------------------
@angular-devkit/architect 0.1102.14
@angular-devkit/build-angular 0.1102.14
@angular-devkit/core 11.2.14
@angular-devkit/schematics 11.2.14
@angular/cdk 11.2.13
@angular/http 7.2.16
@angular/material 7.3.7
@schematics/angular 11.2.14
@schematics/update 0.1102.14
rxjs 6.6.7
typescript 4.1.6
Thanks for any suggestions.
Have 1 answer(s) found.
-
An Pham Truong
Sep 02 2021You can check your angular.json file and find
node-gyp
package. If installed it. You have to install Python.To install Python you can download from here.
Related Q&A May You Like
- Error: Cannot redeclare block-scoped variable in Typescript
- ReferenceError: $ is not defined in Angular version 11
- ‘rxjs/Observable’ has no exported member ‘Observable’ in Angular
- You seem to not be depending on «@angular/core» and/or «rxjs» in Angular
- Error: PostCSS plugin postcss-discard-comments requires PostCSS 8 in Angular 7
- Error TS1086: An accessor cannot be declared in an ambient context in Angular
- ENOENT: no such file or directory, lstat coreui-icons.css in Angular
- Module not found: Error: Can’t resolve ‘@angular/localize/init’ in Angular
- Error: Cannot find module ‘@angular-devkit/core’ in Angular 9
- TypeError: Cannot read property ‘props’ of undefined in ReactJS
- Can’t bind to ‘ngModel’ since it isn’t a known property of ‘input’ in Angular
- Error: Node Sass does not yet support your current environment in Angular
- Angular 9 throw error «ng: command not found» in MacOS
- Angular: No value accessor for form control with unspecified name attribute
- Angular : If ngModel is used within a form tag, either the name attribute must be set
Leave An Answer
* NOTE: You need Login before leave an answer
* Type maximum 2000 characters.
* All comments have to wait approved before display.
* Please polite comment and respect questions and answers of others.
Today We are Going To Solve Error: Could not find any Python installation to use in Nodejs. Here we will Discuss All Possible Solutions and How this error Occurs So let’s get started with this Article.
Contents
- 1 How to Fix Error: Could not find any Python installation to use Error?
- 1.1 Solution 1 : For window users
- 1.2 Solution 2 : Add the below code in your docker file
- 1.3 Solution 3 : For Alpine
- 2 Conclusion
- 2.1 Also Read These Solutions
- How to Fix Error: Could not find any Python installation to use Error?
To Fix Error: Could not find any Python installation to use Error just For window users. First of all, Open Powershell with administrator privileges and run the below command
npm install --global --production windows-build-tools
And after it go for bcrypt installation. This will helps you. - Error: Could not find any Python installation to use
To Fix Error: Could not find any Python installation to use Error just Add the below code in your docker file. Here you have to just add the below code in your docker file and after it install npm. Just try it.
RUN apk add --update python make g++ && rm -rf /var/cache/apk/*
Solution 1 : For window users
First of all, Open Powershell with administrator privileges and run the below command
npm install --global --production windows-build-tools
And after it go for bcrypt installation. This will helps you.
Solution 2 : Add the below code in your docker file
Here you have to just add the below code in your docker file and after it install npm. Just try it.
RUN apk add --update python make g++
&& rm -rf /var/cache/apk/*
Solution 3 : For Alpine
This is for Alpine. Just run the below command.
RUN apk add --no-cache python3 make g++
Conclusion
So these were all possible solutions to this error. I hope your error has been solved by this article. In the comments, tell us which solution worked? If you liked our article, please share it on your social media and comment on your suggestions. Thank you.
Also Read These Solutions
- org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat servlet container
- Uncaught SyntaxError: Unexpected token o in JSON at position 1
- You may need an additional loader to handle the result of these loaders.
- unrecognized Attribute name MODULE (class com.sun.tools.javac.util.SharedNameTable$NameImpl)
- ERROR: JAVA_HOME is set to an invalid directory
Scenario: after upgrading the node environment, an error is reported when the project version number does not match. After deciding to reinitialize, an error is reported again
Building: G:nodejsnode.exe F:testnode_modulesnode-gypbinnode-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [
gyp verb cli 'G:\nodejs\node.exe',
gyp verb cli 'F:\test\node_modules\node-gyp\bin\node-gyp.js',
gyp verb cli 'rebuild',
gyp verb cli '--verbose',
gyp verb cli '--libsass_ext=',
gyp verb cli '--libsass_cflags=',
gyp verb cli '--libsass_ldflags=',
gyp verb cli '--libsass_library='
gyp verb cli ]
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed at getNotFoundError (F:testnode_moduleswhichwhich.js:13:12)
gyp verb `which` failed at F (F:testnode_moduleswhichwhich.js:68:19)
gyp verb `which` failed at E (F:testnode_moduleswhichwhich.js:80:29)
gyp verb `which` failed at F:testnode_moduleswhichwhich.js:89:16
gyp verb `which` failed at F:testnode_modulesisexeindex.js:42:5
gyp verb `which` failed at F:testnode_modulesisexewindows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:158:21)
gyp verb `which` failed python2 Error: not found: python2
gyp verb `which` failed at getNotFoundError (F:testnode_moduleswhichwhich.js:13:12)
gyp verb `which` failed at F (F:testnode_moduleswhichwhich.js:68:19)
gyp verb `which` failed at E (F:testnode_moduleswhichwhich.js:80:29)
gyp verb `which` failed at F:testnode_moduleswhichwhich.js:89:16
gyp verb `which` failed at F:testnode_modulesisexeindex.js:42:5
gyp verb `which` failed at F:testnode_modulesisexewindows.js:36:5
gyp verb `which` failed at FSReqCallback.oncomplete (fs.js:158:21) {
gyp verb `which` failed stack: 'Error: not found: python2n' +
gyp verb `which` failed ' at getNotFoundError (F:\test\node_modules\which\which.js:13:12)n' +
gyp verb `which` failed ' at F (F:\test\node_modules\which\which.js:68:19)n' +
gyp verb `which` failed ' at E (F:\test\node_modules\which\which.js:80:29)n' +
gyp verb `which` failed ' at F:\test\node_modules\which\which.js:89:16n' +
gyp verb `which` failed ' at F:\test\node_modules\isexe\index.js:42:5n' +
gyp verb `which` failed ' at F:\test\node_modules\isexe\windows.js:36:5n' +
gyp verb `which` failed ' at FSReqCallback.oncomplete (fs.js:158:21)',
gyp verb `which` failed code: 'ENOENT'
gyp verb `which` failed }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` succeeded python G:PythonPython37-32python.EXE
gyp ERR! configure error
gyp ERR! stack Error: Command failed: G:PythonPython37-32python.EXE -c import sys; print "%s.%s.%s" % sys.version_info[:3];
gyp ERR! stack File "<string>", line 1
gyp ERR! stack import sys; print "%s.%s.%s" % sys.version_info[:3];
gyp ERR! stack ^
gyp ERR! stack SyntaxError: invalid syntax
gyp ERR! stack
gyp ERR! stack at ChildProcess.exithandler (child_process.js:295:12)
gyp ERR! stack at ChildProcess.emit (events.js:210:5)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "G:\nodejs\node.exe" "F:\test\node_modules\node-gyp\bin\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsas
s_library="
gyp ERR! cwd F:testnode_modulesnode-sass
gyp ERR! node -v v12.13.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN [email protected] requires a peer of [email protected]^5.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modulesfsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:UsersAdministratorAppDataRoamingnpm-cache_logs2019-11-18T07_33_10_767Z-debug.log
Process finished with exit code 1
The solution for online search is:
npm install --global windows-build-tools --save
But it got stuck when installing windows build tools, so the solution is as follows
1, run npm install -g windows-build-tools
2, in the %temp% folder, find the latest file with a filename similar to dd_installer_20210421124746.log
3, check this file, make sure the log output Closing the installer with exit code 0
4, make sure you have vscode installed
PS: In fact, you can skip steps 2-4, because your python environment has already been installed, and the repeated steps of the installer have already been executed.
5, create a file named dd_client_.log in the %temp% directory
6, edit the file created in 5, add a line Closing installer. return code: 3010. and save it.
Note: Paste %temp% directly in Explorer to open your Windows temp directory.
Finally, NPM install is installed successfully