[Sqlalchemy-tickets] Issue #3315: MySQL Connector >= 2.0.0, Python 3.4 always returns bytearrays in
Brought to you by:
zzzeek
|
From: Andrea G. <iss...@bi...> - 2015-03-04 14:46:42
|
New issue 3315: MySQL Connector >= 2.0.0, Python 3.4 always returns bytearrays instead of (unicode) strings https://bitbucket.org/zzzeek/sqlalchemy/issue/3315/mysql-connector-200-python-34-always Andrea Gronchi: I'm using SQLAlchemy 9.8.0 and MySQL Connector 2.0.3. I've found myself unable to get unicode data (intending the PY3 type "str"), every text field was always obtained as byte array data. Passing explicitly convert_unicode=True had no effect; declaring columns as UnicodeText had no effect; coercing connection options "use_unicode=1&charset=…" had no effect. I have gave out and moved on to PyMySql; everything worked instantly. Then I found this release note http://dev.mysql.com/doc/relnotes/connector-python/en/news-2-0-0.html , which basically notifies about the braking change of always returning bytearray data while using raw cursors. I don't know if this might be the case but it's probably worth looking into. |