mirror of https://github.com/ansible/ansible.git
actionable.py: Do not print next task banner in handler callback (#15698)
Fix actionable callback plugin to not print the banner of the previous task. When a handler is executed there is no task banner, so in case it is run, it will reference the banner from the preceding task. **Author:** @hvhaugwitz Test case: --- - name: actionable filter hosts: all handlers: - name: handler command: "true" tasks: - name: task 1 file: path=/tmp/test state=touch notify: handler - name: task 2 file: path=/tmp/test state=absent - name: task 3 file: path=/tmp/test state=absent - name: task 4 file: path=/tmp/test state=absent - name: task 5 file: path=/tmp/test state=absent - name: task 6 file: path=/tmp/test state=absent Example output: BEFORE ------ PLAY [actionable filter] ******************************************************* TASK [task 1] ****************************************************************** changed: [localhost] TASK [task 2] ****************************************************************** changed: [localhost] RUNNING HANDLER [handler] ****************************************************** TASK [task 6] ****************************************************************** changed: [localhost] PLAY RECAP ********************************************************************* localhost : ok=8 changed=3 unreachable=0 failed=0 AFTER ----- PLAY [actionable filter] ******************************************************* TASK [task 1] ****************************************************************** changed: [localhost] TASK [task 2] ****************************************************************** changed: [localhost] RUNNING HANDLER [handler] ****************************************************** changed: [localhost] PLAY RECAP ********************************************************************* localhost : ok=8 changed=3 unreachable=0 failed=0pull/15708/head
parent
47d58c30e4
commit
87648f7bdf
Loading…
Reference in New Issue