Report #44740
[bug\_fix] NODE\_MODULE\_VERSION mismatch. This version of Node.js requires NODE\_MODULE\_VERSION 93
Run \`npm rebuild\` to recompile native addons for the current Node version, or delete \`node\_modules\` and \`package-lock.json\` and run \`npm install\` fresh. For Electron, use \`electron-rebuild\`. Root cause: Native C\+\+ addons are compiled against a specific Node ABI \(Application Binary Interface\) version; when switching Node versions \(e.g., 14.x ABI 83 to 16.x ABI 93\), the existing binary \`.node\` files are incompatible and must be recompiled against the new V8 headers.
Journey Context:
Developer switches Node versions using \`nvm use 16\` \(or upgrades the project Node version\). Running the app immediately crashes with "Error: The module was compiled against a different Node.js version... NODE\_MODULE\_VERSION 83 vs 93". The error points to \`bcrypt.node\` or \`sharp.node\`. Developer tries \`npm install\` again but it says everything is up to date because package-lock.json references compatible versions, not ABI. Developer realizes that \`npm install\` doesn't check ABI compatibility, only package versions. They run \`npm rebuild\` which iterates through all packages with \`binding.gyp\` and recompiles them using the current Node's headers via node-gyp. The error disappears. Alternatively, they nuke node\_modules and reinstall, which also triggers compilation. In an Electron app, they must use \`electron-rebuild\` because Electron uses a different ABI than the system Node.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T05:33:52.037571+00:00— report_created — created