-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Could not find any Visual Studio installation to use after trying all the tips I could find online #2203
Comments
I've nuked my entire nodejs installation and started over, but the problem persists. ReproI've nuked my entire nodejs installation and started over. What I've done
me@me-PC0 D:\Desktop
$ npx create-electron-app myapp
√ Initializing Project Directory
√ Initializing Git Repository
√ Locating custom template: "base"
√ Copying Starter Files
√ Initializing NPM Module
√ Installing Template Dependencies
√ Installing NPM Dependencies
me@me-PC0 D:\Desktop
$ cd myapp
me@me-PC0 D:\Desktop\myapp
$ npm start
> myapp@1.0.0 start D:\Desktop\myapp
> electron-forge start
√ Checking your system
√ Locating Application
√ Preparing native dependencies
√ Launching Application
The app runs up until this point. Then ...
$ npm install zeromq --save-prod
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\extract-zip.cmd as it wasn't installed by D:\Desktop\myapp\node_modules\extract-zip
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\extract-zip as it wasn't installed by D:\Desktop\myapp\node_modules\extract-zip
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\rimraf.cmd as it wasn't installed by D:\Desktop\myapp\node_modules\rimraf
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\rimraf as it wasn't installed by D:\Desktop\myapp\node_modules\rimraf
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\semver.cmd as it wasn't installed by D:\Desktop\myapp\node_modules\semver
npm WARN rm not removing D:\Desktop\myapp\node_modules\.bin\semver as it wasn't installed by D:\Desktop\myapp\node_modules\semver
> zeromq@6.0.0-beta.6 install D:\Desktop\myapp\node_modules\zeromq
> node-gyp-build
> core-js@3.6.5 postinstall D:\Desktop\myapp\node_modules\core-js
> node -e "try{require('./postinstall')}catch(e){}"
Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library!
The project needs your help! Please consider supporting of core-js on Open Collective or Patreon:
> https://opencollective.com/core-js
> https://www.patreon.com/zloirock
Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -)
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: electron-installer-debian@^3.0.0 (node_modules\@electron-forge\maker-deb\node_modules\electron-installer-debian):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for electron-installer-debian@3.1.0: wanted {"os":"darwin,linux","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: electron-installer-redhat@^3.2.0 (node_modules\@electron-forge\maker-rpm\node_modules\electron-installer-redhat):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for electron-installer-redhat@3.2.0: wanted {"os":"darwin,linux","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN myapp@1.0.0 No repository field.
+ zeromq@6.0.0-beta.6
added 50 packages from 7 contributors, removed 32 packages, updated 401 packages and audited 460 packages in 61.306s
32 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
$ npm run make
> myapp@1.0.0 make D:\Desktop\myapp
> electron-forge make
√ Checking your system
√ Resolving Forge Config
We need to package your application before we can make it
√ Preparing to Package Application for arch: x64
× Preparing native dependencies: 0 / 1
An unhandled error has occurred inside Forge:
Command failed with a non-zero return code (1):
D:\Desktop\myapp\node_modules\electron-rebuild\node_modules\.bin\node-gyp.cmd rebuild --target=10.1.0 --arch=x64 --dist-url=https://www.electronjs.org/headers --build-from-source
gyp ERR! find VS
gyp ERR! find VS msvs_version was set from command line or npm config
gyp ERR! find VS - looking for Visual Studio version 2017
gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - found in "C:\Program Files (x86)\Microsoft Visual Studio 14.0"
gyp ERR! find VS - could not find MSBuild in registry for this version
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS
gyp ERR! find VS valid versions for msvs_version:
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack at VisualStudioFinder.fail (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:121:47)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:74:16
gyp ERR! stack at VisualStudioFinder.findVisualStudio2013 (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:351:14)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:70:14
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:384:20
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:54:7
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:33:16
gyp ERR! stack at ChildProcess.exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Desktop\\myapp\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=10.1.0" "--arch=x64" "--dist-url=https://www.electronjs.org/headers" "--build-from-source"
gyp ERR! cwd C:\Users\me\AppData\Local\Temp\electron-packager\win32-x64\myapp-win32-x64\resources\app\node_modules\zeromq
gyp ERR! node -v v12.18.3
gyp ERR! node-gyp -v v7.1.0
gyp ERR! not ok
Error: Command failed with a non-zero return code (1):
D:\Desktop\myapp\node_modules\electron-rebuild\node_modules\.bin\node-gyp.cmd rebuild --target=10.1.0 --arch=x64 --dist-url=https://www.electronjs.org/headers --build-from-source
gyp ERR! find VS
gyp ERR! find VS msvs_version was set from command line or npm config
gyp ERR! find VS - looking for Visual Studio version 2017
gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - found in "C:\Program Files (x86)\Microsoft Visual Studio 14.0"
gyp ERR! find VS - could not find MSBuild in registry for this version
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS
gyp ERR! find VS valid versions for msvs_version:
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack at VisualStudioFinder.fail (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:121:47)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:74:16
gyp ERR! stack at VisualStudioFinder.findVisualStudio2013 (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:351:14)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:70:14
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:384:20
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:54:7
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:33:16
gyp ERR! stack at ChildProcess.exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Desktop\\myapp\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=10.1.0" "--arch=x64" "--dist-url=https://www.electronjs.org/headers" "--build-from-source"
gyp ERR! cwd C:\Users\me\AppData\Local\Temp\electron-packager\win32-x64\myapp-win32-x64\resources\app\node_modules\zeromq
gyp ERR! node -v v12.18.3
gyp ERR! node-gyp -v v7.1.0
gyp ERR! not ok
at ChildProcess.<anonymous> (D:\Desktop\myapp\node_modules\@malept\cross-spawn-promise\src\index.ts:155:16)
at ChildProcess.emit (events.js:315:20)
at ChildProcess.EventEmitter.emit (domain.js:483:12)
at ChildProcess.cp.emit (D:\Desktop\myapp\node_modules\cross-spawn\lib\enoent.js:34:29)
at maybeClose (internal/child_process.js:1021:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! myapp@1.0.0 make: `electron-forge make`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the myapp@1.0.0 make 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:\Users\me\AppData\Roaming\npm-cache\_logs\2020-08-28T04_35_43_345Z-debug.log
set VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\
D:\Desktop\myapp>npm run make
> myapp@1.0.0 make D:\Desktop\myapp
> electron-forge make
√ Checking your system
√ Resolving Forge Config
We need to package your application before we can make it
√ Preparing to Package Application for arch: x64
× Preparing native dependencies: 0 / 1
An unhandled error has occurred inside Forge:
Command failed with a non-zero return code (1):
D:\Desktop\myapp\node_modules\electron-rebuild\node_modules\.bin\node-gyp.cmd rebuild --target=10.1.0 --arch=x64 --dist-url=https://www.electronjs.org/headers --build-from-source
gyp ERR! find VS
gyp ERR! find VS msvs_version was set from command line or npm config
gyp ERR! find VS - looking for Visual Studio version 2017
gyp ERR! find VS running in VS Command Prompt, installation path is:
gyp ERR! find VS "C:\Program Files (x86)\Microsoft Visual Studio\2017"
gyp ERR! find VS - will only use this version
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - found in "C:\Program Files (x86)\Microsoft Visual Studio 14.0"
gyp ERR! find VS - could not find MSBuild in registry for this version
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS msvs_version does not match this VS Command Prompt or the
gyp ERR! find VS installation cannot be used.
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack at VisualStudioFinder.fail (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:121:47)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:74:16
gyp ERR! stack at VisualStudioFinder.findVisualStudio2013 (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:351:14)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:70:14
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:384:20
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:54:7
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:33:16
gyp ERR! stack at ChildProcess.exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Desktop\\myapp\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=10.1.0" "--arch=x64" "--dist-url=https://www.electronjs.org/headers" "--build-from-source"
gyp ERR! cwd C:\Users\me\AppData\Local\Temp\electron-packager\win32-x64\myapp-win32-x64\resources\app\node_modules\zeromq
gyp ERR! node -v v12.18.3
gyp ERR! node-gyp -v v7.1.0
gyp ERR! not ok
Error: Command failed with a non-zero return code (1):
D:\Desktop\myapp\node_modules\electron-rebuild\node_modules\.bin\node-gyp.cmd rebuild --target=10.1.0 --arch=x64 --dist-url=https://www.electronjs.org/headers --build-from-source
gyp ERR! find VS
gyp ERR! find VS msvs_version was set from command line or npm config
gyp ERR! find VS - looking for Visual Studio version 2017
gyp ERR! find VS running in VS Command Prompt, installation path is:
gyp ERR! find VS "C:\Program Files (x86)\Microsoft Visual Studio\2017"
gyp ERR! find VS - will only use this version
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - found in "C:\Program Files (x86)\Microsoft Visual Studio 14.0"
gyp ERR! find VS - could not find MSBuild in registry for this version
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS msvs_version does not match this VS Command Prompt or the
gyp ERR! find VS installation cannot be used.
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack at VisualStudioFinder.fail (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:121:47)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:74:16
gyp ERR! stack at VisualStudioFinder.findVisualStudio2013 (D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:351:14)
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:70:14
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\find-visualstudio.js:384:20
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:54:7
gyp ERR! stack at D:\Desktop\myapp\node_modules\node-gyp\lib\util.js:33:16
gyp ERR! stack at ChildProcess.exithandler (child_process.js:310:5)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! System Windows_NT 10.0.18362
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Desktop\\myapp\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--target=10.1.0" "--arch=x64" "--dist-url=https://www.electronjs.org/headers" "--build-from-source"
gyp ERR! cwd C:\Users\me\AppData\Local\Temp\electron-packager\win32-x64\myapp-win32-x64\resources\app\node_modules\zeromq
gyp ERR! node -v v12.18.3
gyp ERR! node-gyp -v v7.1.0
gyp ERR! not ok
at ChildProcess.<anonymous> (D:\Desktop\myapp\node_modules\@malept\cross-spawn-promise\src\index.ts:155:16)
at ChildProcess.emit (events.js:315:20)
at ChildProcess.EventEmitter.emit (domain.js:483:12)
at ChildProcess.cp.emit (D:\Desktop\myapp\node_modules\cross-spawn\lib\enoent.js:34:29)
at maybeClose (internal/child_process.js:1021:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! myapp@1.0.0 make: `electron-forge make`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the myapp@1.0.0 make 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:\Users\me\AppData\Roaming\npm-cache\_logs\2020-08-28T04_40_16_364Z-debug.log
if (versionYear === 2017) {
return path.join(info.path, 'MSBuild', '15.0', 'Bin', 'MSBuild.exe')
}
if (versionYear === 2019) {
return path.join(info.path, 'MSBuild', 'Current', 'Bin', 'MSBuild.exe')
}
if (versionYear === 2017) {
return path.join(info.path, 'MSBuild', '15.0', 'Bin', 'amd64', 'MSBuild.exe')
}
if (versionYear === 2019) {
return path.join(info.path, 'MSBuild', 'Current', 'Bin', 'amd64', 'MSBuild.exe')
}
Here is my build environment D:\Desktop\myapp>npm config get msvs_version
2017
D:\Desktop\myapp>npm config get python
C:\Python\Python38\pythonw.exe Python 3.8 is the 64bit version from python.org. QuestionWhat am I missing? Should I forget about VS2017? My project uses VS2017 for the C++ development so I'm afraid I can't change that. But should I install VS2015? It's confusing that on node-gyp
Then later in
What's with this version discrepancy? |
I also had similar issues recently and what helped me to locate the issue was running the npm command with My issue was that there were some outdated (non-existing) paths in my LIB environment variable and that made node-gyp fail. |
Thanks for the tip. Indeed, I shared the exact problem with you. I found out about it myself weeks ago the hard way and I really should've used |
|
@anujxx Check out initram's answer above. |
A little late, but if it helps anyone: |
Deleting the package-lock.json file resolved the problem for me. As far as I can tell, no |
Did the work thanks! |
WORKED FOR ME AFTER TRYING EVERYTHING! Just had to delete the |
did anything happen after deleting that file? |
Ran into this pretty recently. Completely reinstalling Visual Studio cleared it up. |
@DeuxAlpha Appreciate it, Man! |
Just follow the instructions at https://github.com/nodejs/node-gyp#on-windows like the error output suggests |
@lsharir thank you, this was my problem too. gyp ERR! find VS
gyp ERR! find VS msvs_version was set from command line or npm config
gyp ERR! find VS - looking for Visual Studio version 2017
gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
gyp ERR! find VS checking VS2019 (16.10.31424.327) found at:
gyp ERR! find VS "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools"
gyp ERR! find VS - found "Visual Studio C++ core features"
gyp ERR! find VS - found VC++ toolset: v142
gyp ERR! find VS - found Windows SDK: 10.0.19041.0
gyp ERR! find VS - msvs_version does not match this version
gyp ERR! find VS checking VS2019 (16.10.31424.327) found at:
gyp ERR! find VS "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community"
gyp ERR! find VS - found "Visual Studio C++ core features"
gyp ERR! find VS - found VC++ toolset: v142
gyp ERR! find VS - found Windows SDK: 10.0.19041.0
gyp ERR! find VS - msvs_version does not match this version
gyp ERR! find VS could not find a version of Visual Studio 2017 or newer to use
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - not found
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS
gyp ERR! find VS valid versions for msvs_version:
gyp ERR! find VS - "2019"
gyp ERR! find VS - "C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools"
gyp ERR! find VS - "2019"
gyp ERR! find VS - "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community"
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the "Desktop development with C++" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack at VisualStudioFinder.fail (C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\find-visualstudio.js:121:47)
gyp ERR! stack at C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\find-visualstudio.js:74:16
gyp ERR! stack at VisualStudioFinder.findVisualStudio2013 (C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\find-visualstudio.js:351:14)
gyp ERR! stack at C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\find-visualstudio.js:70:14
gyp ERR! stack at C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\find-visualstudio.js:372:16
gyp ERR! stack at C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\util.js:54:7
gyp ERR! stack at C:\Users\...\AppData\Roaming\nvm\v12.22.1\node_modules\npm\node_modules\node-gyp\lib\util.js:33:16
gyp ERR! stack at ChildProcess.exithandler (child_process.js:315:5)
gyp ERR! stack at ChildProcess.emit (events.js:314:20)
gyp ERR! stack at maybeClose (internal/child_process.js:1022:16)
gyp ERR! System Windows_NT 10.0.19043
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\...\\AppData\\Roaming\\nvm\\v12.22.1\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" |
on my computer works with the next commands |
Indeed, this appears to be a cross-platform issue and regenerating I have two machines, one running Ubuntu the other Windows. The former generated that file and I didn't encounter any issue. However when I tried installing the modules on the latter, that's when the issue occurred. |
I have tried every solution on this issue, but I am getting the same error. Can someone help me? |
In your error log, what is the version on the line that starts with Is it the same version as https://github.com/nodejs/node-gyp/releases ? |
Came across exact same issue when trying to install
|
Tried to install it inside Noticed I have But still, I can't get its running on PowerShell Is this line
really means I have to run in Elevated VS Developer Shell? |
@feryardiant Running via a Powershell launched from VS 2022's Tools > Command line > Dev powershell is what finally got it working for me once I got to this point |
node -v
=v12.18.3 andnpm -v
=6.14.8systeminfo | findstr /B /C:"OS Name" /C:"OS Version" /C:"System Type"
(Windows)msbuild /version & cl
(Windows)Verbose output (from npm or node-gyp):
Things I've tried to no avail
Desktop Development Kit for C++
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\
npm config set msvs_version 2017 --global
, thennpm config get msvs_version
gives me 2017I got the same errors as above every step of the way.
Please help!
The text was updated successfully, but these errors were encountered: