Multiple Loop Vars Problem

Hi,

I am trying to pass each item from a list using “with_items” and trying to control it using “loop_control” & “loop_vars”.But when I have defined another “loop_control” & “loop_vars” along with “with_items”.The playbook is throwing error.Below are the 2 playbooks details:

main.yml

expected, since when you include in the first task, outer_item2 is not
defined. use `deafult` filter to avoid the errors.

this should get it working for both includes:

- debug:
   msg: "outer item={{ outer_item|default('none') }} inner item={{
item }} outer2 item={{ outer_item2|default('none') }}"
with_items:
     - a
     - b
     - c

Thanks Brain that worked for me.