27 lines
499 B
Python
27 lines
499 B
Python
|
import os
|
||
|
import time
|
||
|
from bot.catbot import CatBot
|
||
|
from server.server import Server
|
||
|
|
||
|
SERVER_BASE_URL = "https://kaylee.wtf/cats/";
|
||
|
|
||
|
def run_bot():
|
||
|
global cb
|
||
|
cb = CatBot()
|
||
|
|
||
|
def run_server():
|
||
|
global s
|
||
|
s = Server()
|
||
|
|
||
|
import threading
|
||
|
|
||
|
# run bot (and server which allows users to upload cat images)
|
||
|
if __name__=="__main__":
|
||
|
t1 = threading.Thread(target=run_bot)
|
||
|
t2 = threading.Thread(target=run_server)
|
||
|
t1.start()
|
||
|
t2.start()
|
||
|
t1.join()
|
||
|
t2.join()
|
||
|
print("done")
|