On Jan 18, 2007, at 5:02 PM, stane wrote:


I easy_install mako and try to use it

@expose(template="mako.templates.makohello")
   def checkmako(self):
       return dict(msg='hello from mako')


and I am getting 500 errors here is snippet
File
"c:\Python24\lib\site-packages\myghty-1.0.2-py2.4.egg\myghty \importer.py",
line 54, in import_module
   return builtin_importer(name, globals, locals, fromlist)
ImportError: No module named templates

Is there something that I should setup in front to use mako templates

You're telling expose to load a template called "makohello" inside the "mako.templates" package which doesn't exist.

I guess you made a small typo, @expose (template="mako:myapp.templates.makohello") would probably work (if your app's module is called "myapp" ;)

Alberto

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to