Thursday, December 22, 2011

Py rdbms.connect does not support charset = "utf8" or use_unicode = True

In development mode my application works fine. When I deploy it to
App Engine I see that these two options are dropped and an exception
is thrown as soon as I try to run a query that contains an accented
character.

2011-12-22 11:41:57.342
Ignoring extra kwargs to connect(): {'charset': 'utf8', 'use_unicode':
True}
....
cursor.execute(q, newTuple)
File "/base/python27_runtime/python27_lib/versions/1/google/storage/
speckle/python/api/rdbms.py", line 319, in execute
tuple_proto.values[value_index]))
File "/base/python27_runtime/python27_lib/versions/1/google/storage/
speckle/python/api/rdbms.py", line 255, in _DecodeVariable
return converter(value)
File "/base/python27_runtime/python27_lib/versions/1/google/storage/
speckle/python/api/converters.py", line 112, in Str2Unicode
return unicode(arg, 'utf-8')
UnicodeDecodeError: 'utf8' codec can't decode byte 0xed in position 9:
invalid continuation byte

No comments:

Post a Comment