Commit e2d0bb95 authored by Bryton Lacquement's avatar Bryton Lacquement 🚪

jinja2: add bytes and six

parent a240f354
...@@ -25,6 +25,7 @@ setup(name=name, ...@@ -25,6 +25,7 @@ setup(name=name,
include_package_data=True, include_package_data=True,
install_requires=[ install_requires=[
'setuptools', # namespaces 'setuptools', # namespaces
'six',
'zc.buildout', # plays with buildout 'zc.buildout', # plays with buildout
'jinja2>=2.7', 'jinja2>=2.7',
], ],
......
...@@ -32,12 +32,13 @@ import tempfile ...@@ -32,12 +32,13 @@ import tempfile
import zc.buildout import zc.buildout
from jinja2 import Environment, StrictUndefined, \ from jinja2 import Environment, StrictUndefined, \
BaseLoader, TemplateNotFound, PrefixLoader BaseLoader, TemplateNotFound, PrefixLoader
import six
DEFAULT_CONTEXT = {x.__name__: x for x in ( DEFAULT_CONTEXT = {x.__name__: x for x in (
abs, all, any, bin, bool, callable, chr, complex, dict, divmod, abs, all, any, bin, bool, bytes, callable, chr, complex, dict, divmod,
enumerate, filter, float, format, frozenset, hex, int, enumerate, filter, float, format, frozenset, hex, int,
isinstance, iter, len, list, map, max, min, next, oct, ord, isinstance, iter, len, list, map, max, min, next, oct, ord,
pow, repr, reversed, round, set, sorted, str, sum, tuple, zip)} pow, repr, reversed, round, set, six, sorted, str, sum, tuple, zip)}
def _assert(x, *args): def _assert(x, *args):
if x: if x:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment