Closed
Description
Migrated issue, originally created by Anonymous
This snippet gives an error (Mako 0.8, Python 2.6.6).
>>> Template('hello ${data|entity}!').render(data="world")
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "/srv/openerp/.buildout/eggs/Mako-0.8.0-py2.6.egg/mako/template.py", line 443, in render
return runtime._render(self, self.callable_, args, data)
File "/srv/openerp/.buildout/eggs/Mako-0.8.0-py2.6.egg/mako/runtime.py", line 783, in _render
**_kwargs_for_callable(callable_, data))
File "/srv/openerp/.buildout/eggs/Mako-0.8.0-py2.6.egg/mako/runtime.py", line 815, in _render_context
_exec_template(inherit, lclcontext, args=args, kwargs=kwargs)
File "/srv/openerp/.buildout/eggs/Mako-0.8.0-py2.6.egg/mako/runtime.py", line 841, in _exec_template
callable_(context, *args, **kwargs)
File "memory:0x1e70d50", line 22, in render_body
File "/srv/openerp/.buildout/eggs/Mako-0.8.0-py2.6.egg/mako/filters.py", line 92, in escape_entities
return str(text).translate(self.codepoint2entity)
TypeError: expected a character buffer object