Hello everyone!
I found out recently that Mako has a nice cache mechanism. Its simple like
<%block cached="True">
... some expensive call ...
</%block>
I can set all the rest required attributes (like cache_timeout="86400"
cache_type="file" cache_dir="cache") in that block tag, but I want to set
them in pyramid *__init__.py *to be global for all my cached block. In Mako
docs there is a section on cache
arguments<http://www.makotemplates.org/docs/caching.html#cache-arguments> and
as top-level object to set cache defaults to is Template. As I am new to
Pyramid and Mako, I can't figure out how do I access the Mako.Template
object. Ok I know how to set mako.directories and thats all.
Can someone point me in right direction?
--
You received this message because you are subscribed to the Google Groups
"pylons-discuss" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/pylons-discuss/-/WXIkCsmB6LsJ.
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/pylons-discuss?hl=en.