Wrong dbapi for Binary in python3

Bug #732134 reported by Martin Drejer
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
MySQL Connector/Python
Status tracked in Trunk
0.3
In Progress
High
Geert JM Vanderkelen
Trunk
In Progress
High
Geert JM Vanderkelen

Bug Description

Just downloaded the file http://launchpad.net/myconnpy/0.3/0.3.2/+download/mysql-connector-python-0.3.2-devel.tar.gz. In this file theres both a python2 and a python3 lib (MUCH APPRECIATED). However the dbapi file in the python3 folder declares the Binary type as:
Binary = str
In python 3 this should be:
Binary = binary

This avoids the code from wrapping binary data in b'data' when inserted into data.

The path to the file in the archive is:
mysql-connector-python-0.3.2-devel/python3/mysql/connector/dbapi.py line 58

Revision history for this message
Martin Drejer (drejer-martin) wrote :

Oops. Typo...

The line for python3 should of course be:

Binary = bytes

Revision history for this message
Geert JM Vanderkelen (geertjmvdk) wrote :

Indeed, that should be 'bytes' for Python 3.1. Thanks for reporting this!

Changed in myconnpy:
assignee: nobody → Geert JM Vanderkelen (geertjmvdk)
importance: Undecided → Low
status: New → In Progress
importance: Low → High
Revision history for this message
Geert JM Vanderkelen (geertjmvdk) wrote :

This bug was moved to http://bugs.mysql.com/bug.php?id=64404

Please add comments or subscribe using the above URL.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.