From e6c70b48e72f468de4cc0b11dea6618d2ff8d6f3 Mon Sep 17 00:00:00 2001 From: Divye Gala Date: Tue, 25 Jul 2023 15:18:05 -0400 Subject: [PATCH 1/2] Switch to new wheels pipeline (#506) Authors: - Divye Gala (https://github.com/divyegala) Approvers: - Vyas Ramasubramani (https://github.com/vyasr) - AJ Schmidt (https://github.com/ajschmidt8) URL: https://github.com/rapidsai/cuxfilter/pull/506 --- .github/workflows/build.yaml | 8 ++++---- .github/workflows/pr.yaml | 12 ++++++------ .github/workflows/test.yaml | 6 +++--- ci/build_wheel.sh | 23 +++++++++++++++++++++++ ci/test_wheel.sh | 12 ++++++++++++ 5 files changed, 48 insertions(+), 13 deletions(-) create mode 100755 ci/build_wheel.sh create mode 100755 ci/test_wheel.sh diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 79c53e97..cbd66355 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -59,18 +59,18 @@ jobs: sha: ${{ inputs.sha }} wheel-build: secrets: inherit - uses: rapidsai/shared-action-workflows/.github/workflows/wheels-pure-build.yml@branch-23.08 + uses: rapidsai/shared-action-workflows/.github/workflows/wheels-build.yaml@branch-23.08 with: build_type: ${{ inputs.build_type || 'branch' }} branch: ${{ inputs.branch }} sha: ${{ inputs.sha }} date: ${{ inputs.date }} - package-name: cuxfilter - package-dir: python/ + script: ci/build_wheel.sh + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and (.CUDA_VER == "11.8.0" or .CUDA_VER == "12.0.1"))) wheel-publish: needs: wheel-build secrets: inherit - uses: rapidsai/shared-action-workflows/.github/workflows/wheels-pure-publish.yml@branch-23.08 + uses: rapidsai/shared-action-workflows/.github/workflows/wheels-publish.yaml@branch-23.08 with: build_type: ${{ inputs.build_type || 'branch' }} branch: ${{ inputs.branch }} diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index d3f7711e..1ba457e2 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -60,16 +60,16 @@ jobs: wheel-build: needs: checks secrets: inherit - uses: rapidsai/shared-action-workflows/.github/workflows/wheels-pure-build.yml@branch-23.08 + uses: rapidsai/shared-action-workflows/.github/workflows/wheels-build.yaml@branch-23.08 with: build_type: pull-request - package-name: cuxfilter - package-dir: python/ + script: ci/build_wheel.sh + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and (.CUDA_VER == "11.8.0" or .CUDA_VER == "12.0.1"))) wheel-tests: needs: wheel-build secrets: inherit - uses: rapidsai/shared-action-workflows/.github/workflows/wheels-pure-test.yml@branch-23.08 + uses: rapidsai/shared-action-workflows/.github/workflows/wheels-test.yaml@branch-23.08 with: build_type: pull-request - package-name: cuxfilter - test-unittest: "python -m pytest -n 8 ./python/cuxfilter/tests" + script: ci/test_wheel.sh + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and (.CUDA_VER == "11.8.0" or .CUDA_VER == "12.0.1"))) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index a48c07c1..1e5324bc 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -25,8 +25,8 @@ jobs: wheel-tests: needs: wheel-build secrets: inherit - uses: rapidsai/shared-action-workflows/.github/workflows/wheels-pure-test.yml@branch-23.08 + uses: rapidsai/shared-action-workflows/.github/workflows/wheels-test.yaml@branch-23.08 with: build_type: pull-request - package-name: cuxfilter - test-unittest: "python -m pytest -n 8 ./python/cuxfilter/tests" + script: ci/test_wheel.sh + matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and (.CUDA_VER == "11.8.0" or .CUDA_VER == "12.0.1"))) diff --git a/ci/build_wheel.sh b/ci/build_wheel.sh new file mode 100755 index 00000000..0cb197f8 --- /dev/null +++ b/ci/build_wheel.sh @@ -0,0 +1,23 @@ +#!/bin/bash +# Copyright (c) 2023, NVIDIA CORPORATION. + +set -euo pipefail + +source rapids-configure-sccache +source rapids-date-string + +# Use gha-tools rapids-pip-wheel-version to generate wheel version then +# update the necessary files +version_override="$(rapids-pip-wheel-version ${RAPIDS_DATE_STRING})" + +RAPIDS_PY_CUDA_SUFFIX="$(rapids-wheel-ctk-name-gen ${RAPIDS_CUDA_VERSION})" + +ci/release/apply_wheel_modifications.sh ${version_override} "-${RAPIDS_PY_CUDA_SUFFIX}" +echo "The package name and/or version was modified in the package source. The git diff is:" +git diff + +cd python + +python -m pip wheel . -w dist -vvv --no-deps --disable-pip-version-check + +RAPIDS_PY_WHEEL_NAME="cuxfilter_${RAPIDS_PY_CUDA_SUFFIX}" rapids-upload-wheels-to-s3 dist diff --git a/ci/test_wheel.sh b/ci/test_wheel.sh new file mode 100755 index 00000000..5087d221 --- /dev/null +++ b/ci/test_wheel.sh @@ -0,0 +1,12 @@ +#!/bin/bash +# Copyright (c) 2023, NVIDIA CORPORATION. + +set -eou pipefail + +RAPIDS_PY_CUDA_SUFFIX="$(rapids-wheel-ctk-name-gen ${RAPIDS_CUDA_VERSION})" +RAPIDS_PY_WHEEL_NAME="cuxfilter_${RAPIDS_PY_CUDA_SUFFIX}" 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] + +python -m pytest -n 8 ./python/cuxfilter/tests From e6eb47e9b40bafee9a7f568640d14b6e10575730 Mon Sep 17 00:00:00 2001 From: Bradley Dice Date: Tue, 25 Jul 2023 16:52:01 -0500 Subject: [PATCH 2/2] Fix nightly wheel testing workflow. (#507) This PR fixes the nightly wheel testing workflow. It looks like this was copied straight from `pr.yaml` rather than adapted for nightly testing. ``` Invalid workflow file: .github/workflows/test.yaml#L26 The workflow is not valid. .github/workflows/test.yaml (Line: 26, Col: 12): Job 'wheel-tests' depends on unknown job 'wheel-build'. ``` https://github.com/rapidsai/cuxfilter/actions/runs/5653917680 Authors: - Bradley Dice (https://github.com/bdice) - Vyas Ramasubramani (https://github.com/vyasr) Approvers: - Ajay Thorve (https://github.com/AjayThorve) - Vyas Ramasubramani (https://github.com/vyasr) - Ray Douglass (https://github.com/raydouglass) URL: https://github.com/rapidsai/cuxfilter/pull/507 --- .github/workflows/test.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 1e5324bc..9440ed6b 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -23,10 +23,12 @@ jobs: date: ${{ inputs.date }} sha: ${{ inputs.sha }} wheel-tests: - needs: wheel-build secrets: inherit uses: rapidsai/shared-action-workflows/.github/workflows/wheels-test.yaml@branch-23.08 with: - build_type: pull-request + build_type: nightly + branch: ${{ inputs.branch }} + date: ${{ inputs.date }} + sha: ${{ inputs.sha }} script: ci/test_wheel.sh matrix_filter: map(select(.ARCH == "amd64" and .PY_VER == "3.10" and (.CUDA_VER == "11.8.0" or .CUDA_VER == "12.0.1")))