# Passing variables via nested include\_role doesn't work Ticket #17686. Closed but still not working.

**URL:** <https://forum.ansible.com/t/passing-variables-via-nested-include-role-doesnt-work-ticket-17686-closed-but-still-not-working/23038>\
**Category:** Ansible Developer\
**Created:** [November 16, 2016, 4:23am UTC](https://forum.ansible.com/t/passing-variables-via-nested-include-role-doesnt-work-ticket-17686-closed-but-still-not-working/23038 "2016-11-16T04:23:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jorge\_Moraleda](https://avatars.discourse-cdn.com/v4/letter/j/ecccb3/32.png) [@Jorge\_Moraleda](https://forum.ansible.com/u/Jorge_Moraleda)\
**Post date:** [November 16, 2016, 4:23am UTC](https://forum.ansible.com/t/passing-variables-via-nested-include-role-doesnt-work-ticket-17686-closed-but-still-not-working/23038/1 "2016-11-16T04:23:49Z")

</div>

# I believe variable resolution in nested add\_role is still not working properly. For example if we change the example shown in the ticket above such that instead of the line

b: “{{ a+1 }}”  
in ./roles/a/tasks/main.yml where (a is a variable that was passed to the add\_role) we had instead  
b: “{{a\_defaults\_var}}”  
where a\_defaults\_var was a variable _not passed_ to the add\_role. (It was for example defined in roles/a/defaults/main.yml) then we get a a\_defaults\_var not defined.

---

<div class="post-metadata">

**Author:** ![Jorge\_Moraleda](https://avatars.discourse-cdn.com/v4/letter/j/ecccb3/32.png) [@Jorge\_Moraleda](https://forum.ansible.com/u/Jorge_Moraleda)\
**Post date:** [November 16, 2016, 4:28am UTC](https://forum.ansible.com/t/passing-variables-via-nested-include-role-doesnt-work-ticket-17686-closed-but-still-not-working/23038/2 "2016-11-16T04:28:48Z")

</div>

Actually I just observed that a separate bug report has been filed and is still open about this exact issue in:# “include\_role : troubleshooting passing variables #18217”
