1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Properly catch AnsibleError and not all errors

This commit is contained in:
James Cammarata 2015-07-13 16:20:19 -04:00
parent 2b723c6130
commit 9a586c3512

View file

@ -209,7 +209,7 @@ class VariableManager:
break break
else: else:
raise AnsibleError("vars file %s was not found" % vars_file_item) raise AnsibleError("vars file %s was not found" % vars_file_item)
except: except AnsibleError, e:
# FIXME: get_vars should probably be taking a flag to determine # FIXME: get_vars should probably be taking a flag to determine
# whether or not vars files errors should be fatal at this # whether or not vars files errors should be fatal at this
# stage, or just base it on whether a host was specified? # stage, or just base it on whether a host was specified?