Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 70 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -471,3 +471,73 @@ jobs:
with:
push: true
cuda: '["12.9", "13.3"]'
# Build the cuDF Java JAR for every Maven classifier.
java-build:
needs: [telemetry-setup]
strategy:
fail-fast: false
matrix:
include:
- { cuda: "12.9", cuda_major: "12", arch: "x86_64", runner: "linux-amd64-cpu16" }
- { cuda: "13.3", cuda_major: "13", arch: "x86_64", runner: "linux-amd64-cpu16" }
- { cuda: "12.9", cuda_major: "12", arch: "aarch64", runner: "linux-arm64-cpu16" }
- { cuda: "13.3", cuda_major: "13", arch: "aarch64", runner: "linux-arm64-cpu16" }
runs-on: ${{ matrix.runner }}
permissions:
contents: read
steps:
- name: Checkout code repo
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
with:
ref: ${{ inputs.sha }}
fetch-depth: 0
persist-credentials: false
- name: Build static libcudf
run: |
./java/ci/build_static_libcudf.sh \
--output-dir "${RUNNER_TEMP}/libcudf" \
--cuda-version "${{ matrix.cuda }}"
- name: Build cuDF Java JAR
run: |
./java/ci/build_cudf_java_jar.sh \
--libcudf-dir "${RUNNER_TEMP}/libcudf" \
--output-dir "${RUNNER_TEMP}/jars" \
--cuda-version "${{ matrix.cuda }}"
- name: Upload per-entry JAR artifact
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
name: cudf_java_cuda${{ matrix.cuda_major }}_${{ matrix.arch }}
# Ship only the JARs and POMs. Exclude the per-classifier Maven build scratch dir.
path: |
${{ runner.temp }}/jars
!${{ runner.temp }}/jars/.mvn-temp-target
if-no-files-found: error
# Assemble the per-classifier JARs into one Maven-repository layout.
java-gather:
needs: [java-build]
runs-on: linux-amd64-cpu4
permissions:
contents: read
steps:
- name: Checkout code repo
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
with:
ref: ${{ inputs.sha }}
persist-credentials: false
- name: Download per-entry JAR artifacts
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
with:
pattern: cudf_java_cuda*
path: ${{ runner.temp }}/jars
merge-multiple: true
- name: Assemble Maven repository layout
run: |
./java/ci/assemble_maven_repo.sh \
--jars-dir "${RUNNER_TEMP}/jars" \
--output-dir "${RUNNER_TEMP}/maven-repo"
- name: Upload combined Maven repository artifact
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
name: cudf_java_maven_repo
path: ${{ runner.temp }}/maven-repo
if-no-files-found: error
13 changes: 9 additions & 4 deletions ci/run_cudf_polars_polars_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

set -euo pipefail

TIMEOUT_TOOL_PATH="$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/timeout_with_stack.py

# Support invoking run_cudf_polars_pytests.sh outside the script directory
# Assumption, polars has been cloned in the root of the repo.
cd "$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/../polars/
Expand Down Expand Up @@ -60,16 +62,18 @@ DESELECTED_TESTS_STR=$(printf -- " --deselect %s" "${DESELECTED_TESTS[@]}")
# Don't quote the `DESELECTED_...` variable because `pytest` can't handle
# multiple quoted arguments inline
# shellcheck disable=SC2086
# Fail fast (-x) because failed tests pollute the state
echo "Run polars tests with injected in-memory GPU engine"
python -m pytest \
python "${TIMEOUT_TOOL_PATH}" --enable-python 3600 \
python -m pytest \
--import-mode=importlib \
--cache-clear \
-x \
-m "" \
-p cudf_polars.testing.inject_gpu_engine \
-n 4 \
--dist=worksteal \
--tb=native \
--timeout=240 \
--durations 10 --durations-min 10 \
-ra \
$DESELECTED_TESTS_STR \
Expand All @@ -81,17 +85,18 @@ python -m pytest \
echo "Run polars tests with injected SPMD GPU engine, small blocksize"
CUDF_POLARS__EXECUTOR__TARGET_PARTITION_SIZE=805306368 \
CUDF_POLARS__EXECUTOR__FALLBACK_MODE=silent \
python -m pytest \
python "${TIMEOUT_TOOL_PATH}" --enable-python 3600 \
python -m pytest \
--import-mode=importlib \
--cache-clear \
-x \
-v \
-m "" \
-p cudf_polars.testing.inject_gpu_engine \
-W ignore::ResourceWarning \
-n 4 \
--dist=worksteal \
--tb=native \
--timeout=240 \
--durations 10 --durations-min 10 \
-ra \
$DESELECTED_TESTS_STR \
Expand Down
7 changes: 5 additions & 2 deletions ci/run_cudf_polars_pytests.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#!/bin/bash
# SPDX-FileCopyrightText: Copyright (c) 2024-2026, NVIDIA CORPORATION.
# SPDX-FileCopyrightText: Copyright (c) 2024-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0

set -euo pipefail

# It is essential to cd into python/cudf_polars as `pytest-xdist` + `coverage` seem to work only at this directory level.
# Support invoking run_cudf_polars_pytests.sh outside the script directory
TIMEOUT_TOOL_PATH="$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/timeout_with_stack.py

cd "$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/../python/cudf_polars/

python -m pytest --cache-clear "$@" tests
python "${TIMEOUT_TOOL_PATH}" --enable-python 3600 \
python -m pytest --cache-clear "$@" tests
3 changes: 3 additions & 0 deletions ci/test_wheel_cudf_polars.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,14 @@ for version in "${VERSIONS[@]}"; do
COVERAGE_ARGS=(--no-cov)
fi

# Fail fast (-x) rather than trying to continue because failed tests pollute the state
./ci/run_cudf_polars_pytests.sh \
-vv \
"${COVERAGE_ARGS[@]}" \
--numprocesses=4 \
--dist=worksteal \
--durations 10 --durations-min 10 \
-x \
-ra \
--junitxml="${RAPIDS_TESTS_DIR}/junit-cudf-polars-${version}.xml"

Expand All @@ -106,6 +108,7 @@ for version in "${VERSIONS[@]}"; do
EXITCODE=1
FAILED+=("${version}")
rapids-logger "Tests failed for polars ${version}.*"
break
else
PASSED+=("${version}")
rapids-logger "Tests passed for polars ${version}.*"
Expand Down
Loading
Loading