# Modify warning display during playbook execution

**URL:** <https://forum.ansible.com/t/modify-warning-display-during-playbook-execution/37139>\
**Category:** Ansible Developer\
**Created:** [September 23, 2022, 12:59pm UTC](https://forum.ansible.com/t/modify-warning-display-during-playbook-execution/37139 "2022-09-23T12:59:45Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jonathan\_Renon](https://avatars.discourse-cdn.com/v4/letter/j/b38774/32.png) [@Jonathan\_Renon](https://forum.ansible.com/u/Jonathan_Renon)\
**Post date:** [September 23, 2022, 12:59pm UTC](https://forum.ansible.com/t/modify-warning-display-during-playbook-execution/37139/1 "2022-09-23T12:59:45Z")

</div>

Hello,  
I’m trying to silence some specific warnings from playbook output in ansible-2.9.27.  
I tried creating a custom callback plugin based on the default callback plugin.  
overloading \_handle\_warnings(self, res): method did not change anything.

the warning I’m trying to suppress are from:  
lib/ansible/executor/task\_executor.py:  
`[WARNING]: Using a variable for a task's 'args' is unsafe in some situations (see https://docs.ansible.com/ansible/devel/reference_appendices/faq.html#argsplat-unsafe)`

lib/ansible/plugins/action/raw.py:

`[WARNING]: raw module does not support the environment keyword`

how can I stop these warning without silencing all warnings via ansible.cfg options or env variable equivalent.

Thank you for your help
