mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-27 21:01:27 -07:00
remove default from delegate_facts to inherit (#45492)
* remove default from delegate_facts to inherit fixes #45456 * test delegate_facts * added note about inheritance and defaults * yamllint
This commit is contained in:
parent
58aaf53271
commit
8743e6ae2e
5 changed files with 34 additions and 3 deletions
|
@ -66,6 +66,10 @@ class Task(Base, Conditional, Taggable, Become):
|
|||
# will be used if defined
|
||||
# might be possible to define others
|
||||
|
||||
# NOTE: ONLY set defaults on task attributes that are not inheritable,
|
||||
# inheritance is only triggered if the 'current value' is None,
|
||||
# default can be set at play/top level object and inheritance will take it's course.
|
||||
|
||||
_args = FieldAttribute(isa='dict', default=dict())
|
||||
_action = FieldAttribute(isa='string')
|
||||
|
||||
|
@ -73,7 +77,7 @@ class Task(Base, Conditional, Taggable, Become):
|
|||
_changed_when = FieldAttribute(isa='list', default=[])
|
||||
_delay = FieldAttribute(isa='int', default=5)
|
||||
_delegate_to = FieldAttribute(isa='string')
|
||||
_delegate_facts = FieldAttribute(isa='bool', default=False)
|
||||
_delegate_facts = FieldAttribute(isa='bool')
|
||||
_failed_when = FieldAttribute(isa='list', default=[])
|
||||
_loop = FieldAttribute()
|
||||
_loop_control = FieldAttribute(isa='class', class_type=LoopControl, inherit=False)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue