Error: Cannot find module 'express'

Alright so I have been watching a few tutorials here and there on how to host my discord bot using glitch.
For some odd reason though I keep getting this error,
Error: Cannot find module 'express'.
I’m not sure why it does this.

1 Like

Nevermind for some reason it just decided to fix itself

Hmm, I’m also seeing this error in one of my projects https://glitch.com/edit/#!/slack-arena?path=server.js

i’ve made no changes since it was working earlier in the day … :thinking:

I reinstalled all my modules using npm i and for some reason they all came back to life

1 Like

ya that did it, possibly there’s an issue with our changes to package management/pnpm :thinking: , hopefully if more ppl report this we can repro and fix it

1 Like

Running npm i fixed my issue with a module load error (mongoose). Maybe something as simple as a ‘Re-run NPM install’ button inside of the advanced setting section would be able to quickly resolve any module load error.

Getting this exact problem in only one of my projects

https://testing-with-mocha.glitch.me

ran npm i and it installed the modules in the console but immediately started experiencing the error in the logs and the app won’t start

This has fixed itself. ignore previous comment

I saw the same error today in one of my projects and it was resolved with running “npm i” in console

A post was split to a new topic: Permission errors in node_modules