Here is the issue just created: 
https://github.com/ansible/ansible/issues/5865

Thanks
Jack

On Monday, February 3, 2014 1:20:54 PM UTC-8, Michael DeHaan wrote:
>
> This is probably not something the system is templating out, but should.
>
> Please make sure you have filed a github.com/ansible/ansible ticket with 
> the above info so we can add templating to this call.
>
> Thanks!
>
>
> On Mon, Feb 3, 2014 at 4:11 PM, jack <jackm...@gmail.com <javascript:>>wrote:
>
>> Hi, 
>>
>> we are trying to use the variable for the value of retries at loop. But 
>> always hit an error. We are using ansible version 1.4.3.
>>
>> Here is the sample test playbook:
>>
>> - hosts: test-servers
>>   vars:
>>     tries: 5
>>   tasks:
>>     - name: test
>>       debug: msg="looping"
>>       register: output
>>       until: no
>>       retries: "{{ tries | int }}"
>>       delay: 1
>>
>> Here is the error we got:
>>
>> TASK: [test] 
>> ******************************************************************
>> fatal: [test01] => Traceback (most recent call last):
>>   File "/usr/lib/python2.6/site-packages/ansible/runner/__init__.py", 
>> line 394, in _executor
>>     exec_rc = self._executor_internal(host, new_stdin)
>>   File "/usr/lib/python2.6/site-packages/ansible/runner/__init__.py", 
>> line 485, in _executor_internal
>>     return self._executor_internal_inner(host, self.module_name, 
>> self.module_args, inject, port, complex_args=complex_args)
>>   File "/usr/lib/python2.6/site-packages/ansible/runner/__init__.py", 
>> line 694, in _executor_internal_inner
>>     for x in range(1, retries + 1):
>> TypeError: cannot concatenate 'str' and 'int' objects
>>
>>
>> FATAL: all hosts have already failed -- aborting
>>
>> Does anyone have some idea? Appreciate your help. 
>>
>> Thanks
>> Jack
>>
>> -- 
>> 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-proje...@googlegroups.com <javascript:>.
>> To post to this group, send email to ansible...@googlegroups.com<javascript:>
>> .
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>
>
> -- 
> Michael DeHaan <mic...@ansible.com <javascript:>>
> CTO, Ansible, Inc.
> http://www.ansible.com/ <http://www.ansibleworks.com/>
>
>  

-- 
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 post to this group, send email to ansible-project@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to