mirror of https://github.com/ansible/ansible.git
_get_next_task_from_state should not mutate anyting outside of state (#78657)
Fixes #78612pull/78667/head
parent
38c3b5e8f1
commit
19e7c5b0c1
@ -0,0 +1,2 @@
|
||||
bugfixes:
|
||||
- "Fix an issue where ``ansible_play_hosts`` and ``ansible_play_batch`` were not properly updated when a failure occured in an explicit block inside the rescue section (https://github.com/ansible/ansible/issues/78612)"
|
@ -0,0 +1,16 @@
|
||||
- hosts: all
|
||||
gather_facts: false
|
||||
tasks:
|
||||
- block:
|
||||
- fail:
|
||||
when: inventory_hostname == 'host1'
|
||||
rescue:
|
||||
- block:
|
||||
- fail:
|
||||
when: inventory_hostname == 'host1'
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "'host1' not in ansible_play_hosts"
|
||||
- "'host1' not in ansible_play_batch"
|
||||
success_msg: PASSED
|
Loading…
Reference in New Issue