Frequent Restart Of My Project Causing It Not To Function Correctly

Hello Glitch Support, My project has a discord bot hosted on it. When I open the project something happens in the console then after a few moments the bot starts up. If I don’t open the project the bot won’t function. Also I have to always keep the project open for it to work correctly. Can you tell me why does the project need to do the stuff that it does in console then start my bot. A screenshot of what it does is provided below.

Thank You

My project name is: gentle-curler-bot
It is a private project. DM me and I’ll create an invite link for you.

Same happened to me, had to copy the files to another project to fix it, remixing won’t work ( because it will also copy the damaged files ), but “downloading and reuploading” in another project works, just a temporary solution.

Ok thanks for the help. :+1:

I’ve sent you a DM so you can give me a join link and we’ll look into this for you.

1 Like

Ok Gareth I have sent the link

I’ve cleared your node_modules folder which was given you the warning in the second screenshot.

Using setInterval as a method of keeping your bot awake is unreliable as we sometimes need to restart projects and yours won’t restart itself after this. We recommend pinging your bot using a third-party service like uptimerobot. You already have a route in your app so you can use this for that if you’re not already. So long as you’re handling errors which occur during the operating of your bot, it should stay online.

When your project wakes the ‘something happens in the console’ you’re referring to is the packages getting installed. I suggest only listing packages you’re using in your package.json file to minimize install times. For example, you currently have mysql, mongodb, lowdb, rethinkdb and other database packages installed but you don’t seem to be using all of them.