2023-10-23 22:10:07 +00:00
|
|
|
#!/usr/bin/python3
|
2023-11-07 13:25:53 +00:00
|
|
|
from bot import bot
|
2023-11-07 13:53:14 +00:00
|
|
|
from sys import argv as args
|
2023-11-08 03:58:11 +00:00
|
|
|
from traceback import format_exc
|
|
|
|
from logs import log
|
2023-10-23 22:43:10 +00:00
|
|
|
|
2023-11-05 01:37:35 +00:00
|
|
|
server = args[1] if args else "UNSTABLE BOT MODE"
|
2023-11-02 01:28:02 +00:00
|
|
|
|
2023-11-05 04:17:08 +00:00
|
|
|
|
2023-10-23 22:10:07 +00:00
|
|
|
if __name__ == "__main__":
|
2023-11-07 13:53:14 +00:00
|
|
|
instance = bot(server)
|
2023-11-08 03:58:11 +00:00
|
|
|
try:
|
|
|
|
instance.mainloop()
|
|
|
|
except Exception:
|
|
|
|
Err = format_exc()
|
|
|
|
for line in Err.split("\n"):
|
|
|
|
log(line, server, "CRASH")
|
|
|
|
exit(-1)
|