Printing fails with accented characters (trunk)

Bug #308910 reported by Dukai Gábor
4
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Fix Released
Undecided
Stephane Wirtel (OpenERP)

Bug Description

Hi!
Trunk version.
1.) Try to create a partner name with accented characters like 'ó' and use the print screen report on it. The result:
 Traceback (most recent call last):
   File "path/bin/service/web_services.py", line 465, in go
    (result, format) = obj.create(cr, uid, ids, datas, context)
   File "path/bin/report/printscreen/ps_list.py", line 76, in create
     res = self._create_table(uid, datas['ids'], result['fields'], fields_order, rows, context, model_desc)
   File "path/bin/report/printscreen/ps_list.py", line 169, in _create_table
    txt = new_doc.createTextNode(str(line[f] or ''))
 UnicodeEncodeError: 'ascii' codec can't encode character u'\xf3' in position 2: ordinal not in range(128)

2.)Trying to print a General Ledger where account names have 'č' in them:
 Traceback (most recent call last):
  File "path/bin/service/web_services.py", line 465, in go
    (result, format) = obj.create(cr, uid, ids, datas, context)
   File "path/bin/report/report_sxw.py", line 695, in create
     rml2 = rml_parser._parse(rml_dom, objs, data, header=self.header)
   File "path/bin/report/report_sxw.py", line 576, in _parse
     self._parse_node()
  File "path/bin/report/report_sxw.py", line 520, in _parse_node
     self._parse_text(self._node.data, level)
   File "path/bin/report/report_sxw.py", line 473, in _parse_text
     newtext = str(newtext)
 UnicodeEncodeError: 'ascii' codec can't encode character u'\u0161' in position 32: ordinal not in range(128)

Changed in openobject-server:
status: New → Confirmed
assignee: nobody → matrixise
Changed in openobject-server:
status: Confirmed → 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.