From 32b780ce8134f3febb6f7e62ecf24f3b03a36c6e Mon Sep 17 00:00:00 2001 From: Anil Belur Date: Wed, 10 May 2023 16:57:04 +1000 Subject: [PATCH] Fix: pin urllib3 to <2.0.0 for RTD jobs The latest version of module breaks compatibility with RTDv3 jobs during tox install and run. Note: The pip upgrade eager option pulls in the newer version of urllib3>2.0.0 unless the exact version is passed with lftools. Issue: RELENG-4715 Change-Id: I8aae2505eb20e7dc8bef02f5687f9dad9b0e8ef0 Signed-off-by: Anil Belur --- .../notes/pin-urllib3-tox-afb8227c923291ff.yaml | 18 ++++++++++++++++++ shell/tox-install.sh | 2 +- shell/tox-run.sh | 2 +- 3 files changed, 20 insertions(+), 2 deletions(-) create mode 100644 releasenotes/notes/pin-urllib3-tox-afb8227c923291ff.yaml diff --git a/releasenotes/notes/pin-urllib3-tox-afb8227c923291ff.yaml b/releasenotes/notes/pin-urllib3-tox-afb8227c923291ff.yaml new file mode 100644 index 00000000..eecd5df5 --- /dev/null +++ b/releasenotes/notes/pin-urllib3-tox-afb8227c923291ff.yaml @@ -0,0 +1,18 @@ +--- +fixes: + - | + Pin urllib3 to <2.0.0 for the RTD jobs + + The latest version of module breaks compatibility with RTDv3 + jobs during tox install and run. + + Error: + + .. code-block:: bash + + ValueError: Timeout value connect was , but it must be an int, float or None. + + Reference: + + `Launchpad#2018567 ` diff --git a/shell/tox-install.sh b/shell/tox-install.sh index e4bb50db..56bc43a9 100644 --- a/shell/tox-install.sh +++ b/shell/tox-install.sh @@ -17,7 +17,7 @@ set -eux -o pipefail # shellcheck disable=SC1090 source ~/lf-env.sh -lf-activate-venv --venv-file /tmp/.toxenv tox virtualenv +lf-activate-venv --venv-file /tmp/.toxenv tox virtualenv urllib3~=1.26.15 # installs are silent, show version details in log $PYTHON --version diff --git a/shell/tox-run.sh b/shell/tox-run.sh index ce527cf6..b30ea67d 100644 --- a/shell/tox-run.sh +++ b/shell/tox-run.sh @@ -24,7 +24,7 @@ cd "$WORKSPACE/$TOX_DIR" || exit 1 # shellcheck disable=SC1090 source ~/lf-env.sh -lf-activate-venv --venv-file /tmp/.toxenv tox virtualenv +lf-activate-venv --venv-file /tmp/.toxenv tox virtualenv urllib3~=1.26.15 if [[ -d /opt/pyenv ]]; then echo "---> Setting up pyenv" -- 2.16.6