Hello, I am having some problems in server of gold medal metrics, You see the server does not want to run when I run ,
node server.js
Hello, I am having some problems in server of gold medal metrics, You see the server does not want to run when I run ,
node server.js
here is the error
internal/modules/cjs/loader.js:888
throw err;
^
Error: Cannot find module 'sqlite3'
Require stack:
- D:\Teaching\Coding and Coding related\HTML ,SQL ,PHP, CSS\SQL dev env\project
-5-gold-medal-metrics-start\server.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:885:15)
at Function.Module._load (internal/modules/cjs/loader.js:730:27)
at Module.require (internal/modules/cjs/loader.js:957:19)
at require (internal/modules/cjs/helpers.js:88:18)
at Object.<anonymous> (D:\Teaching\Coding and Coding related\HTML ,SQL ,PHP
, CSS\SQL dev env\project-5-gold-medal-metrics-start\server.js:3:17)
at Module._compile (internal/modules/cjs/loader.js:1068:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)
at Module.load (internal/modules/cjs/loader.js:933:32)
at Function.Module._load (internal/modules/cjs/loader.js:774:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js
:72:12) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'D:\\Coding and Coding related\\HTML ,SQL ,PHP, CSS\\SQL dev env\
\project-5-gold-medal-metrics-start\\server.js'
]
}
Thanks for any help in advance
What is the link to the course/lesson?
This error is on the CC site?
no in my work station
Are you on a Windows machine or Mac?
Did you run npm install
to grab all the package dependencies?
See:
https://stackoverflow.com/questions/59586305/cannot-find-module-sqlite3
And this thread is helpful:
And here:
https://docs.npmjs.com/cli/v6/commands/npm-install
https://nodejs.org/en/knowledge/getting-started/npm/what-is-npm/
I haven’t completed the course but definitely take a look at npm install
. I found this article here which points to a similar problem: How do I resolve “Cannot find module” error using Node.js? - Stack Overflow
i am on a windows also how is npm install related to this
did you read the information we provided?
yes it helped in fixing one of the problems i saw when i opened server.js
do i need to download express?
maybe i shouldn’t have tried to finish sql first.
Have you taken any other SQL courses?
nope it is my first .
It’s always great to try but you may experience some frustration .