through ``encode()``, as this is not valid on Python 3, and prevented
statements from functioning correctly on Python 3. We now
encode only if ``supports_unicode_binds`` is False, which is not
the case for cx_oracle when at least version 5 of cx_oracle is used.
.. changelog::
:version: 0.8.0
+ .. change::
+ :tags: bug, oracle
+
+ The cx_oracle dialect will no longer run the bind parameter names
+ through ``encode()``, as this is not valid on Python 3, and prevented
+ statements from functioning correctly on Python 3. We now
+ encode only if ``supports_unicode_binds`` is False, which is not
+ the case for cx_oracle when at least version 5 of cx_oracle is used.
+
.. change::
:tags: bug, orm
:tickets: 2661
(not exclude_types or dbtype not in exclude_types):
if translate:
key = translate.get(key, key)
- inputsizes[self.dialect._encoder(key)[0]] = dbtype
+ if not self.dialect.supports_unicode_binds:
+ key = self.dialect._encoder(key)[0]
+ inputsizes[key] = dbtype
try:
self.cursor.setinputsizes(**inputsizes)
except Exception, e: