how limit uri module retries output

I am using uri module with retries until: (result | success),

ansible is logging whole HTTP Request information including username and password.

is there way to disable logging on retries failures? no_log=true is not helping here.

Here is my task

uri:
url: “https://localhost:1567/api/aliveness-test
user: “{{admin_username}}”
password: “{{admin_password}}”
validate_certs: no
register: result
until: “(result | success) and (result.status == 200)”
retries: 40
delay: 30
with_items: “{{clusters_elb_facts.elbs}}”
ignore_errors: “true”
no_log: True

Log
FAILED - RETRYING: TASK: wait for api to come up (39 retries left). Result was: {‘invocation’: {‘module_name’: u’uri’, u’module_args’: {u’directory_mode’: None, u’force’: None, u’remote_src’: None, u’follow_redirects’: u’safe’, u’body_format’: u’raw’, u’owner’: None, u’follow’: False, u’group’: None, u’serole’: None, u’content’: None, u’setype’: None, u’status_code’: [200], u’return_content’: False, u’method’: u’GET’, u’body’: None, u’dest’: None, u’selevel’: None, u’force_basic_auth’: False, u’removes’: None, u’user’: u’api-user’, u’regexp’: None, u’password’: u’abcd1234’, u’src’: None, u’_ansible_no_log’: True, u’url’: u’https://internal-ism-a-dev-1021862535.us-east-1.elb.amazonaws.com:156721/api/aliveness-test/digital’, u’backup’: None, u’seuser’: None, u’creates’: None, u’delimiter’: None, u’mode’: None, u’timeout’: 30, u’validate_certs’: False}}, u’msg’: u’Unable to resolve the host name given.‘, u’failed’: True}

no_log: True is working as expected if i remove retires…

not sure if it is a bug with retires or is there any other workaround?

uri:
url: “https://localhost:1567/api/aliveness-test
user: “{{admin_username}}”
password: “{{admin_password}}”
validate_certs: no
register: result
with_items: “{{clusters_elb_facts.elbs}}”
ignore_errors: “true”
no_log: True

i think i found the root cause. below code from line number 413 @task_executor.py should be split to two statements.

display.display(“FAILED - RETRYING: %s (%d retries left). Result was: %s” % (self._task, retries-attempt, result), color=C.COLOR_DEBUG)

to

display.display("FAILED - RETRYING: %s (%d retries left)., color=C.COLOR_DEBUG)
display.debug(“Result was: %s” % (self._task, retries-attempt, result), color=C.COLOR_DEBUG)

fixed via http://github.com/ansible/ansible/commit/e02b98274b60cdbc12ef4a4c74ae0f74207384e8