from base import ModuleBase import MySQLdb class Module(ModuleBase): def __init__(self, manager): ModuleBase.__init__(self, manager) conf = manager.config['mysql'] self.db = MySQLdb.connect(host = conf['host'], user = conf['user'], passwd = conf['passwd'], db = conf['db'])