summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2019-04-24 13:20:53 -0400
committerJason R. Coombs <jaraco@jaraco.com>2019-04-24 13:23:23 -0400
commit123b0b20d6e0bc9ffd00d7fb8c2e1a3ceee7475a (patch)
treec4d909d0c006286215c0cb7cbc9074c1d21a537e
parent51f138939c98a4f616c702bc2f080504395fbbd6 (diff)
downloadpytest-runner-123b0b20d6e0bc9ffd00d7fb8c2e1a3ceee7475a.tar.gz
Pin to pip 19.0 for now for pypa/pip#6434.
-rw-r--r--pin-pip.py20
-rw-r--r--tox.ini1
2 files changed, 21 insertions, 0 deletions
diff --git a/pin-pip.py b/pin-pip.py
new file mode 100644
index 0000000..4cf0383
--- /dev/null
+++ b/pin-pip.py
@@ -0,0 +1,20 @@
+"""
+Downgrade to pip 19.0 before installing requirements, working
+around limitations introduced in 19.1 (ref
+https://github.com/pypa/pip/issues/6434)
+"""
+
+import sys
+import subprocess
+import shlex
+
+
+def main():
+ subprocess.check_call(shlex.split(
+ 'python -m pip install pip<19.1'
+ ))
+ subprocess.check_call(shlex.split(
+ 'python -m pip install') + sys.argv[1:])
+
+
+__name__ == '__main__' and main()
diff --git a/tox.ini b/tox.ini
index 8a3bf67..3d1ae59 100644
--- a/tox.ini
+++ b/tox.ini
@@ -5,6 +5,7 @@ minversion = 3.2
tox_pip_extensions_ext_venv_update = true
[testenv]
+install_command = python pin-pip.py {opts} {packages}
deps =
setuptools>=31.0.1
commands =