Skip to content

Commit 00e70ff

Browse files
committed
Correctly handle failed pip/setuptools/wheel installs (#1007)
They are now displayed in the build output (instead of being sent to `/dev/null`) and fail the build early instead of failing later in `bin/steps/pip-install`. Fixes #1002.
1 parent 60f2fac commit 00e70ff

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
- For repeat builds, also manage the installed versions of setuptools/wheel, rather than just that of pip (#1007).
66
- Install an explicit version of wheel rather than the latest release at the time (#1007).
77
- Output the installed version of pip, setuptools and wheel in the build log (#1007).
8+
- Errors installing pip/setuptools/wheel are now displayed in the build output and fail the build early (#1007).
89
- Install pip using itself rather than `get-pip.py` (#1007).
910
- Disable pip's version check + cache when installing pip/setuptools/wheel (#1007).
1011
- Install setuptools from PyPI rather than a vendored copy (#1007).

bin/steps/python

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,8 @@ if [ ! "$SKIP_INSTALL" ]; then
135135
hash -r
136136
fi
137137

138+
set -e
139+
138140
PIP_VERSION='20.0.2'
139141
SETUPTOOLS_VERSION='39.0.1'
140142
WHEEL_VERSION='0.34.2'
@@ -174,8 +176,7 @@ fi
174176

175177
puts-step "Installing pip ${PIP_VERSION}, setuptools ${SETUPTOOLS_VERSION} and wheel ${WHEEL_VERSION}"
176178

177-
/app/.heroku/python/bin/python "${PIP_WHEEL}/pip" install --disable-pip-version-check --no-cache \
178-
"${PIP_TO_INSTALL}" "setuptools==${SETUPTOOLS_VERSION}" "wheel==${WHEEL_VERSION}" &> /dev/null
179+
/app/.heroku/python/bin/python "${PIP_WHEEL}/pip" install --quiet --disable-pip-version-check --no-cache \
180+
"${PIP_TO_INSTALL}" "setuptools==${SETUPTOOLS_VERSION}" "wheel==${WHEEL_VERSION}"
179181

180-
set -e
181182
hash -r

0 commit comments

Comments
 (0)