"Can't find Python executable" when I tried to install an angular 2 application.

Dear experts here, I am learning angular 2 these days. When I tied to run "npm install" on an angular 2 application for displaying a slider document, it threw me into an error about python. I have two versions of python installed, how could I set up %PYTHON% PARAMETER?

THANKS.


C:\angular-training-slides\slides\node_modules\bufferutil>if not defined npm_config_node_gyp (node "C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "C:UsersjyuAppDataLocalProgramsPythonPython35python.EXE", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:454:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:480:16)
gyp ERR! stack     at C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:114:15)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\jyu\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\angular-training-slides\slides\node_modules\bufferutil
gyp ERR! node -v v7.7.4
gyp ERR! node-gyp -v v3.5.0
gyp ERR! not ok

> utf-8-validate@1.2.2 install C:\angular-training-slides\slides\node_modules\utf-8-validate
> node-gyp rebuild


C:\angular-training-slides\slides\node_modules\utf-8-validate>if not defined npm_config_node_gyp (node "C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "" rebuild )
gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "C:UsersjyuAppDataLocalProgramsPythonPython35python.EXE", you can set the PYTHON env variable.
gyp ERR! stack     at PythonFinder.failNoPython (C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:454:19)
gyp ERR! stack     at PythonFinder.<anonymous> (C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\configure.js:480:16)
gyp ERR! stack     at C:\Users\jyu\AppData\Roaming\npm\node_modules\npm\node_modules\graceful-fs\polyfills.js:284:29
gyp ERR! stack     at FSReqWrap.oncomplete (fs.js:114:15)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\jyu\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\angular-training-slides\slides\node_modules\utf-8-validate
gyp ERR! node -v v7.7.4
gyp ERR! node-gyp -v v3.5.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules\chokidar\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.1: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: bufferutil@1.2.1 (node_modules\bufferutil):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: bufferutil@1.2.1 install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: utf-8-validate@1.2.2 (node_modules\utf-8-validate):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: utf-8-validate@1.2.2 install: `node-gyp rebuild`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

Open in new window

Jason YuAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

TomMicrosoft ISV PartnerCommented:
Is Phyton in your environment variables? You need to tell windows where to find Phyton (folder name)

Environment variables can be accessed from “Advanced system settings” on the left side of the “System” control panel. How you access and edit the environment variables depends on the version of Windows you are using.

Windows 10 (Also Windows 8.1)

Right-click on the Start Button
Select “System” from the context menu.
Click “Advanced system settings”
Go to the “Advanced” tab
Click “Environment Variables…”
Click variable called “Path” and click “Edit…”
Click “New”
Enter the path to the folder containing the binary you want on your PATH. Separate with ;
Click “OK” to save the changes to your variables and restart your computer for the changes to take effect.

Windows 7 (Also Windows Vista)

Right-click on the My Computer icon on the right side of the Start Menu.
Click “Properties” from the context menu.
Click “Advanced system settings”
Go to the “Advanced” tab
Click “Environment Variables…”
Click variable called “Path” and click “Edit…”
Add the path to the folder containing the binary to the end of the value in your PATH variable.
Separate with ;
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Seth SimmonsSr. Systems AdministratorCommented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.

I have recommended this question be closed as follows:

Accept: Tom (https:#a42283286)

If you feel this question should be closed differently, post an objection and the moderators will review all objections and close it as they feel fit. If no one objects, this question will be closed automatically the way described above.

seth2740
Experts-Exchange Cleanup Volunteer
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Python

From novice to tech pro — start learning today.