Skip to content

Commit f260cb7

Browse files
committed
Update pip to 20.1.1
Updates pip from 20.0.2 to 20.1.1 for Python 2.7 and Python 3.5+: https://pip.pypa.io/en/stable/news/#id40 The version used for Python 3.4 remains unchanged at 19.1.1, since it's the last version of pip that supports it. Pip has been updated to 20.1.1 rather than the recently released 20.2, since the latter has a few regressions and even though these will be fixed shortly in 20.2.1, we should let the changes soak for longer before picking them up. The `PIP_NO_PYTHON_VERSION_WARNING` environment variable has been set (equivalent to passing `--no-python-version-warning`) to prevent the Python 2.7 EOL warnings added in pip 20.1 from spamming the build log: https://github.com/pypa/pip/blob/20.1.1/src/pip/_internal/cli/base_command.py#L139-L154 This was set via environment variable rather than CLI flag, since: * otherwise we'd have to pass it to every pip invocation * older pip (such as the 19.1.1 used by Python 3.4) doesn't support this option and would error out due to an unknown CLI flag being passed, unless we added conditional flags throughout. The new pip wheel was uploaded to S3 using: ``` $ pip download --no-cache pip==20.1.1 Collecting pip==20.1.1 Downloading pip-20.1.1-py2.py3-none-any.whl (1.5 MB) Saved ./pip-20.1.1-py2.py3-none-any.whl Successfully downloaded pip $ aws s3 sync . s3://lang-python/common/ --exclude "*" --include "*.whl" --acl public-read --dryrun (dryrun) upload: ./pip-20.1.1-py2.py3-none-any.whl to s3://lang-python/common/pip-20.1.1-py2.py3-none-any.whl $ aws s3 sync . s3://lang-python/common/ --exclude "*" --include "*.whl" --acl public-read upload: ./pip-20.1.1-py2.py3-none-any.whl to s3://lang-python/common/pip-20.1.1-py2.py3-none-any.whl ``` Fixes #1005. @W-7659489@
1 parent 6fa6feb commit f260cb7

File tree

5 files changed

+15
-9
lines changed

5 files changed

+15
-9
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
# Unreleased
44

5+
- Update pip from 20.0.2 to 20.1.1 for Python 2.7 and Python 3.5+ (#1030).
56
- Update setuptools from 39.0.1 to: (#1024)
67
- 44.1.1 for Python 2.7
78
- 43.0.0 for Python 3.4

bin/compile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,10 @@ export LIBRARY_PATH=/app/.heroku/vendor/lib:/app/.heroku/python/lib:$LIBRARY_PAT
137137
export LD_LIBRARY_PATH=/app/.heroku/vendor/lib:/app/.heroku/python/lib:$LD_LIBRARY_PATH
138138
export PKG_CONFIG_PATH=/app/.heroku/vendor/lib/pkg-config:/app/.heroku/python/lib/pkg-config:$PKG_CONFIG_PATH
139139

140+
# Global pip options (https://pip.pypa.io/en/stable/user_guide/#environment-variables).
141+
# Disable pip's warnings about EOL Python since we show our own.
142+
export PIP_NO_PYTHON_VERSION_WARNING=1
143+
140144
# The Application Code
141145
# --------------------
142146

bin/steps/python

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ fi
137137

138138
set -e
139139

140-
PIP_VERSION='20.0.2'
140+
PIP_VERSION='20.1.1'
141141
# Must use setuptools <47.2.0 until we fix:
142142
# https://github.com/heroku/heroku-buildpack-python/issues/1006
143143
SETUPTOOLS_VERSION='47.1.1'

test/run-features

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ testHooks() {
108108
LIBRARY_PATH
109109
OLDPWD
110110
PATH
111+
PIP_NO_PYTHON_VERSION_WARNING
111112
PKG_CONFIG_PATH
112113
PROFILE_PATH
113114
PWD

test/run-versions

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ testPythonDefault() {
99
compile "pythonDefault"
1010
assertCaptured $DEFAULT_PYTHON_VERSION
1111
assertNotCaptured "security update"
12-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
12+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
1313
assertCaptured "Installing SQLite3"
1414
assertCapturedSuccess
1515
}
@@ -25,7 +25,7 @@ testPython2() {
2525
assertNotCaptured "python-2-7-eol-faq";
2626
fi
2727
assertNotCaptured "security update"
28-
assertCaptured "Installing pip 20.0.2, setuptools 44.1.1 and wheel 0.34.2"
28+
assertCaptured "Installing pip 20.1.1, setuptools 44.1.1 and wheel 0.34.2"
2929
assertCaptured "Installing SQLite3"
3030
assertCapturedSuccess
3131
}
@@ -89,7 +89,7 @@ testPython3_5() {
8989
compile "python3_5"
9090
assertCaptured $LATEST_35
9191
assertNotCaptured "security update"
92-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
92+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
9393
assertCaptured "Installing SQLite3"
9494
assertCapturedSuccess
9595
}
@@ -112,7 +112,7 @@ testPython3_6() {
112112
compile "python3_6"
113113
assertCaptured $LATEST_36
114114
assertNotCaptured "security update"
115-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
115+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
116116
assertCaptured "Installing SQLite3"
117117
assertCapturedSuccess
118118
}
@@ -139,7 +139,7 @@ testPython3_7() {
139139
else
140140
assertNotCaptured "security update"
141141
assertCaptured $LATEST_37
142-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
142+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
143143
assertCaptured "Installing SQLite3"
144144
assertCapturedSuccess
145145
fi
@@ -183,7 +183,7 @@ testPython3_8() {
183183
else
184184
assertNotCaptured "security update"
185185
assertCaptured $LATEST_38
186-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
186+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
187187
assertCaptured "Installing SQLite3"
188188
assertCapturedSuccess
189189
fi
@@ -202,7 +202,7 @@ testPypy3_6() {
202202
else
203203
assertCaptured "Installing pypy"
204204
assertCaptured "$PYPY_36"
205-
assertCaptured "Installing pip 20.0.2, setuptools 47.1.1 and wheel 0.34.2"
205+
assertCaptured "Installing pip 20.1.1, setuptools 47.1.1 and wheel 0.34.2"
206206
assertCapturedSuccess
207207
fi
208208
}
@@ -214,7 +214,7 @@ testPypy2_7() {
214214
else
215215
assertCaptured "Installing pypy"
216216
assertCaptured "$PYPY_27"
217-
assertCaptured "Installing pip 20.0.2, setuptools 44.1.1 and wheel 0.34.2"
217+
assertCaptured "Installing pip 20.1.1, setuptools 44.1.1 and wheel 0.34.2"
218218
assertCapturedSuccess
219219
fi
220220
}

0 commit comments

Comments
 (0)