had not been migrated to lxml
<t t-if="'expression' in qweb_exception.qweb">and evaluating the following expression: <code t-esc="qweb_exception.qweb['expression']"/></t>
</p>
<t t-if="'node' in qweb_exception.qweb">
- <pre id="exception_node" t-esc="qweb_exception.qweb['node'].toxml()"/>
+ <pre id="exception_node" t-esc="qweb_exception.pretty_xml()"/>
</t>
</div>
</div>
def __init__(self, message, **kw):
Exception.__init__(self, message)
self.qweb = dict(kw)
+ def pretty_xml(self):
+ if 'node' not in self.qweb:
+ return ''
+ return etree.tostring(self.qweb['node'], pretty_print=True)
class QWebTemplateNotFound(QWebException):
pass