| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|/ / / / / |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Don't skip an erroneous comma when parsing "from"
|
| | | | | | |
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Currently we skip an extra comma when "with context" is not provided to
the "from" statement. This allows invalid code such as this:
{% from "functions.html" import my_function,, %}
The primary issue with this is that it is not consistent when providing
"with context". The following code throws an error, contrary to the
previous example:
{% from "functions.html" import my_function,, with context %}
It seems that the comma skipping was originally found in 0611e49 and was
accidentally put inside the "with context" check in ea847c5. It was then
updated to use "skip_if" in fdf9530.
There doesn't seem to be any reason for this check existing, as
double commas should never be allowed and serve no purpose in the
statement.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Add stricter checking to "from ... import ..."
|
| | | | | | |
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Currently token parsing on "from ... import ..." is rather "loose" — it
sees the following "invalid" code as perfectly valid:
{% from "functions" import my_function, %}
{% from "functions" import, %}
{% from "functions" import %}
This is caused by the parser ignoring non-name values where there should
be names, either as the first value or after commas.
This commit ensures only name values are allowed as the first value and
any values after commas in the import section.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Inline template tests during optimization
|
|/ / / / / |
|
| |_|/ /
|/| | |
| | | |
| | | |
| | | |
| | | | |
This works by having an alternate CodeGenerator that avoids doing to_string
after the yield statement and a new version of concat that handles the returned
generator with a bit more "intelligence".
|
|\ \ \ \
| | | | |
| | | | | |
Allow using comparison operator symbols as tests
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | | |
add tests and aliases for all comparison operators
adjust docs to prefer short names for compare tests
closes #664
|
|\ \ \ \
| | | | |
| | | | | |
Standard test config
|
| | | | |
| | | | |
| | | | |
| | | | | |
add branch coverage and codecov
|
| | | | | |
|
|/ / / / |
|
|\ \ \ \
| | | | |
| | | | | |
min and max filters
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
argument order consistent with existing filters
add changelog
|
|/ / / / |
|
|\ \ \ \
| | | | |
| | | | | |
Unique filter
|
| | | | |
| | | | |
| | | | |
| | | | | |
add changelog
|
| |\ \ \ \
| |/ / / /
|/| | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Prevent random filter from being folded
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
add changelog
|
| | | | | | |
|
| |\ \ \ \ \
| |/ / / / /
|/| | | | | |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Use str.isidentifier to match idents on python 3
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
new version uses ~2KB vs 200KB memory, is ~100x faster to load
move script to generate pattern to scripts directory
add more tests
|
| | | | | | | |
|
| | | | | | | |
|
| | | | | | | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
avoids duplicate work for internal prs
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
currently fails on special case unicode
|
| | | | | | | |
|
| | | | | | | |
|
| | | | | | | |
|
|/ / / / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Same behavior as in Django: All linebreaks and the whitespace
surrounding linebreaks are replaced with a single space.
closes #504
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Add namespace objects that support attribute assignment
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
https://github.com/pallets/jinja/pull/684#issuecomment-291958060
|
| | | | | | | |
|
| | | | | | | |
|
|/ / / / / / |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Add previtem/nextitem/changed() to loop context
|
| | | | | | | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
related: #641
|
|/ / / / / / |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
disable recursive comments in vim syntax file
|
|/ / / / / /
| | | | | |
| | | | | |
| | | | | | |
Fixes #720
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
In documentation, prefer https over http when available
|
| | | | | | | |
|