phase3
This commit is contained in:
parent
18b2ee383c
commit
57dfc8f8ba
1 changed files with 3 additions and 3 deletions
6
grid.py
6
grid.py
|
@ -29,9 +29,9 @@ def querydb(cubeid):
|
||||||
""" open a metadata file """
|
""" open a metadata file """
|
||||||
try:
|
try:
|
||||||
dbfile = 'db/vm.{}.json'.format(src_data['cube'])
|
dbfile = 'db/vm.{}.json'.format(src_data['cube'])
|
||||||
with open(dbfile as datafile):
|
with open(dbfile, 'r' as dbf):
|
||||||
data = json.load(datafile)
|
data = json.load(dbf)
|
||||||
datafile.close()
|
dbf.close()
|
||||||
logger.info('grid> {} --> {}'.format(dbfile, data))
|
logger.info('grid> {} --> {}'.format(dbfile, data))
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.critical('grid> {}'.format(e))
|
logger.critical('grid> {}'.format(e))
|
||||||
|
|
Loading…
Reference in a new issue