Skip to content
Snippets Groups Projects
  1. Jul 08, 2012
  2. Mar 30, 2012
  3. Mar 24, 2012
  4. Mar 12, 2012
  5. Jan 16, 2012
    • Mike Bayer's avatar
      2012 · 0050ca81
      Mike Bayer authored
      0050ca81
    • Mike Bayer's avatar
      - [feature/bug] Can now refer to context variables · 2879f8bc
      Mike Bayer authored
        within extra arguments to <%block>, <%def>, i.e.
        <%block name="foo" cache_key="${somekey}">.
        Filters can also be used in this way, i.e.
        <%def name="foo()" filter="myfilter">
        then template.render(myfilter=some_callable)
        [ticket:180]
      2879f8bc
  6. Oct 01, 2011
    • Mike Bayer's avatar
      - Template caching has been converted into a plugin · 643701f1
      Mike Bayer authored
        system, whereby the usage of Beaker is just the
        default plugin.   Template and TemplateLookup
        now accept a string "cache_impl" parameter which
        refers to the name of a cache plugin, defaulting
        to the name 'beaker'.  New plugins can be
        registered as pkg_resources entrypoints under
        the group "mako.cache", or registered directly
        using mako.cache.register_plugin().  The
        core plugin is the mako.cache.CacheImpl
        class.
      
      - The <%def>, <%block> and <%page> tags now accept
        any argument named "cache_*", and the key
        minus the "cache_" prefix will be passed as keyword
        arguments to the CacheImpl methods.
      
      - Template and TemplateLookup now accept an argument
        cache_args, which refers to a dictionary containing
        cache parameters.  The cache_dir, cache_url, cache_type,
        cache_timeout arguments are deprecated (will probably
        never be removed, however) and can be passed
        now as cache_args={'url':<some url>, 'type':'memcached',
        'timeout':50, 'dir':'/path/to/some/directory'}
      643701f1
  7. Apr 06, 2011
    • Mike Bayer's avatar
      - New tag: <%block>. A variant on <%def> that · 4a19e4d9
      Mike Bayer authored
        evaluates its contents in-place.
        Can be named or anonymous,
        the named version is intended for inheritance
        layouts where any given section can be
        surrounded by the <%block> tag in order for
        it to become overrideable by inheriting
        templates, without the need to specify a
        top-level <%def> plus explicit call.
        Modified scoping and argument rules as well as a
        more strictly enforced usage scheme make it ideal
        for this purpose without at all replacing most
        other things that defs are still good for.
        Lots of new docs. [ticket:164]
      4a19e4d9
  8. Feb 20, 2011
  9. Feb 19, 2011
  10. Jan 19, 2011
  11. Nov 13, 2010
    • Mike Bayer's avatar
      - more cleanup · fe823ebd
      Mike Bayer authored
      - move Namespace docs inline to attributes on Namespace
      - document Cache methods, add to caching.rst
      - use functools.partial for partials, part of [ticket:156]
      fe823ebd
  12. Nov 10, 2010
    • Mike Bayer's avatar
      - The range of Python identifiers that · ca21a535
      Mike Bayer authored
        are considered "undefined", meaning they
        are pulled from the context, has been
        trimmed back to not include variables
        declared inside of expressions (i.e. from
        list comprehensions), as well as
        in the argument list of lambdas.  This
        to better support the strict_undefined
        feature.
      ca21a535
  13. Sep 02, 2010
  14. Aug 11, 2010
  15. Jun 30, 2010
    • Mike Bayer's avatar
      - The <%namespace> tag allows expressions · 4b408e5f
      Mike Bayer authored
        for the `file` argument, i.e. with ${}.
        The `context` variable, if needed,
        must be referenced explicitly.
        [ticket:141]
      
      - Fixed previously non-covered regular
        expression, such that using a ${} expression
        inside of a tag element that doesn't allow
        them raises a CompileException instead of
        silently failing.
      4b408e5f
  16. Mar 04, 2010
  17. Mar 02, 2010
  18. Feb 05, 2010
  19. Sep 07, 2009
  20. Mar 19, 2009
    • Mike Bayer's avatar
      - Added a "decorator" kw argument to <%def>, · da73752b
      Mike Bayer authored
        allows custom decoration functions to wrap
        rendering callables.  Mainly intended for
        custom caching algorithms, not sure what
        other uses there may be (but there may be).
        Examples are in the "filtering" docs.
      da73752b
  21. Nov 16, 2008
  22. Nov 15, 2008
    • Mike Bayer's avatar
      - the <%namespacename:defname> syntax described at · 718d98ee
      Mike Bayer authored
        http://techspot.zzzeek.org/?p=28 has now
        been added as a built in syntax, and is recommended
        as a more modern syntax versus <%call expr="expression">.
        The %call tag itself will always remain,
        with <%namespacename:defname> presenting a more HTML-like
        alternative to calling defs, both plain and
        nested.  Many examples of the new syntax are in the
        "Calling a def with embedded content" section
        of the docs.
      718d98ee
  23. Jan 19, 2008
  24. Apr 21, 2007
    • Mike Bayer's avatar
      - Lexer/Compile exceptions propigate throughout lexer/parsetree/ast · 3f9520f9
      Mike Bayer authored
      using a more portable **exception_kwargs collection
      - added "source" member to the dict propigated to Lexer/Compile exceptions
      - RichTraceback can access original template source as a unicode object
      using either 'source' memebr on Lexer/Compile exception, or 'source'
      property on ModuleInfo, fixes #37
      - unit tests for #37
      3f9520f9
  25. Mar 26, 2007
  26. Mar 19, 2007
  27. Mar 16, 2007
  28. Mar 08, 2007
  29. Jan 05, 2007
  30. Jan 04, 2007
  31. Dec 17, 2006
  32. Dec 16, 2006
Loading