changeset 4231:23ba17d01a24

re-order sqlite imports to handle multiple installed versions (issue 2550570)
author Richard Jones <richard@users.sourceforge.net>
date Mon, 27 Jul 2009 23:57:23 +0000
parents f5d7562bed95
children 01ef28bffcbd
files CHANGES.txt roundup/backends/back_sqlite.py
diffstat 2 files changed, 6 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/CHANGES.txt	Mon Jul 20 23:26:10 2009 +0000
+++ b/CHANGES.txt	Mon Jul 27 23:57:23 2009 +0000
@@ -14,6 +14,8 @@
   privilege, e.g., user not existing (issue 2550534)
 - fix construction of individual messages to nosy recipents with
   attachments (issue 2550568)
+- re-order sqlite imports to handle multiple installed versions (issue
+  2550570)
 
 
 2009-03-18 1.4.8 (r4209)
--- a/roundup/backends/back_sqlite.py	Mon Jul 20 23:26:10 2009 +0000
+++ b/roundup/backends/back_sqlite.py	Mon Jul 27 23:57:23 2009 +0000
@@ -14,8 +14,8 @@
 from roundup.backends import rdbms_common
 sqlite_version = None
 try:
-    import sqlite
-    sqlite_version = 1
+    import sqlite3 as sqlite
+    sqlite_version = 3
 except ImportError:
     try:
         from pysqlite2 import dbapi2 as sqlite
@@ -24,8 +24,8 @@
                 '- %s found'%sqlite.version)
         sqlite_version = 2
     except ImportError:
-        import sqlite3 as sqlite
-        sqlite_version = 3
+        import sqlite
+        sqlite_version = 1
 
 def db_exists(config):
     return os.path.exists(os.path.join(config.DATABASE, 'db'))

Roundup Issue Tracker: http://roundup-tracker.org/