[issue13676] sqlite3: Zero byte truncates string contents
report at bugs.python.org
Sun Jan 1 21:18:23 CET 2012
Petri Lehtinen <petri at digip.org> added the comment:
Attached an updated patch. The custom text_factory case is now fixed, and bytes, bytearray and custom factory are all tested.
I also added back the pysqlite_unicode_from_string() function, as this makes the patch a bit smaller. It also seems to me (only by looking at the code) that the sqlite3.OptimizedUnicode factory isn't currently working as documented.
Antoine: Do you happen to know what's the status of the OptimizeUnicode thingie? Has it been changed for a reason or is it just an error that happened during the py3k transition?
Added file: http://bugs.python.org/file24122/sqlite3_zero_byte_v3.patch
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list