Browse files

Support pymysql.

  • Loading branch information...
1 parent ba114e2 commit bdd7a7669af981326b64b18a5c2f949dbde282c2 @methane methane committed Dec 26, 2012
Showing with 8 additions and 2 deletions.
  1. +4 −1 peewee.py
  2. +4 −1 pwiz.py
View
5 peewee.py
@@ -40,7 +40,10 @@
try:
import MySQLdb as mysql
except ImportError:
- mysql = None
+ try:
+ import pymysql as mysql
+ except ImportError:
+ mysql = None
class ImproperlyConfigured(Exception):
pass
View
5 pwiz.py
@@ -24,7 +24,10 @@
try:
from MySQLdb.constants import FIELD_TYPE
except ImportError:
- FIELD_TYPE = None
+ try:
+ from pymysql.constants import FIELD_TYPE
+ except ImportError:
+ FIELD_TYPE = None
class UnknownFieldType(object):

0 comments on commit bdd7a76

Please sign in to comment.