We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 58f32d9 commit bf49e29Copy full SHA for bf49e29
roundup/backends/back_sqlite.py
@@ -1,4 +1,4 @@
1
-# $Id: back_sqlite.py,v 1.34 2004-10-08 05:37:44 richard Exp $
+# $Id: back_sqlite.py,v 1.35 2004-10-16 12:52:53 a1s Exp $
2
'''Implements a backend for SQLite.
3
4
See https://pysqlite.sourceforge.net/ for pysqlite info
@@ -60,6 +60,11 @@ def sql_open_connection(self):
60
61
pysqlite will automatically BEGIN TRANSACTION for us.
62
'''
63
+ # make sure the database directory exists
64
+ # database itself will be created by sqlite if needed
65
+ if not os.path.isdir(self.config.DATABASE):
66
+ os.makedirs(self.config.DATABASE)
67
+
68
db = os.path.join(self.config.DATABASE, 'db')
69
self.config.logging.getLogger('hyperdb').info('open database %r'%db)
70
conn = sqlite.connect(db=db)
0 commit comments