[Resolved] Cannot find module 'express'


Hello! I’m hosting a Discord bot on glitch, and today, I got an error saying:

throw err;
Error: Cannot find module ‘express’
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:548:15)
at Function.Module._load (internal/modules/cjs/loader.js:475:25)
at Module.require (internal/modules/cjs/loader.js:598:17)
at require (internal/modules/cjs/helpers.js:11:18)

I’ve seen posts saying this was fixed. Is it something wrong with my code only?
Project: https://panda-turtle-bot.glitch.me


This can happen for a few reasons. Check your project isn’t out of space - run ‘df’ at the console and see the percentage space used for the ‘/app’ entry. Failing that, we’ve seen a spate of these errors caused by 404 errors resulting from invalid URLs used for other dependencies in your package.json file. Particularly ones for discord.js now the old organization has been redirected. Check for that too and let us know if you’re still having trouble.


@Gareth | I am having the same issue. However, my storage isn’t capped. Any other solutions? Thank you in advance.


If it’s none of the above, then let us know the project name and we’ll take a look. If your project is private, either make it public temporarily or DM me a join link so we can view the code. Thanks.


@Gareth | I will send you an invite link.