aboutsummaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
Diffstat (limited to 'utils')
-rw-r--r--utils/agljobtemplate.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/utils/agljobtemplate.py b/utils/agljobtemplate.py
index 381f7f4..90bad13 100644
--- a/utils/agljobtemplate.py
+++ b/utils/agljobtemplate.py
@@ -48,6 +48,10 @@ class Agljobtemplate(object):
RFS_TYPE = ['nbd', 'ramdisk']
def __init__(self, path=DEFAULT_PATH):
+ try:
+ from jinja2 import select_autoescape
+ except ImportError:
+ raise ImportError, "Please make sure your version of jinja2 is >= 2.9"
self._template_path = os.path.normpath(path)
if not (os.path.isdir(self._template_path) and os.access(self._template_path, os.F_OK)):
raise OSError, "Cannot access {}".format(self._template_path)