Dragory / modmailbot

Modmail Bot is a bot for Discord that makes it easier for users to contact moderators and admins for help.
MIT License
684 stars 696 forks source link

Bot Crashes Every Day or Two #64

Closed Ragnarok345 closed 6 years ago

Ragnarok345 commented 6 years ago

So I run the bot 24/7 on my Mac Mini that I have on permanently, and every couple days or so, the bot just randomly crashes. No idea why. I've got I have a picture of the crash below, and I know, it says to update, which is why I've included what happens when I do that, too. It tells me to run as an administrator, but I'm the only administrator on the computer.

crash update

EDIT: I've got it updated now. Totally forgot about sudo. Time will now tell if it stops crashing. Apologies if this wastes anyone's time.

sporkwitch commented 6 years ago

Make sure you're using the latest version; if you originally installed before mid-February, you'll need to nuke the ./src folder, at minimum (you can really nuke everything but config.json, ./attachments, and ./db). Back that stuff up, do a fresh clone, restore the backups.

Dragory commented 6 years ago

The error, ECONNRESET, looks like an issue of some sort with your connection and/or the Discord API. I would recommend running the bot with something that auto-restarts it, such as foreverjs or pm2.