mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Ensure we raise the exception caught _post_validate_environment->_parse_env_kv. Fixes #41322 (#41411)
This commit is contained in:
parent
5b0bb91c72
commit
3832d04611
1 changed files with 2 additions and 1 deletions
|
@ -280,7 +280,8 @@ class Task(Base, Conditional, Taggable, Become):
|
||||||
except AnsibleUndefinedVariable as e:
|
except AnsibleUndefinedVariable as e:
|
||||||
if self.action in ('setup', 'gather_facts') and 'ansible_env' in to_native(e):
|
if self.action in ('setup', 'gather_facts') and 'ansible_env' in to_native(e):
|
||||||
# ignore as fact gathering sets ansible_env
|
# ignore as fact gathering sets ansible_env
|
||||||
pass
|
return
|
||||||
|
raise
|
||||||
|
|
||||||
if isinstance(value, list):
|
if isinstance(value, list):
|
||||||
for env_item in value:
|
for env_item in value:
|
||||||
|
|
Loading…
Reference in a new issue