From 8acd812e37abbdc270b3387f17ac849ad2afb773 Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 12:45:09 -0700 Subject: [PATCH 1/9] fix: use slim container image --- .github/workflows/conda-python-build.yaml | 56 +++++++++++++++++------ ci/build_conda_python.sh | 29 ++++++++++++ 2 files changed, 72 insertions(+), 13 deletions(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index bb3c16c2..4d436dff 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -57,21 +57,21 @@ jobs: # Please keep the matrices sorted in ascending order by the following: # - # [ARCH, PY_VER, CUDA_VER, LINUX_VER] + # [ARCH, PY_VER] # export MATRIX=" # amd64 - - { ARCH: 'amd64', PY_VER: '3.10', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'amd64', PY_VER: '3.11', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'amd64', PY_VER: '3.12', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'amd64', PY_VER: '3.13', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'amd64', PY_VER: '3.14', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } + - { ARCH: 'amd64', PY_VER: '3.10' } + - { ARCH: 'amd64', PY_VER: '3.11' } + - { ARCH: 'amd64', PY_VER: '3.12' } + - { ARCH: 'amd64', PY_VER: '3.13' } + - { ARCH: 'amd64', PY_VER: '3.14' } # arm64 - - { ARCH: 'arm64', PY_VER: '3.10', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'arm64', PY_VER: '3.11', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'arm64', PY_VER: '3.12', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'arm64', PY_VER: '3.13', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } - - { ARCH: 'arm64', PY_VER: '3.14', CUDA_VER: '12.9.1', LINUX_VER: 'rockylinux8' } + - { ARCH: 'arm64', PY_VER: '3.10' } + - { ARCH: 'arm64', PY_VER: '3.11' } + - { ARCH: 'arm64', PY_VER: '3.12' } + - { ARCH: 'arm64', PY_VER: '3.13' } + - { ARCH: 'arm64', PY_VER: '3.14' } " MATRIX="$( @@ -80,8 +80,24 @@ jobs: )" echo "MATRIX=${MATRIX}" | tee --append "${GITHUB_OUTPUT}" + fetch-gha-tools: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + with: + repository: rapidsai/gha-tools + ref: main + path: gha-tools + fetch-depth: 1 + - uses: actions/upload-artifact@v6 + with: + name: rapids-gha-tools + path: gha-tools + if-no-files-found: error build: - needs: compute-matrix + needs: + - compute-matrix + - fetch-gha-tools strategy: fail-fast: false matrix: ${{ fromJSON(needs.compute-matrix.outputs.MATRIX) }} @@ -89,7 +105,7 @@ jobs: env: RAPIDS_ARTIFACTS_DIR: ${{ github.workspace }}/artifacts container: - image: rapidsai/ci-conda:cuda${{ matrix.CUDA_VER }}-${{ matrix.LINUX_VER }}-py${{ matrix.PY_VER }} + image: condaforge/miniforge3:latest env: RAPIDS_BUILD_TYPE: ${{ inputs.build_type }} steps: @@ -103,6 +119,15 @@ jobs: repository: ${{ inputs.repo }} ref: ${{ inputs.sha }} fetch-depth: 0 + # One clone in fetch-gha-tools; matrix jobs only download the artifact into the mounted workspace. + - uses: actions/download-artifact@v6 + with: + name: rapids-gha-tools + path: ${{ github.workspace }} + - name: Add RAPIDS gha-tools to PATH + run: echo "${GITHUB_WORKSPACE}/tools" | tee -a "${GITHUB_PATH}" + - name: Mark workspace safe for the git command + run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - name: Standardize repository information run: | echo "RAPIDS_REPOSITORY=${{ inputs.repo || github.repository }}" >> "${GITHUB_ENV}" @@ -123,7 +148,12 @@ jobs: - name: Build Conda Package run: ${{ inputs.script }} env: + RAPIDS_CONDA_BLD_ROOT_DIR: /tmp/conda-bld-workspace + RAPIDS_CONDA_BLD_OUTPUT_DIR: /tmp/conda-bld-output + # renovate: datasource=github-releases depName=rapidsai/sccache + SCCACHE_VER: 0.14.0-rapids.1 GH_TOKEN: ${{ github.token }} + PYTHON_VERSION: ${{ matrix.PY_VER }} - name: Upload conda repo if: ${{ !cancelled() }} uses: actions/upload-artifact@v7 diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index 5b303f6b..efe89258 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -4,6 +4,32 @@ set -euo pipefail +chmod +x tools/rapids-* + +apt update +apt install -y jq gh unzip curl gettext + +curl -fsSL "https://raw.githubusercontent.com/rapidsai/ci-imgs/main/context/condarc.tmpl" | \ +envsubst | tee ~/.condarc + +SCCACHE_VERSION="${SCCACHE_VER}" rapids-install-sccache + +rapids-mamba-retry update --all -y -n base +conda install -y conda-build + +# install expected Python version +PYTHON_MAJOR_VERSION=${PYTHON_VERSION%%.*} +PYTHON_MINOR_VERSION=${PYTHON_VERSION#*.} +PYTHON_UPPER_BOUND="${PYTHON_MAJOR_VERSION}.$((PYTHON_MINOR_VERSION+1)).0a0" +PYTHON_MINOR_PADDED=$(printf "%02d" "$PYTHON_MINOR_VERSION") +PYTHON_VERSION_PADDED="${PYTHON_MAJOR_VERSION}.${PYTHON_MINOR_PADDED}" +if [[ "$PYTHON_VERSION_PADDED" > "3.12" ]]; then + PYTHON_ABI_TAG="cp${PYTHON_MAJOR_VERSION}${PYTHON_MINOR_VERSION}" +else + PYTHON_ABI_TAG="cpython" +fi +rapids-mamba-retry install -y -n base "python>=${PYTHON_VERSION},<${PYTHON_UPPER_BOUND}=*_${PYTHON_ABI_TAG}" + source rapids-configure-sccache source rapids-date-string @@ -32,3 +58,6 @@ rapids-conda-retry build conda/recipes/numbast rapids-conda-retry build conda/recipes/numbast_extensions sccache --show-adv-stats + +# find /opt -type d -name conda-bld +ls -lh /tmp/conda-bld-output || true From e02c25a7dc6d8f12a83c532d28a8509e29488d9a Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 12:45:38 -0700 Subject: [PATCH 2/9] debug --- ci/build_conda_python.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index efe89258..bf3a4ae6 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -59,5 +59,5 @@ rapids-conda-retry build conda/recipes/numbast_extensions sccache --show-adv-stats -# find /opt -type d -name conda-bld -ls -lh /tmp/conda-bld-output || true +ls -lh "$RAPIDS_CONDA_BLD_OUTPUT_DIR" || { cat ~/.condarc && exit 1; } +find "$RAPIDS_CONDA_BLD_OUTPUT_DIR" From 4a0bc51d45d560f9726334eec024e2b220315e6f Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 12:53:26 -0700 Subject: [PATCH 3/9] cleanup --- ci/build_conda_python.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index bf3a4ae6..336a9141 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -58,6 +58,3 @@ rapids-conda-retry build conda/recipes/numbast rapids-conda-retry build conda/recipes/numbast_extensions sccache --show-adv-stats - -ls -lh "$RAPIDS_CONDA_BLD_OUTPUT_DIR" || { cat ~/.condarc && exit 1; } -find "$RAPIDS_CONDA_BLD_OUTPUT_DIR" From 9e8e7418720797aa0bddcc14653cdce603338bf0 Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 13:20:40 -0700 Subject: [PATCH 4/9] pin on tags --- .github/workflows/conda-python-build.yaml | 2 +- ci/build_conda_python.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index 4d436dff..f5c1c991 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -86,7 +86,7 @@ jobs: - uses: actions/checkout@v6 with: repository: rapidsai/gha-tools - ref: main + ref: v0.0.198 path: gha-tools fetch-depth: 1 - uses: actions/upload-artifact@v6 diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index 336a9141..c1892924 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -9,7 +9,7 @@ chmod +x tools/rapids-* apt update apt install -y jq gh unzip curl gettext -curl -fsSL "https://raw.githubusercontent.com/rapidsai/ci-imgs/main/context/condarc.tmpl" | \ +curl -fsSL "https://raw.githubusercontent.com/rapidsai/ci-imgs/v26.06.00a/context/condarc.tmpl" | \ envsubst | tee ~/.condarc SCCACHE_VERSION="${SCCACHE_VER}" rapids-install-sccache From c207957b6475b6051b2f65605897d69f89e866cf Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 14:50:54 -0700 Subject: [PATCH 5/9] pin on tags --- .github/workflows/conda-python-build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index f5c1c991..86d09a8f 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -105,7 +105,7 @@ jobs: env: RAPIDS_ARTIFACTS_DIR: ${{ github.workspace }}/artifacts container: - image: condaforge/miniforge3:latest + image: condaforge/miniforge3:26.1.1-3 env: RAPIDS_BUILD_TYPE: ${{ inputs.build_type }} steps: From cea16939f967357826c8572f14e3e4f73500983c Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 15:04:41 -0700 Subject: [PATCH 6/9] move env vars --- .github/workflows/conda-python-build.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index 86d09a8f..d42c34e2 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -104,6 +104,8 @@ jobs: runs-on: "linux-${{ matrix.ARCH }}-${{ inputs.node_type }}" env: RAPIDS_ARTIFACTS_DIR: ${{ github.workspace }}/artifacts + RAPIDS_CONDA_BLD_OUTPUT_DIR: /tmp/conda-bld-output + RAPIDS_CONDA_BLD_ROOT_DIR: /tmp/conda-bld-workspace container: image: condaforge/miniforge3:26.1.1-3 env: @@ -148,8 +150,6 @@ jobs: - name: Build Conda Package run: ${{ inputs.script }} env: - RAPIDS_CONDA_BLD_ROOT_DIR: /tmp/conda-bld-workspace - RAPIDS_CONDA_BLD_OUTPUT_DIR: /tmp/conda-bld-output # renovate: datasource=github-releases depName=rapidsai/sccache SCCACHE_VER: 0.14.0-rapids.1 GH_TOKEN: ${{ github.token }} @@ -159,7 +159,7 @@ jobs: uses: actions/upload-artifact@v7 with: name: conda-repo-${{ matrix.ARCH }}-${{ matrix.PY_VER }} - path: "/tmp/conda-bld-output" + path: ${{ env.RAPIDS_CONDA_BLD_OUTPUT_DIR }} - name: Publish Conda Package if: inputs.upload_to_conda run: "ci/upload_conda.sh" From 193593117240ee3ec202dd7a024f7e9294632c9b Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Fri, 3 Apr 2026 16:03:40 -0700 Subject: [PATCH 7/9] bump --- .github/workflows/conda-python-build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index d42c34e2..e633d285 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -89,7 +89,7 @@ jobs: ref: v0.0.198 path: gha-tools fetch-depth: 1 - - uses: actions/upload-artifact@v6 + - uses: actions/upload-artifact@v7 with: name: rapids-gha-tools path: gha-tools From b368e48015fcf5dc66f8ee742305af682db0cebd Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Sun, 5 Apr 2026 20:49:50 -0700 Subject: [PATCH 8/9] just minor --- ci/build_conda_python.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index c1892924..3be379c6 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -21,9 +21,7 @@ conda install -y conda-build PYTHON_MAJOR_VERSION=${PYTHON_VERSION%%.*} PYTHON_MINOR_VERSION=${PYTHON_VERSION#*.} PYTHON_UPPER_BOUND="${PYTHON_MAJOR_VERSION}.$((PYTHON_MINOR_VERSION+1)).0a0" -PYTHON_MINOR_PADDED=$(printf "%02d" "$PYTHON_MINOR_VERSION") -PYTHON_VERSION_PADDED="${PYTHON_MAJOR_VERSION}.${PYTHON_MINOR_PADDED}" -if [[ "$PYTHON_VERSION_PADDED" > "3.12" ]]; then +if [[ "${PYTHON_MINOR_VERSION}" -gt 12 ]]; then PYTHON_ABI_TAG="cp${PYTHON_MAJOR_VERSION}${PYTHON_MINOR_VERSION}" else PYTHON_ABI_TAG="cpython" From 2991295285efe12e74104c36060dddf21962cf30 Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Sun, 5 Apr 2026 21:09:38 -0700 Subject: [PATCH 9/9] fix: archive only tools --- .github/workflows/conda-python-build.yaml | 12 +++++++++--- ci/build_conda_python.sh | 2 +- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/.github/workflows/conda-python-build.yaml b/.github/workflows/conda-python-build.yaml index e633d285..82dc6dad 100644 --- a/.github/workflows/conda-python-build.yaml +++ b/.github/workflows/conda-python-build.yaml @@ -89,10 +89,12 @@ jobs: ref: v0.0.198 path: gha-tools fetch-depth: 1 + - name: Archive RAPIDS gha-tools + run: tar -C gha-tools -czf rapids-gha-tools-tools.tgz tools - uses: actions/upload-artifact@v7 with: name: rapids-gha-tools - path: gha-tools + path: rapids-gha-tools-tools.tgz if-no-files-found: error build: needs: @@ -125,9 +127,13 @@ jobs: - uses: actions/download-artifact@v6 with: name: rapids-gha-tools - path: ${{ github.workspace }} + path: ${{ github.workspace }}/gha-tools + - name: Extract RAPIDS gha-tools + run: | + mkdir -p "${GITHUB_WORKSPACE}/gha-tools" + tar -xzf "${GITHUB_WORKSPACE}/gha-tools/rapids-gha-tools-tools.tgz" -C "${GITHUB_WORKSPACE}/gha-tools" - name: Add RAPIDS gha-tools to PATH - run: echo "${GITHUB_WORKSPACE}/tools" | tee -a "${GITHUB_PATH}" + run: echo "${GITHUB_WORKSPACE}/gha-tools/tools" | tee -a "${GITHUB_PATH}" - name: Mark workspace safe for the git command run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - name: Standardize repository information diff --git a/ci/build_conda_python.sh b/ci/build_conda_python.sh index 3be379c6..1cace915 100755 --- a/ci/build_conda_python.sh +++ b/ci/build_conda_python.sh @@ -4,7 +4,7 @@ set -euo pipefail -chmod +x tools/rapids-* +chmod +x gha-tools/tools/rapids-* apt update apt install -y jq gh unzip curl gettext