[RC2] Report with notes containt accent doesn't appear

Bug #312393 reported by Christophe CHAUVET
2
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Fix Released
Undecided
Unassigned

Bug Description

Server revno : 1522
Addons revno : 2054

on object containt a note field (purchase order, sale order, etc...) use word with accent é è (or word in french) the report is generate but the note is missing and an error message appear on server log
--------------8<---------------------8<--------------
[Tue Dec 30 2008 10:21:41] ERROR:report:[01]: report sale.order:
[Tue Dec 30 2008 10:21:41] ERROR:report:[02]: Traceback (most recent call last):
[Tue Dec 30 2008 10:21:41] ERROR:report:[03]: File "/home/kryskool/openerp50-rc2/openerp/server/bin/report/report_sxw.py", line 418, in _eval
[Tue Dec 30 2008 10:21:41] ERROR:report:[04]: res = eval(expr, self.localcontext)
[Tue Dec 30 2008 10:21:41] ERROR:report:[05]: File "<string>", line 1, in <module>
[Tue Dec 30 2008 10:21:41] ERROR:report:[06]: File "/home/kryskool/openerp50-rc2/openerp/server/bin/report/report_sxw.py", line 304, in format
[Tue Dec 30 2008 10:21:41] ERROR:report:[07]: newnode.__dict__['childNodes'][0].__dict__['data'] = lst[i].decode('utf8')
[Tue Dec 30 2008 10:21:41] ERROR:report:[08]: File "/usr/lib/python2.5/encodings/utf_8.py", line 16, in decode
[Tue Dec 30 2008 10:21:41] ERROR:report:[09]: return codecs.utf_8_decode(input, errors, True)
[Tue Dec 30 2008 10:21:41] ERROR:report:[10]: UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 1: ordinal not in range(128)
--------------8<---------------------8<--------------
When the note doesn't containt an accent, it appear correctly,

I think the problem is the same as bug #307908 and #308910 , and the problem was not on the module, but in orm

I haven't test to send the command below after the database connection

SET client_encoding to 'UTF8';

Regards,

Christophe.

description: updated
Changed in openobject-server:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.