From ad996f162b4ce1683c2ced63aa27715469d831dd Mon Sep 17 00:00:00 2001 From: Brian Coca Date: Tue, 5 Jul 2016 16:47:57 -0400 Subject: [PATCH] name was the issue, not pkg --- lib/ansible/modules/packaging/language/pip.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/ansible/modules/packaging/language/pip.py b/lib/ansible/modules/packaging/language/pip.py index eed16fd4a53..d7f832f0924 100755 --- a/lib/ansible/modules/packaging/language/pip.py +++ b/lib/ansible/modules/packaging/language/pip.py @@ -368,7 +368,7 @@ def main(): # Automatically apply -e option to extra_args when source is a VCS url. VCS # includes those beginning with svn+, git+, hg+ or bzr+ has_vcs = False - if pkg: + if name: for pkg in name: if bool(pkg and re.match(r'(svn|git|hg|bzr)\+', pkg)): has_vcs = True @@ -386,7 +386,7 @@ def main(): if extra_args: cmd += ' %s' % extra_args - if pkg: + if name: for pkg in name: cmd += ' %s' % _get_full_name(pkg, version) else: @@ -410,7 +410,7 @@ def main(): out += out_pip err += err_pip - if pkg: + if name: for pkg in name: is_present = _is_present(pkg, version, out.split()) if (state == 'present' and not is_present) or (state == 'absent' and is_present):