From a639da7c44472503f88bf3de66647686d01e4839 Mon Sep 17 00:00:00 2001 From: Brian Coca Date: Wed, 7 Oct 2015 12:18:36 -0400 Subject: [PATCH] default chdir to tmpdir to avoid virtualenv issues --- packaging/language/pip.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packaging/language/pip.py b/packaging/language/pip.py index 30adce43ef1..e587fad920f 100644 --- a/packaging/language/pip.py +++ b/packaging/language/pip.py @@ -258,6 +258,9 @@ def main(): if state == 'latest' and version is not None: module.fail_json(msg='version is incompatible with state=latest') + if chdir is None: + chdir = tempfile.gettempdir() + err = '' out = ''