diff --git a/library/packaging/easy_install b/library/packaging/easy_install index a18b2f7d70..4110ce154a 100644 --- a/library/packaging/easy_install +++ b/library/packaging/easy_install @@ -94,7 +94,6 @@ def main(): name = module.params['name'] env = module.params['virtualenv'] - easy_install = module.get_bin_path('easy_install', True, ['%s/bin' % env]) site_packages = module.params['virtualenv_site_packages'] virtualenv_command = module.params['virtualenv_command'] @@ -117,6 +116,8 @@ def main(): out += out_venv err += err_venv + easy_install = module.get_bin_path('easy_install', True, ['%s/bin' % env]) + cmd = None changed = False installed = _is_package_installed(module, name, easy_install)