vercelsveltekit

SvelteKit build on Vercel E401


When I try to build my SvelteKit app to Vercel I get the following

npm ERR! code E401
npm ERR! Incorrect or missing password.
npm ERR! If you were trying to login, change your password, create an
npm ERR! authentication token or enable two-factor authentication then
npm ERR! that means you likely typed your password in incorrectly.
npm ERR! Please try again, or recover your password at:
npm ERR!     https://www.npmjs.com/forgot
npm ERR! 
npm ERR! If you were doing some other operation then your saved credentials are
npm ERR! probably out of date. To correct this please try logging in again with:
npm ERR!     npm login
npm ERR! A complete log of this run can be found in: /vercel/.npm/_logs/2024-06-12T05_48_36_739Z-debug-0.log
Error: Command "npm install" exited with 1

No idea how to fix this, I'm new to SvelteKit. All node modules install fine on my dev machine without me ever logging into npmsjs...


Solution

  • I did delete package.lock.json and now the app builds perfectly on Vercel.

    Thanks Peppe.