osu-wayback/objects/glob.py
2019-03-11 07:51:05 +01:00

16 lines
334 B
Python

import json
import sqlite3
from multiprocessing.pool import ThreadPool
from helpers import databaseHelper
with open("config.json", "r") as f:
config = json.load(f)
app = None
sql = None
pool = ThreadPool(config["threads"])
def new_sql():
db = sqlite3.connect("wayback.db")
db.row_factory = databaseHelper.dict_factory
return db