return aDict


class Db:

    def __init__(self, app):
        self.app = app

def connect(self):
    self.connection = sqlite3.connect(self.app.dbFileName,
        check_same_thread=False, isolation_level=None)
self.connection.row_factory = dictFactory
self.cs = LockableCursor(self.connection.cursor())
How to share single SQLite connection in multi-threaded Python application