DB-API: fix version
This commit is contained in:
parent
8fd4f7ff8e
commit
f09c32181a
@ -229,7 +229,10 @@ class CLIDbManager(object):
|
|||||||
version = open(os.path.join(dirpath, "bdbversion.txt")).read()
|
version = open(os.path.join(dirpath, "bdbversion.txt")).read()
|
||||||
except:
|
except:
|
||||||
version = "(0, 0, 0)"
|
version = "(0, 0, 0)"
|
||||||
version = ast.literal_eval(version)
|
try:
|
||||||
|
version = ast.literal_eval(version)
|
||||||
|
except:
|
||||||
|
version = (0, 0, 0)
|
||||||
if os.path.isfile(path_name):
|
if os.path.isfile(path_name):
|
||||||
file = open(path_name, 'r', encoding='utf8')
|
file = open(path_name, 'r', encoding='utf8')
|
||||||
name = file.readline().strip()
|
name = file.readline().strip()
|
||||||
|
@ -430,6 +430,8 @@ class DbGeneric(DbWriteBase, DbReadBase, UpdateCallback, Callback):
|
|||||||
|
|
||||||
__callback_map = {}
|
__callback_map = {}
|
||||||
|
|
||||||
|
VERSION = (18, 0, 0)
|
||||||
|
|
||||||
def __init__(self, directory=None):
|
def __init__(self, directory=None):
|
||||||
DbReadBase.__init__(self)
|
DbReadBase.__init__(self)
|
||||||
DbWriteBase.__init__(self)
|
DbWriteBase.__init__(self)
|
||||||
|
@ -40,7 +40,6 @@ class DBAPI(DbGeneric):
|
|||||||
"""
|
"""
|
||||||
Database backends class for DB-API 2.0 databases
|
Database backends class for DB-API 2.0 databases
|
||||||
"""
|
"""
|
||||||
VERSION = (18, 0, 0)
|
|
||||||
|
|
||||||
def restore(self):
|
def restore(self):
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user