# "flush\_handlers task does not support when conditional"...??

**URL:** <https://forum.ansible.com/t/flush-handlers-task-does-not-support-when-conditional/29153>\
**Category:** Ansible Project\
**Created:** [November 29, 2018, 7:09pm UTC](https://forum.ansible.com/t/flush-handlers-task-does-not-support-when-conditional/29153 "2018-11-29T19:09:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Frank\_Thommen](https://avatars.discourse-cdn.com/v4/letter/f/7feea3/32.png) [@Frank\_Thommen](https://forum.ansible.com/u/Frank_Thommen)\
**Post date:** [November 29, 2018, 7:09pm UTC](https://forum.ansible.com/t/flush-handlers-task-does-not-support-when-conditional/29153/1 "2018-11-29T19:09:23Z")

</div>

Hello,

our latest yum update brought ansible from 2.4.2.0 to 2.7.2 and now we are facing

&nbsp;&nbsp;&nbsp;&nbsp;[WARNING]: flush\_handlers task does not support when conditional

we need the handlers to be flushed at that point, as later tasks rely on previously reconfigured services to be reloaded. The "when" originates from our role definition:

---

<div class="post-metadata">

**Author:** ![sivel](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/sivel/32/1198_2.png) [@sivel](https://forum.ansible.com/u/sivel)\
**Post date:** [November 29, 2018, 7:15pm UTC](https://forum.ansible.com/t/flush-handlers-task-does-not-support-when-conditional/29153/2 "2018-11-29T19:15:34Z")

</div>

A when statement supplied to flush\_handlers has never worked. It was silently ignored in the past, but now has a warning.

There is an open feature request to allow this to work:  
[https://github.com/ansible/ansible/issues/41313](https://github.com/ansible/ansible/issues/41313)

---

<div class="post-metadata">

**Author:** ![Frank\_Thommen](https://avatars.discourse-cdn.com/v4/letter/f/7feea3/32.png) [@Frank\_Thommen](https://forum.ansible.com/u/Frank_Thommen)\
**Post date:** [November 29, 2018, 7:27pm UTC](https://forum.ansible.com/t/flush-handlers-task-does-not-support-when-conditional/29153/3 "2018-11-29T19:27:11Z")

</div>

Hmm. That would explain some random issues that we had in the past with this playbook
