def connect(self):
if self.dbconn is None:
log.info(_("Connecting the database."))
try:
self.dbdriver.connect()
except DbProfilerException as e:
log.error(_("Could not connect to the database."),
detail=e.source)
log.error(_("Abort."))
sys.exit(1)
self.dbconn = self.dbdriver.conn
log.info(_("Connected to the database."))
return True
评论列表
文章目录