Node.js 22
Error: The module was compiled against a different Node.js version using NODE_MODULE_VERSION
A precompiled native addon was built for a different Node.js ABI than the one now running.
Native Node addons (sharp, bcrypt, better-sqlite3, canvas, …) are tied to the Node major version's ABI (NODE_MODULE_VERSION). Upgrading the Lambda/container runtime to Node 22 without rebuilding or bumping these packages triggers the mismatch.
Related deadline: Lambda Node.js 20 Phase 1 — 2027-02-01.
The free EOLkits scanner runs in your browser (nothing uploaded) and flags this and related breakages across your IaC and dependency files.
Primary source: https://docs.aws.amazon.com/lambda/latest/dg/lambda-runtimes.html