diff contrib/automation/hgautomation/linux.py @ 47195:546e812a1c2d

automation: create Python 3.5 variant of requirements.txt The automation environment is refusing to build with the previous file because some dependencies won't install on Python 3.5. I couldn't find an easy way to salvage the situation with a single requirements.txt file. So, I decided to introduce a variant for Python 3.5. As part of this, we update packages to latest versions. (I do question why we are still supporting Python 3.5...) Differential Revision: https://phab.mercurial-scm.org/D10690
author Gregory Szorc <gregory.szorc@gmail.com>
date Thu, 06 May 2021 17:46:57 -0700
parents a6c5ec6b4728
children 743522fa2455
line wrap: on
line diff
--- a/contrib/automation/hgautomation/linux.py	Sat May 15 09:45:10 2021 +0000
+++ b/contrib/automation/hgautomation/linux.py	Thu May 06 17:46:57 2021 -0700
@@ -56,7 +56,20 @@
 for v in ${PYENV3_VERSIONS}; do
     pyenv install -v ${v}
     ${PYENV_ROOT}/versions/${v}/bin/python get-pip.py
-    ${PYENV_ROOT}/versions/${v}/bin/pip install -r /hgdev/requirements-py3.txt
+
+    case ${v} in
+        3.5.*)
+            REQUIREMENTS=requirements-py3.5.txt
+            ;;
+        pypy3.5*)
+            REQUIREMENTS=requirements-py3.5.txt
+            ;;
+        *)
+            REQUIREMENTS=requirements-py3.txt
+            ;;
+    esac
+
+    ${PYENV_ROOT}/versions/${v}/bin/pip install -r /hgdev/${REQUIREMENTS}
 done
 
 pyenv global ${PYENV2_VERSIONS} ${PYENV3_VERSIONS} system
@@ -307,8 +320,7 @@
 
 {install_rust}
 
-cp requirements-py2.txt /hgdev/requirements-py2.txt
-cp requirements-py3.txt /hgdev/requirements-py3.txt
+cp requirements-*.txt /hgdev/
 
 # Disable the pip version check because it uses the network and can
 # be annoying.