From cf540575690e42dc09083d271e701a16d1f9d03e Mon Sep 17 00:00:00 2001 From: Gil Forsyth Date: Wed, 5 Feb 2025 14:51:15 -0500 Subject: [PATCH] Use `rapids-pip-retry` in CI jobs that might need retries (#655) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Uses a retry wrapper for `pip` commands to try to alleviate CI failures due to hash mismatches that result from network hiccups xref rapidsai/build-planning#148 This will retry failures that show up in CI like: ``` Collecting nvidia-cublas-cu12 (from libraft-cu12==25.2.*,>=0.0.0a0) Downloading https://pypi.nvidia.com/nvidia-cublas-cu12/nvidia_cublas_cu12-12.8.3.14-py3-none-manylinux_2_27_aarch64.whl (604.9 MB) ━━━━━━━━━━━━━━━━━━━━━ 350.2/604.9 MB 229.2 MB/s eta 0:00:02 ERROR: THESE PACKAGES DO NOT MATCH THE HASHES FROM THE REQUIREMENTS FILE. If you have updated the package versions, please update the hashes. Otherwise, examine the package contents carefully; someone may have tampered with them. nvidia-cublas-cu12 from https://pypi.nvidia.com/nvidia-cublas-cu12/nvidia_cublas_cu12-12.8.3.14-py3-none-manylinux_2_27_aarch64.whl#sha256=93a4e0e386cc7f6e56c822531396de8170ed17068a1e18f987574895044cd8c3 (from libraft-cu12==25.2.*,>=0.0.0a0): Expected sha256 93a4e0e386cc7f6e56c822531396de8170ed17068a1e18f987574895044cd8c3 Got 849c88d155cb4b4a3fdfebff9270fb367c58370b4243a2bdbcb1b9e7e940b7be ``` Authors: - Gil Forsyth (https://github.com/gforsyth) Approvers: - Mike Sarahan (https://github.com/msarahan) - Bradley Dice (https://github.com/bdice) URL: https://github.com/rapidsai/cuxfilter/pull/655 --- ci/build_wheel.sh | 2 +- ci/test_external.sh | 4 ++-- ci/test_wheel.sh | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ci/build_wheel.sh b/ci/build_wheel.sh index 4fb8091c..3aca3b53 100755 --- a/ci/build_wheel.sh +++ b/ci/build_wheel.sh @@ -14,7 +14,7 @@ RAPIDS_PY_CUDA_SUFFIX="$(rapids-wheel-ctk-name-gen ${RAPIDS_CUDA_VERSION})" cd "${package_dir}" -python -m pip wheel . -w dist -v --no-deps --disable-pip-version-check +rapids-pip-retry wheel . -w dist -v --no-deps --disable-pip-version-check ../ci/validate_wheel.sh dist diff --git a/ci/test_external.sh b/ci/test_external.sh index d12a2cdb..e941e5eb 100755 --- a/ci/test_external.sh +++ b/ci/test_external.sh @@ -52,7 +52,7 @@ if [ "$PROJECT" = "all" ]; then # Change directory to the library pushd $LIBRARY # Run setup.py with test dependencies - python -m pip install .[tests] + rapids-pip-retry install .[tests] rapids-logger "Run GPU tests for $LIBRARY" @@ -76,7 +76,7 @@ else # Change directory to the specified project pushd $PROJECT # Run setup.py with test dependencies - python -m pip install .[tests] + rapids-pip-retry install .[tests] rapids-logger "Run GPU tests for $PROJECT" diff --git a/ci/test_wheel.sh b/ci/test_wheel.sh index c1253fe9..01867cea 100755 --- a/ci/test_wheel.sh +++ b/ci/test_wheel.sh @@ -7,6 +7,6 @@ RAPIDS_PY_CUDA_SUFFIX="$(rapids-wheel-ctk-name-gen ${RAPIDS_CUDA_VERSION})" RAPIDS_PY_WHEEL_NAME="cuxfilter_${RAPIDS_PY_CUDA_SUFFIX}" RAPIDS_PY_WHEEL_PURE="1" rapids-download-wheels-from-s3 ./dist # echo to expand wildcard before adding `[extra]` requires for pip -python -m pip install $(echo ./dist/cuxfilter*.whl)[test] +rapids-pip-retry install $(echo ./dist/cuxfilter*.whl)[test] python -m pytest -n 8 ./python/cuxfilter/tests