allow using sqlite from pysqlite2

in case Python was built with an incomplete standard library (missing sqlite3)

we do the same thing in IPython history, etc.
This commit is contained in:
Min RK 2016-04-06 13:17:44 -07:00
parent 67f57ae4aa
commit 65ba875d5b

View File

@ -4,7 +4,12 @@
# Distributed under the terms of the Modified BSD License.
import uuid
import sqlite3
try:
import sqlite3
except ImportError:
# fallback on pysqlite2 if Python was build without sqlite
from pysqlite2 import dbapi2 as sqlite3
from tornado import gen, web