This project is archived and is in readonly mode.

#38 ✓invalid
Daniele Varrazzo

Review binary typecasters in Py3

Reported by Daniele Varrazzo | February 1st, 2011 @ 11:08 AM | in python3 (closed)

In current Py3 implementation the typecaster receive a decoded string. This means that is basically impossible to have a binary typecaster in python.

Idea: add a "binary" flag (or a "type", currently only "text" and "binary" would be meaningful) to the typecaster type. It would default to text on Python 3 and either default to binary in Python 2 or not available at all. The create_type would grow an optional parameter with the proper default. Use the value to decide whether to pass a binary or a decoded text to the typecaster function.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

<b>WARNING:</b> the informations in this tracker are archived. Please submit new tickets or comments to <a href="https://github.com/psycopg/psycopg2/issues">the new tracker</a>.
<br/>
Psycopg is the most used PostgreSQL adapter for the Python programming language. At the core it fully implements the Python DB API 2.0 specifications. Several extensions allow access to many of the features offered by PostgreSQL.

Shared Ticket Bins

People watching this ticket

Attachments

Pages