Skip to content

Commit 3c6c387

Browse files
authored
Merge branch 'main' into graph-builder-refactor
2 parents 9465c76 + 93f513e commit 3c6c387

32 files changed

Lines changed: 1323 additions & 260 deletions

.github/workflows/backport.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
echo "OLD_BRANCH=${OLD_BRANCH}" >> $GITHUB_ENV
4444
4545
- name: Create backport pull requests
46-
uses: korthout/backport-action@3c06f323a58619da1e8522229ebc8d5de2633e46 # v4.3.0
46+
uses: korthout/backport-action@7c3f6cd5843cac11bc59a04a1b7699af93261670 # v4.5.0
4747
with:
4848
copy_assignees: true
4949
copy_labels_pattern: true
@@ -67,7 +67,7 @@ jobs:
6767
run: echo "BACKPORT_BRANCH=${{ inputs.backport-branch }}" >> $GITHUB_ENV
6868

6969
- name: Create backport pull requests
70-
uses: korthout/backport-action@3c06f323a58619da1e8522229ebc8d5de2633e46 # v4.3.0
70+
uses: korthout/backport-action@7c3f6cd5843cac11bc59a04a1b7699af93261670 # v4.5.0
7171
with:
7272
copy_assignees: true
7373
copy_labels_pattern: true

.github/workflows/bandit.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2424

2525
- name: Install uv
26-
uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0
26+
uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # v8.1.0
2727
with:
2828
enable-cache: false
2929

@@ -38,10 +38,10 @@ jobs:
3838
3939
echo "codes=$(uvx toml2json ./ruff.toml | jq -r '.lint.ignore | map(select(test("^S\\d+"))) | join(",")')" >> "$GITHUB_OUTPUT"
4040
- name: Perform Bandit Analysis using Ruff
41-
uses: astral-sh/ruff-action@4919ec5cf1f49eff0871dbcea0da843445b837e6 # v3.6.1
41+
uses: astral-sh/ruff-action@0ce1b0bf8b818ef400413f810f8a11cdbda0034b # v4.0.0
4242
with:
4343
args: "check --select S --ignore ${{ steps.ignore-codes.outputs.codes }} --output-format sarif --output-file results.sarif"
4444
- name: Upload SARIF file
45-
uses: github/codeql-action/upload-sarif@v4.35.1
45+
uses: github/codeql-action/upload-sarif@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
4646
with:
4747
sarif_file: results.sarif

.github/workflows/build-docs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262
# TODO: This workflow runs on GH-hosted runner and cannot use the proxy cache
6363

6464
- name: Set up miniforge
65-
uses: conda-incubator/setup-miniconda@fc2d68f6413eb2d87b895e92f8584b5b94a10167 # v3.3.0
65+
uses: conda-incubator/setup-miniconda@8ee1f361103df19b6f8c8655fd3967a8ecb162d5 # v4.0.1
6666
with:
6767
activate-environment: cuda-python-docs
6868
environment-file: ./cuda_python/docs/environment-docs.yml
@@ -244,7 +244,7 @@ jobs:
244244
245245
# TODO: Consider removing this step?
246246
- name: Upload doc artifacts
247-
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
247+
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5.0.0
248248
with:
249249
path: artifacts/
250250
retention-days: 3

.github/workflows/build-wheel.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
5555
# xref: https://github.com/orgs/community/discussions/42856#discussioncomment-7678867
5656
- name: Adding addtional GHA cache-related env vars
57-
uses: actions/github-script@v8
57+
uses: actions/github-script@v9
5858
with:
5959
script: |
6060
core.exportVariable('ACTIONS_CACHE_SERVICE_V2', 'on');
@@ -148,7 +148,7 @@ jobs:
148148
149149
- name: Upload cuda.pathfinder build artifacts
150150
if: ${{ strategy.job-index == 0 && inputs.host-platform == 'linux-64' }}
151-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
151+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
152152
with:
153153
name: cuda-pathfinder-wheel
154154
path: cuda_pathfinder/*.whl
@@ -162,7 +162,7 @@ jobs:
162162
cuda-version: ${{ inputs.cuda-version }}
163163

164164
- name: Build cuda.bindings wheel
165-
uses: pypa/cibuildwheel@ee02a1537ce3071a004a6b08c41e72f0fdc42d9a # v3.4.0
165+
uses: pypa/cibuildwheel@8d2b08b68458a16aeb24b64e68a09ab1c8e82084 # v3.4.1
166166
with:
167167
package-dir: ./cuda_bindings/
168168
output-dir: ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}
@@ -219,14 +219,14 @@ jobs:
219219
twine check --strict ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}/*.whl
220220
221221
- name: Upload cuda.bindings build artifacts
222-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
222+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
223223
with:
224224
name: ${{ env.CUDA_BINDINGS_ARTIFACT_NAME }}
225225
path: ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}/*.whl
226226
if-no-files-found: error
227227

228228
- name: Build cuda.core wheel
229-
uses: pypa/cibuildwheel@ee02a1537ce3071a004a6b08c41e72f0fdc42d9a # v3.4.0
229+
uses: pypa/cibuildwheel@8d2b08b68458a16aeb24b64e68a09ab1c8e82084 # v3.4.1
230230
with:
231231
package-dir: ./cuda_core/
232232
output-dir: ${{ env.CUDA_CORE_ARTIFACTS_DIR }}
@@ -316,7 +316,7 @@ jobs:
316316
317317
- name: Upload cuda-python build artifacts
318318
if: ${{ strategy.job-index == 0 && inputs.host-platform == 'linux-64' }}
319-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
319+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
320320
with:
321321
name: cuda-python-wheel
322322
path: cuda_python/*.whl
@@ -354,7 +354,7 @@ jobs:
354354
popd
355355
356356
- name: Upload cuda.bindings Cython tests
357-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
357+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
358358
with:
359359
name: ${{ env.CUDA_BINDINGS_ARTIFACT_NAME }}-tests
360360
path: ${{ env.CUDA_BINDINGS_CYTHON_TESTS_DIR }}/test_*${{ env.PY_EXT_SUFFIX }}
@@ -368,7 +368,7 @@ jobs:
368368
popd
369369
370370
- name: Upload cuda.core Cython tests
371-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
371+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
372372
with:
373373
name: ${{ env.CUDA_CORE_ARTIFACT_NAME }}-tests
374374
path: ${{ env.CUDA_CORE_CYTHON_TESTS_DIR }}/test_*${{ env.PY_EXT_SUFFIX }}
@@ -415,7 +415,7 @@ jobs:
415415
rmdir $OLD_BASENAME
416416
417417
- name: Build cuda.core wheel
418-
uses: pypa/cibuildwheel@ee02a1537ce3071a004a6b08c41e72f0fdc42d9a # v3.4.0
418+
uses: pypa/cibuildwheel@8d2b08b68458a16aeb24b64e68a09ab1c8e82084 # v3.4.1
419419
with:
420420
package-dir: ./cuda_core/
421421
output-dir: ${{ env.CUDA_CORE_ARTIFACTS_DIR }}
@@ -497,7 +497,7 @@ jobs:
497497
twine check --strict ${{ env.CUDA_CORE_ARTIFACTS_DIR }}/*.whl
498498
499499
- name: Upload cuda.core build artifacts
500-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
500+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
501501
with:
502502
name: ${{ env.CUDA_CORE_ARTIFACT_NAME }}
503503
path: ${{ env.CUDA_CORE_ARTIFACTS_DIR }}/*.whl

.github/workflows/codeql.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,13 @@ jobs:
3131
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3232

3333
- name: Initialize CodeQL
34-
uses: github/codeql-action/init@34950e1b113b30df4edee1a6d3a605242df0c40b # v3.31.8
34+
uses: github/codeql-action/init@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
3535
with:
3636
languages: ${{ matrix.language }}
3737
build-mode: ${{ matrix.build-mode }}
3838
queries: security-extended
3939

4040
- name: Perform CodeQL Analysis
41-
uses: github/codeql-action/analyze@34950e1b113b30df4edee1a6d3a605242df0c40b # v3.31.8
41+
uses: github/codeql-action/analyze@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
4242
with:
4343
category: "/language:${{matrix.language}}"

.github/workflows/coverage.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ jobs:
164164
ls -lh $REPO_ROOT/.coverage.linux
165165
166166
- name: Upload Linux coverage data
167-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
167+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
168168
with:
169169
name: coverage-data-linux
170170
path: .coverage.linux
@@ -173,7 +173,7 @@ jobs:
173173
if-no-files-found: error
174174

175175
- name: Upload cuda source code for coverage mapping
176-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
176+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
177177
with:
178178
name: cuda-source-linux
179179
path: ${{ env.INSTALL_ROOT }}/cuda/
@@ -242,7 +242,7 @@ jobs:
242242
ls -lahR ./wheels/
243243
244244
- name: Upload Windows wheel artifacts
245-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
245+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
246246
with:
247247
name: coverage-windows-wheels
248248
path: ./wheels/*.whl
@@ -373,7 +373,7 @@ jobs:
373373
ls -lh "$GITHUB_WORKSPACE/.coverage.windows"
374374
375375
- name: Upload Windows coverage data
376-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
376+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
377377
with:
378378
name: coverage-data-windows
379379
path: .coverage.windows
@@ -475,7 +475,7 @@ jobs:
475475
echo "[SUCCESS] Coverage reports generated successfully"
476476
477477
- name: Archive combined coverage results
478-
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
478+
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
479479
with:
480480
name: coverage-combined
481481
path: docs/coverage/

.github/workflows/release-cuda-pathfinder.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ jobs:
231231
ls -la dist
232232
233233
- name: Publish to TestPyPI
234-
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
234+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0
235235
with:
236236
repository-url: https://test.pypi.org/legacy/
237237

@@ -308,7 +308,7 @@ jobs:
308308
ls -la dist
309309
310310
- name: Publish to PyPI
311-
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
311+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0
312312

313313
# --------------------------------------------------------------------------
314314
# Verify the PyPI package installs and imports correctly.

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ jobs:
9797
ref: ${{ inputs.git-tag }}
9898

9999
- name: Set up Python
100-
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
100+
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
101101
with:
102102
python-version: "3.12"
103103

@@ -176,7 +176,7 @@ jobs:
176176
./ci/tools/validate-release-wheels "${{ inputs.git-tag }}" "${{ inputs.component }}" "dist"
177177
178178
- name: Publish package distributions to TestPyPI
179-
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
179+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0
180180
with:
181181
repository-url: https://test.pypi.org/legacy/
182182

@@ -206,6 +206,6 @@ jobs:
206206
./ci/tools/validate-release-wheels "${{ inputs.git-tag }}" "${{ inputs.component }}" "dist"
207207
208208
- name: Publish package distributions to PyPI
209-
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
209+
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0
210210

211211
# TODO: add another job to make the release leave the draft state?

.github/workflows/test-sdist-linux.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,13 @@ jobs:
5252
# The env vars ACTIONS_CACHE_SERVICE_V2, ACTIONS_RESULTS_URL, and ACTIONS_RUNTIME_TOKEN
5353
# are exposed by this action.
5454
- name: Enable sccache
55-
uses: mozilla-actions/sccache-action@7d986dd989559c6ecdb630a3fd2557667be217ad # 0.0.9
55+
uses: mozilla-actions/sccache-action@9e7fa8a12102821edf02ca5dbea1acd0f89a2696 # 0.0.10
5656
with:
5757
disable_annotations: 'true'
5858

5959
# xref: https://github.com/orgs/community/discussions/42856#discussioncomment-7678867
6060
- name: Adding additional GHA cache-related env vars
61-
uses: actions/github-script@v8
61+
uses: actions/github-script@v9
6262
with:
6363
script: |
6464
core.exportVariable('ACTIONS_CACHE_URL', process.env['ACTIONS_CACHE_URL'])
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
2+
# SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE
3+
"""Build cuda_bindings Cython test extensions in-place.
4+
5+
pixi-build's editable install exposes the `cuda` namespace package via a
6+
PEP 660 finder hook. Python's import machinery honors the hook, but
7+
Cython's filesystem .pxd resolver only walks real directories on sys.path,
8+
so `cimport cuda.bindings.*` fails to locate the .pxd files. We resolve
9+
the namespace package's source root from `cuda.bindings.__file__` and pass
10+
it via `include_path=` so cythonize finds the .pxd tree on every platform.
11+
"""
12+
13+
from __future__ import annotations
14+
15+
import sys
16+
from pathlib import Path
17+
18+
from Cython.Build import cythonize
19+
from setuptools import setup
20+
21+
import cuda.bindings
22+
23+
24+
def _bindings_source_root() -> Path:
25+
# cuda.bindings.__file__ -> .../<root>/cuda/bindings/__init__.py
26+
root = Path(cuda.bindings.__file__).resolve().parents[2]
27+
if not (root / "cuda" / "bindings").is_dir():
28+
raise RuntimeError(
29+
f"cuda.bindings source tree not found at {root}; pixi-build editable install layout may have changed."
30+
)
31+
return root
32+
33+
34+
def main() -> None:
35+
script_dir = Path(__file__).resolve().parent
36+
pyx_files = sorted(str(p) for p in script_dir.glob("test_*.pyx"))
37+
if not pyx_files:
38+
raise SystemExit(f"no test_*.pyx files under {script_dir}")
39+
40+
ext_modules = cythonize(
41+
pyx_files,
42+
language_level=3,
43+
nthreads=1,
44+
include_path=[str(_bindings_source_root())],
45+
compiler_directives={"freethreading_compatible": True},
46+
)
47+
48+
sys.argv = [sys.argv[0], "build_ext", "--inplace"]
49+
setup(name="cuda_bindings_cython_tests", ext_modules=ext_modules)
50+
51+
52+
if __name__ == "__main__":
53+
main()

0 commit comments

Comments
 (0)