#Restart Shell
1 messages · Page 1 of 1 (latest)
it depends on how you set your bot up
You could pay for a bot host online and that would be 24/7 but paid, or you could somehow have your pc its hosted on be up 24/7
My pc is on 24/7
It's the script that stops randomly
No error at all. It just says "Restart shell" like in the picture
You could write a simple python forever script
that would just reboot the bot if it exists.
A script for starting the script again?
from subprocess import Popen
import sys
filename = sys.argv[1]
while True:
print("\nStarting " + filename)
p = Popen("python " + filename, shell=True)
p.wait()
insteead of using python start.py
you would run python forever.py start.py
Yeah. Can use this temporarly. But it's just hiding a bug/Mistake
the restart shell btw, is when you are using the python shell to execute your programs
it's not built for executing longer duration stuff
Ohhhh
This might be the issue.
What would you recommend for running a program 24/7
literally any other shell/command prompt