How do I make changes to the below complex when condition without breaking 
the code in order to address the warning. 

 - debug: msg: "Hi"
         when: entrycurrdb.stdout.find("{{ 
hostvars['localhost']['BASEPATH_FINAL'] }}/{{ vars[(item | 
splitext)[1].split('.')[1] | default('exe')] }}/{{ item | basename }}") == -
1 and actualfile.stat.exists == True

Getting warning

Output:


TASK [debug] 
> *******************************************************************
> [WARNING]: conditional statements should not include jinja2 templating
> delimiters such as {{ }} or {% %}. Found: entrycurrdb.stdout.find("{{
> hostvars['localhost']['BASEPATH_FINAL'] }}/{{ vars[(item |
> splitext)[1].split('.')[1] | default('exe')] }}/{{ item | basename }}") == 
> -1
> and actualfile.stat.exists == True
> changed: [10.0.0.16]


Kindly suggests. 

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/40f2ed22-985b-4fe3-8fd1-b509f497551f%40googlegroups.com.

Reply via email to