summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2015-03-20 11:19:35 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2015-03-20 11:19:35 -0400
commit1d7ce71d245cc80bbf27891e5394ae7b8476a7bb (patch)
tree966c624b263acb8d32d2ee94c6298dd93bd496c8 /lib/sqlalchemy
parentcd076470baf2fce0eebf5853e3145d96a9d48378 (diff)
parent00f37f3984c35fc4a2ee5687e798c5ca36953d6c (diff)
downloadsqlalchemy-1d7ce71d245cc80bbf27891e5394ae7b8476a7bb.tar.gz
Merge remote-tracking branch 'origin/pr/158' into pr158
Diffstat (limited to 'lib/sqlalchemy')
-rw-r--r--lib/sqlalchemy/dialects/mysql/base.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/sqlalchemy/dialects/mysql/base.py b/lib/sqlalchemy/dialects/mysql/base.py
index b8392bd4e..8933e0b70 100644
--- a/lib/sqlalchemy/dialects/mysql/base.py
+++ b/lib/sqlalchemy/dialects/mysql/base.py
@@ -881,7 +881,9 @@ class BIT(sqltypes.TypeEngine):
def process(value):
if value is not None:
v = 0
- for i in map(ord, value):
+ for i in value:
+ if not isinstance(i, int):
+ i = ord(i) # convert byte to int on Python 2
v = v << 8 | i
return v
return value