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

Don't mark host as having gathered facts when peeking at next task

Fixes #14243
This commit is contained in:
James Cammarata 2016-02-02 10:22:08 -05:00
parent 6105c8c77c
commit b2c0abe998

View file

@ -255,10 +255,11 @@ class PlayIterator:
(gathering == 'explicit' and boolean(self._play.gather_facts)) or \
(gathering == 'smart' and implied and not host._gathered_facts):
# mark the host as having gathered facts
host.set_gathered_facts(True)
setup_block = self._blocks[0]
if setup_block.has_tasks() and len(setup_block.block) > 0:
task = setup_block.block[0]
if not peek:
host.set_gathered_facts(True)
else:
state.pending_setup = False