Forums

My Python bot's console keeps getting closed when I'm not looking.

This happens once in every 24 hours, mostly when I'm asleep, so I can't do anything about it. The console's still there, but my bot doesn't run at all. Opening the console again reloads it, and the bot starts normally. I really couldn't be doing anything that causes this. I have a custom console, but that's about it. At first I assumed this happened when my bot runs out of processor time, but now I see that this would only make it run slower, not stop it.

Please help me with this, as I really need the bot to be active 24/7! It's a part of a moderation team, and any downtime is hurting its public reception.

We do not keep consoles running forever. We need to restart them to manage the service. If you need something to run continuously, use an always on task: https://help.pythonanywhere.com/pages/AlwaysOnTasks/