File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change 1
1
import sys
2
- import sagecell_config
3
2
4
3
def select_db (sysargs , context = None ):
5
4
u"""
@@ -10,6 +9,7 @@ def select_db(sysargs, context=None):
10
9
:type context: zmq.Context
11
10
:returns: a tuple of the form ``(db, fs)``
12
11
"""
12
+ import sagecell_config
13
13
try :
14
14
db = sysargs .db
15
15
except :
@@ -38,8 +38,7 @@ def select_db(sysargs, context=None):
38
38
return db_sqlalchemy .DB ('sqlalchemy_sqlite.db' ), None # None should be replaced by the sqlite filestore
39
39
elif db == "mongo" :
40
40
import pymongo , db_mongo , filestore
41
- import sagecell_config
42
- from sagecell_config import mongo_config
41
+ mongo_config = sagecell_config .mongo_config
43
42
44
43
if '@' in mongo_config ['mongo_uri' ]:
45
44
# password specified, so we need to include the database in the URI
You can’t perform that action at this time.
0 commit comments