Commit 17e086fe by Brian Coca

dont break everything when one of the vars in inject does not template…

dont break everything when one of the vars  in inject does not template correctly, wait till its used
parent 57ed9947
......@@ -188,7 +188,11 @@ class _jinja2_vars(object):
if isinstance(var, dict) and varname == "vars" or isinstance(var, HostVars):
return var
else:
try:
return template(self.basedir, var, self.vars, fail_on_undefined=self.fail_on_undefined)
except:
raise KeyError("undefined variable: %s" % varname)
def add_locals(self, locals):
'''
......
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