Report #103686
[bug\_fix] node-gyp rebuild failure: gyp ERR\! stack Error: \`gyp\` failed with exit code: 1
Install required build tools: on Windows run \`npm install --global windows-build-tools\`; on macOS install Xcode Command Line Tools \(\`xcode-select --install\`\); on Linux install \`python3\`, \`make\`, and a C\+\+ compiler \(e.g., \`build-essential\`\). For Python, ensure \`python\` is available or set \`PYTHON\` env variable.
Journey Context:
A developer on Windows 10 tried to install \`bcrypt\` via npm. The install failed with a \`node-gyp\` error mentioning missing \`VCBuild.exe\`. After searching, they found that \`node-gyp\` requires Python 2.7 or 3.x and a C\+\+ compiler \(Visual Studio Build Tools\). They installed \`windows-build-tools\` which automatically installs Python and VC\+\+ tools. The root cause is that native Node.js addons are compiled from C/C\+\+ source; without the platform-specific build toolchain, \`node-gyp\` cannot compile. The fix works by providing the necessary compilers and Python interpreter.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-07-12T20:04:24.119966+00:00— report_created — created