extra_vars_dict: handle the case where an entire yaml file is commented

This commit is contained in:
Chris Meyers 2015-01-23 11:00:16 -05:00
parent 7e822c34d5
commit fad5fb5f58

View File

@ -90,6 +90,9 @@ class VarsDictProperty(object):
if d is None:
try:
d = yaml.safe_load(v)
# This can happen if the whole file is commented out
if d is None:
d = {}
except yaml.YAMLError:
pass
if d is None and self.key_value: