diff options
author | Yaakov Selkowitz <yselkowitz@users.sourceforge.net> | 2010-06-15 20:42:12 -0500 |
---|---|---|
committer | Owen W. Taylor <otaylor@fishsoup.net> | 2010-07-01 13:55:09 -0400 |
commit | 55d8141c5e1565d5d30878d4e5b2e32ec5cd446a (patch) | |
tree | 7163e09542e2cbddbbc3392c21eeb1c6130ad7af | |
parent | 0a00eac3b1a8f7126079722f5f9bf73b8d24b501 (diff) | |
download | git-bz-55d8141c5e1565d5d30878d4e5b2e32ec5cd446a.tar.gz |
Use sqlite3 module if available
Since Python 2.5, pysqlite2 has been included in the Python standard
library with the name sqlite3.
https://bugzilla.gnome.org/show_bug.cgi?id=621715
-rwxr-xr-x | git-bz | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -67,7 +67,10 @@ from ConfigParser import RawConfigParser, NoOptionError import httplib from optparse import OptionParser import os -from pysqlite2 import dbapi2 as sqlite +try: + from sqlite3 import dbapi2 as sqlite +except ImportError: + from pysqlite2 import dbapi2 as sqlite import re from StringIO import StringIO from subprocess import Popen, CalledProcessError, PIPE |