From 5b749ff8f79303aa60d1dce166c40e7095c31876 Mon Sep 17 00:00:00 2001 From: Brad Warren Date: Mon, 20 Apr 2020 14:44:53 -0700 Subject: [PATCH] Use Python 3 in the release script. (#7918) Fixes #7902. --- tools/_release.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/_release.sh b/tools/_release.sh index 97d5f5eb8..7e483905e 100755 --- a/tools/_release.sh +++ b/tools/_release.sh @@ -59,7 +59,7 @@ mv "dist.$version" "dist.$version.$(date +%s).bak" || true git tag --delete "$tag" || true tmpvenv=$(mktemp -d) -VIRTUALENV_NO_DOWNLOAD=1 virtualenv -p python2 $tmpvenv +python3 -m venv "$tmpvenv" . $tmpvenv/bin/activate # update setuptools/pip just like in other places in the repo pip install -U setuptools @@ -157,7 +157,7 @@ done echo "Testing packages" cd "dist.$version" # start local PyPI -python -m SimpleHTTPServer $PORT & +python -m http.server $PORT & # cd .. is NOT done on purpose: we make sure that all subpackages are # installed from local PyPI rather than current directory (repo root) VIRTUALENV_NO_DOWNLOAD=1 virtualenv ../venv @@ -202,7 +202,7 @@ done # pin pip hashes of the things we just built for pkg in $SUBPKGS_IN_AUTO ; do echo $pkg==$version \\ - pip hash dist."$version/$pkg"/*.{whl,gz} | grep "^--hash" | python2 -c 'from sys import stdin; input = stdin.read(); print " ", input.replace("\n--hash", " \\\n --hash"),' + pip hash dist."$version/$pkg"/*.{whl,gz} | grep "^--hash" | python -c 'from sys import stdin; input = stdin.read(); print(" ", input.replace("\n--hash", " \\\n --hash"), end="")' done > letsencrypt-auto-source/pieces/certbot-requirements.txt deactivate