From ca42945264c9a5d0663bae89949b0aa062895eba Mon Sep 17 00:00:00 2001 From: ohemorange Date: Tue, 20 Nov 2018 18:39:12 -0500 Subject: [PATCH] Fix test_sdists test farm test (#6524) * Switch to using _venv_common.py in test_sdists.sh * Upgrade setuptools in _venv_common.py * Upgrade setuptools before running pip_install --- tests/letstest/scripts/test_sdists.sh | 2 +- tools/_venv_common.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/letstest/scripts/test_sdists.sh b/tests/letstest/scripts/test_sdists.sh index f18a64065..0b9a91ffd 100755 --- a/tests/letstest/scripts/test_sdists.sh +++ b/tests/letstest/scripts/test_sdists.sh @@ -10,7 +10,7 @@ VERSION=$(letsencrypt-auto-source/version.py) export VENV_ARGS="-p $PYTHON" # setup venv -tools/_venv_common.sh --requirement letsencrypt-auto-source/pieces/dependency-requirements.txt +tools/_venv_common.py --requirement letsencrypt-auto-source/pieces/dependency-requirements.txt . ./venv/bin/activate # build sdists diff --git a/tools/_venv_common.py b/tools/_venv_common.py index 2a48b0d2e..ecd438f94 100755 --- a/tools/_venv_common.py +++ b/tools/_venv_common.py @@ -149,13 +149,15 @@ def main(venv_name, venv_args, args): command.extend(shlex.split(venv_args)) subprocess_with_print(command) - # We execute the two following commands in the context of the virtual environment, to install + # We execute the following commands in the context of the virtual environment, to install # the packages in it. To do so, we append the venv binary to the PATH that will be used for # these commands. With this trick, correct python executable will be selected. new_environ = os.environ.copy() new_environ['PATH'] = os.pathsep.join([get_venv_bin_path(venv_name), new_environ['PATH']]) subprocess_with_print('python {0}'.format('./letsencrypt-auto-source/pieces/pipstrap.py'), env=new_environ, shell=True) + subprocess_with_print("python -m pip install --upgrade 'setuptools>=30.3'", + env=new_environ, shell=True) subprocess_with_print('python {0} {1}'.format('./tools/pip_install.py', ' '.join(args)), env=new_environ, shell=True)