From b6261d05b0dc27974f0d0fb041d1df029bd24b28 Mon Sep 17 00:00:00 2001 From: Cristian Ciupitu Date: Thu, 14 Aug 2014 16:41:35 +0300 Subject: [PATCH] Fix typo: & -> and `and` is the boolean operator for AND in [Python][1]. `&` is the bitwise operator for AND in [Python][2]. [1]: https://docs.python.org/2/reference/expressions.html#boolean-operations [2]: https://docs.python.org/2/reference/expressions.html#binary-bitwise-operations --- lib/ansible/runner/poller.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ansible/runner/poller.py b/lib/ansible/runner/poller.py index 8bb30ed8fb..5fd3537480 100644 --- a/lib/ansible/runner/poller.py +++ b/lib/ansible/runner/poller.py @@ -32,7 +32,7 @@ class AsyncPoller(object): # flag to determine if at least one host was contacted self.active = False - # True to work with & below + # True to work with the `and` below skipped = True jid = None for (host, res) in results['contacted'].iteritems(): @@ -42,7 +42,7 @@ class AsyncPoller(object): self.runner.vars_cache[host]['ansible_job_id'] = jid self.active = True else: - skipped = skipped & res.get('skipped', False) + skipped = skipped and res.get('skipped', False) self.results['contacted'][host] = res for (host, res) in results['dark'].iteritems(): self.runner.vars_cache[host]['ansible_job_id'] = ''