Skip to content

UnicodeDecodeError #136

@wenshan-willowit

Description

@wenshan-willowit

Hi,

I'm trying to log some information using the kivy Logger, here is the code:

sql = "insert or replace into res_partner (name) values " + values
Logger.info(sql)

(values is a string).

When I run the program on Android, I got:

I/python  ( 4319):  Logged from file main.py, line 46
I/python  ( 4319):  Traceback (most recent call last):
I/python  ( 4319):    File "/home/openerp/code/python-for-android/build/python-install/lib/python2.7/logging/__init__.py", line 865, in emit
I/python  ( 4319):    File "<string>", line 15, in write
I/python  ( 4319):  UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 759: ordinal not in range(128)

On Ubuntu, I got the expected result:

[INFO   ] insert or replace into res_partner (name) values ("Administrator"),("Wenshan"),("Your Company")

Any idea on this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions