mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
Namespaced facts fixes (#26615)
* shorten warning on reservd fact collision also remove ansible_ from namespaced facts for vars manager handle str conversion errors use tuple to avoid iterator errors version added added * only modify final one * removed ansible_ removal
This commit is contained in:
@@ -566,9 +566,7 @@ class TaskExecutor:
|
||||
return failed_when_result
|
||||
|
||||
if 'ansible_facts' in result:
|
||||
if not C.NAMESPACE_FACTS:
|
||||
vars_copy.update(result['ansible_facts'])
|
||||
vars_copy.update({'ansible_facts': result['ansible_facts']})
|
||||
vars_copy.update(result['ansible_facts'])
|
||||
|
||||
# set the failed property if it was missing.
|
||||
if 'failed' not in result:
|
||||
@@ -614,9 +612,7 @@ class TaskExecutor:
|
||||
variables[self._task.register] = wrap_var(result)
|
||||
|
||||
if 'ansible_facts' in result:
|
||||
if not C.NAMESPACE_FACTS:
|
||||
variables.update(result['ansible_facts'])
|
||||
variables.update({'ansible_facts': result['ansible_facts']})
|
||||
variables.update(result['ansible_facts'])
|
||||
|
||||
# save the notification target in the result, if it was specified, as
|
||||
# this task may be running in a loop in which case the notification
|
||||
|
||||
Reference in New Issue
Block a user