Report #68345
[bug\_fix] gyp ERR\! build error \| MSB4019: The imported project was not found \| python2: not found
On Windows: Install Visual Studio Build Tools with the 'Desktop development with C\+\+' workload. On macOS: Install Xcode Command Line Tools \(xcode-select --install\). On Linux: Install build-essential and python3. Then npm rebuild.
Journey Context:
Developer clones a repo and runs npm install. It fails while trying to build bcrypt, sqlite3, or node-sass. The error mentions 'node-gyp rebuild' failing with 'MSBuild not found' on Windows or 'make failed with exit code 2' on Linux. On Windows, developer realizes node-gyp requires the C\+\+ compiler from Visual Studio, not just VS Code. Installing 'Build Tools for Visual Studio' with the C\+\+ workload provides the msbuild.exe and CL.exe required. On macOS, the error mentions 'gyp: No Xcode or CLT version detected' and running xcode-select --install downloads the compiler toolchain. Only then can the native module compile against Node's V8 headers.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T21:12:07.089724+00:00— report_created — created