There are two reasons a bot goes down: something crashed, or something drifted. Automation handles the second one well and the first one badly, and treating them the same is how a real bug hides for a month.
Which one are you looking at?
| Pattern | Meaning |
|---|---|
| Dies at the same point in the same command | A bug. Read the trace and fix it. |
| Dies at random after days of uptime | Often a leak or an unhandled network hiccup. |
| Memory climbs steadily until it stops | A leak. A restart schedule is a bandage, not a fix. |
| Dies right after starting | Config: token, intents, missing file. |
| Never restarts after a crash | Nothing is watching it. That is what a schedule fixes. |
Setting up a nightly restart
- Pick a genuinely quiet hour
Look at when your servers are actually active, not at what sounds late. A restart during your peak is worse than no restart.
- Use the panel's schedule feature
A power action on a cron expression. Nothing needs to run inside your bot for this to work.
- Announce it if people will notice
A bot that vanishes for twenty seconds every night generates reports unless somebody says it is expected.
Restarting a leaking bot every six hours keeps it online and keeps the bug. It also means you find out about the real problem when it grows fast enough to beat the schedule — usually at the worst moment.
Console output scrolls away and is gone after a restart. Writing errors to a file in your bot's directory means the crash from last Tuesday is still there when you finally have time to look at it.