added with-statement extension.
[jinja2.git] / CHANGES
1 Jinja2 Changelog
2 ================
3
4 Version 2.3
5 -----------
6 (codename to be selected, release date will be February 9th 2010)
7
8 - fixes issue with code generator that causes unbound variables
9   to be generated if set was used in if-blocks and other small
10   identifier problems.
11 - include tags are now able to select between multiple templates
12   and take the first that exists, if a list of templates is
13   given.
14 - fixed a problem with having call blocks in outer scopes that
15   have an argument that is also used as local variable in an
16   inner frame (#360).
17 - greatly improved error message reporting (#339)
18 - implicit tuple expressions can no longer be totally empty.
19   This change makes ``{% if %}...{% endif %}`` a syntax error
20   now. (#364)
21 - added support for translator comments if extracted via babel.
22 - added with-statement extension.
23
24 Version 2.2.1
25 -------------
26 (bugfix release, released on September 14th 2009)
27
28 - fixes some smaller problems for Jinja2 on Jython.
29
30 Version 2.2
31 -----------
32 (codename Kong, released on September 13th 2009)
33
34 - Include statements can now be marked with ``ignore missing`` to skip
35   non existing templates.
36 - Priority of `not` raised.  It's now possible to write `not foo in bar`
37   as an alias to `foo not in bar` like in python.  Previously the grammar
38   required parentheses (`not (foo in bar)`) which was odd.
39 - Fixed a bug that caused syntax errors when defining macros or using the
40   `{% call %}` tag inside loops.
41 - Fixed a bug in the parser that made ``{{ foo[1, 2] }}`` impossible.
42 - Made it possible to refer to names from outer scopes in included templates
43   that were unused in the callers frame (#327)
44 - Fixed a bug that caused internal errors if names where used as iteration
45   variable and regular variable *after* the loop if that variable was unused
46   *before* the loop.  (#331)
47 - Added support for optional `scoped` modifier to blocks.
48 - Added support for line-comments.
49 - Added the `meta` module.
50 - Renamed (undocumented) attribute "overlay" to "overlayed" on the
51   environment because it was clashing with a method of the same name.
52 - speedup extension is now disabled by default.
53
54 Version 2.1.1
55 -------------
56 (Bugfix release)
57
58 - Fixed a translation error caused by looping over empty recursive loops.
59
60 Version 2.1
61 -----------
62 (codename Yasuzō, released on November 23rd 2008)
63
64 - fixed a bug with nested loops and the special loop variable.  Before the
65   change an inner loop overwrote the loop variable from the outer one after
66   iteration.
67
68 - fixed a bug with the i18n extension that caused the explicit pluralization
69   block to look up the wrong variable.
70
71 - fixed a limitation in the lexer that made ``{{ foo.0.0 }}`` impossible.
72
73 - index based subscribing of variables with a constant value returns an
74   undefined object now instead of raising an index error.  This was a bug
75   caused by eager optimizing.
76
77 - the i18n extension looks up `foo.ugettext` now followed by `foo.gettext`
78   if an translations object is installed.  This makes dealing with custom
79   translations classes easier.
80
81 - fixed a confusing behavior with conditional extending.  loops were partially
82   executed under some conditions even though they were not part of a visible
83   area.
84
85 - added `sort` filter that works like `dictsort` but for arbitrary sequences.
86
87 - fixed a bug with empty statements in macros.
88
89 - implemented a bytecode cache system.  (:ref:`bytecode-cache`)
90
91 - the template context is now weakref-able
92
93 - inclusions and imports "with context" forward all variables now, not only
94   the initial context.
95
96 - added a cycle helper called `cycler`.
97
98 - added a joining helper called `joiner`.
99
100 - added a `compile_expression` method to the environment that allows compiling
101   of Jinja expressions into callable Python objects.
102
103 - fixed an escaping bug in urlize
104
105 Version 2.0
106 -----------
107 (codename jinjavitus, released on July 17th 2008)
108
109 - the subscribing of objects (looking up attributes and items) changed from
110   slightly.  It's now possible to give attributes or items a higher priority
111   by either using dot-notation lookup or the bracket syntax.  This also
112   changed the AST slightly.  `Subscript` is gone and was replaced with
113   :class:`~jinja2.nodes.Getitem` and :class:`~jinja2.nodes.Getattr`.
114
115   For more information see :ref:`the implementation details <notes-on-subscriptions>`.
116
117 - added support for preprocessing and token stream filtering for extensions.
118   This would allow extensions to allow simplified gettext calls in template
119   data and something similar.
120
121 - added :meth:`jinja2.environment.TemplateStream.dump`.
122
123 - added missing support for implicit string literal concatenation.
124   ``{{ "foo" "bar" }}`` is equivalent to ``{{ "foobar" }}``
125
126 - `else` is optional for conditional expressions.  If not given it evaluates
127   to `false`.
128
129 - improved error reporting for undefined values by providing a position.
130
131 - `filesizeformat` filter uses decimal prefixes now per default and can be
132   set to binary mode with the second parameter.
133
134 - fixed bug in finalizer
135
136 Version 2.0rc1
137 --------------
138 (no codename, released on June 9th 2008)
139
140 - first release of Jinja2