Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Printing error in sales order

By
Helal
on 3/8/15, 4:58 PM 1,044 views

Dear Experts,
I got this error while I'm trying to print a sales order.
Please help with you experience...

Odoo Server Error

Traceback (most recent call last):
File "/opt/odoo/odoo-server/addons/report/controllers/main.py", line 121, in report_download
response = self.report_routes(reportname, docids=docids, converter='pdf')
File "/opt/odoo/odoo-server/openerp/http.py", line 396, in response_wrap
response = f(args, *kw)
File "/opt/odoo/odoo-server/addons/report/controllers/main.py", line 65, in report_routes
pdf = report_obj.get_pdf(cr, uid, docids, reportname, data=options_data, context=context)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/addons/report/models/report.py", line 190, in get_pdf
html = self.get_html(cr, uid, ids, report_name, data=data, context=context)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/addons/report/models/report.py", line 175, in get_html
return self.render(cr, uid, [], report.report_name, docargs, context=context)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/addons/report/models/report.py", line 151, in render
return view_obj.render(cr, uid, template, values, context=context)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_ui_view.py", line 1015, in render
return self.pool[engine].render(cr, uid, id_or_xml_id, qcontext, loader=loader, context=context)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 253, in render
return self.render_node(self.get_template(id_or_xml_id, qwebcontext), qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node
result = self.render_element(element, template_attributes, generated_attributes, qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element
g_inner.append(self.render_node(current_node, qwebcontext))
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node
result = self._render_tagt_render
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 439, in render_tag_call
return self.render(cr, uid, template, d)
File "/opt/odoo/odoo-server/openerp/api.py", line 241, in wrapper
return old_api(self, args, *kwargs)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 253, in render
return self.render_node(self.get_template(id_or_xml_id, qwebcontext), qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 294, in render_node
result = self.render_element(element, template_attributes, generated_attributes, qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 315, in render_element
g_inner.append(self.render_node(current_node, qwebcontext))
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 292, in render_node
result = self._render_tagt_render
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 458, in render_tag_set
qwebcontext[template_attributes["set"]] = self.eval_object(template_attributes["value"], qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 200, in eval_object
return self.eval(expr, qwebcontext)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 197, in eval
raise_qweb_exception(message="Could not evaluate expression %r" % expr, expression=expr, template=template)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 194, in eval
return qwebcontext.safe_eval(expr)
File "/opt/odoo/odoo-server/openerp/addons/base/ir/ir_qweb.py", line 80, in safe_eval
return eval(expr, None, locals_dict, nocopy=True, locals_builtins=True)
File "/opt/odoo/odoo-server/openerp/tools/safe_eval.py", line 314, in safe_eval
return eval(c, globals_dict, locals_dict)
File "", line 1, in 
QWebException: "cannot concatenate 'str' and 'NoneType' objects" while evaluating
"'container '+lang_direction"

i think you are trying to concatenating a "*string*" with an "*empty value* with none type object". There is no object or value comes for a field which you specified. So you can better use that if not any value , then give "* ' '* " value. For example : ${o.number or ''}.try this

Vasanth
on 3/9/15, 1:34 AM

Did you setup any custom module? This error does not usually happen in core modules. Let me know if you are technical, can help you find out the root. Please here if this helps! https://github.com/odoo/odoo/issues/4974

Serpent Consulting Services Pvt. Ltd.
on 3/9/15, 2:52 AM

Yes, I installed the "Report_rtl" module to enable printing reports from right to left.

Helal
on 3/9/15, 8:11 AM

I don't know how to trace odoo errors!

Helal
on 3/9/15, 8:14 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 3/8/15, 4:58 PM
Seen: 1044 times
Last updated: 3/16/15, 8:10 AM