diff --git a/changelogs/fragments/undeprecate_force_pc.yml b/changelogs/fragments/undeprecate_force_pc.yml new file mode 100644 index 0000000000..565fa7b7a2 --- /dev/null +++ b/changelogs/fragments/undeprecate_force_pc.yml @@ -0,0 +1,2 @@ +bugfixes: + - remove deprecation notice since validation makes it very noisy diff --git a/lib/ansible/playbook/play_context.py b/lib/ansible/playbook/play_context.py index 3f3e7d482e..4159cb96f5 100644 --- a/lib/ansible/playbook/play_context.py +++ b/lib/ansible/playbook/play_context.py @@ -127,10 +127,13 @@ class PlayContext(Base): _verbosity = FieldAttribute(isa='int', default=0) _only_tags = FieldAttribute(isa='set', default=set) _skip_tags = FieldAttribute(isa='set', default=set) - _force_handlers = FieldAttribute(isa='bool', default=False) + _start_at_task = FieldAttribute(isa='string') _step = FieldAttribute(isa='bool', default=False) + # "PlayContext.force_handlers should not be used, the calling code should be using play itself instead" + _force_handlers = FieldAttribute(isa='bool', default=False) + def __init__(self, play=None, passwords=None, connection_lockfd=None): # Note: play is really not optional. The only time it could be omitted is when we create # a PlayContext just so we can invoke its deserialize method to load it from a serialized @@ -345,13 +348,6 @@ class PlayContext(Base): def set_become_plugin(self, plugin): self._become_plugin = plugin - def _get_attr_force_handlers(self): - display.deprecated( - "PlayContext.force_handlers should not be used, the calling code should be using play itself instead", - version="2.19" - ) - return self._attributes.get('force_handlers', None) - def make_become_cmd(self, cmd, executable=None): """ helper function to create privilege escalation commands """ display.deprecated(