On 11 August 2011 10:19, Robert Forkel <[email protected]> wrote: > I noticed that deform form rendering is somewhat slow in my > application and found the @cache decorator in deform.template. I'd > like my templates to be cached, but since I use i18n, thus passing > translators to initialize a template loader on a per request basis, > this does not work. Now I only have a limited number of locales to > support, so I was thinking about initializing template loaders for > these locales at application start. But in this case, the cache > decorator would have to take the translate attribute into account as > well and not only the template filename.
Try upgrading to Chameleon 2.x. The ``cache`` decorator you're talking about is not used on this version and I'd expect that it would just work for you out of the box. I assume that you're using the default language setup: https://docs.pylonsproject.org/projects/pyramid/1.0/narr/i18n.html#default-locale-negotiator \malthe -- You received this message because you are subscribed to the Google Groups "pylons-discuss" 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/pylons-discuss?hl=en.
