Problem installing sqlite3

phew, after searching for 2 days for a fix, I finally solved the issue by rolling back to Node v9.11.1

12 Likes

Hey Anthony -

Thanks for your post, I had the exact same issue so this saved me a lot of time figuring out what was wrong. Codecademy should include some sort of warning on this.

Anyway, used a node version manager tool (here) that works perfectly and lets you dynamically change your node version to be used.

Jeroen

3 Likes

I have the same issue, i can’t believe that something such important is not warning anywhere… thank you guys

1 Like

Hey Y’all,
I’m having the same issue with this project. Is anyone using a nvm for mac? If so, can you recommend a link for the nvm so i can install sqlite3?
Not sure I really understand how nvm and node live side by side on my cpu…
j

1 Like

For Windows10 I had to uninstall node and installed again v9.11.1 from https://nodejs.org/en/download/releases/ and after npm install worked.

1 Like

Instead of changing the node version, try to change the sqlite version in package.json:
for me

“sqlite3”: “^4.1.1”

worked perfectly (4.1.1 is the latest sqlite version on npmjs.com). After this, just run npm install again.

32 Likes

Thank you @patrick1238558746048!
That seems to have solved the problem very easily. How did you know to do this?

Thanks, again!

1 Like

I read something on the internet that the problem is related to compatibility problems of node and sqlite so I thought about just using a newer version of sqlite instead of deinstalling node and downloading an earlier node version. Other codecademy-projects seem to already have a newer sqlite version included in package.json!

2 Likes

Thanks for letting me know.

Can you help me? How did you fix it?

This worked for me as well.

made guide here

Thank you Patrick. You saved me.

I just run these to codes:

npm install https://github.com/mapbox/node-sqlite3/tarball/master

then

npm install sqlite3

After it the problem solved.

1 Like

Nailed it. Thanks!

There are still a lot of vulnerabilities (66 for me) but running npm audit fix fixed most of them for me.

1 Like

At the time I’m writing this (7/10/2020), the latest version of Node is 14.3.0, but the version of sqlite3 npm tries to install by default is 4.2.0, which only supports up to Node 13. Fortunately, there is a sqlite3 5.0.0 that does support Node 14 available – you just need to tell npm to install it using:

npm install sqlite3@5.0.0

According to the release notes, this latest version of sqlite3 drops support for versions of node older than 10. If you intend to upgrade to it, make sure your Node is an appropriate version as well.

Thank you for this, Saved me a lot

This worked perfectly for me on a Mac, thanks!

Thanks mate, this solved it!

PATRICK THANK YOU! I just wrote an issue about this. Glad I kept searching.