From ecfc79fb9998f59bdd9531d45e01604ce5398cfb Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Thu, 18 Dec 2025 13:51:37 -0500 Subject: [PATCH 01/12] Use setuptools-scm to determine versions --- .gitignore | 3 +++ cuda_bindings/cuda/bindings/_version.py | 4 ---- cuda_bindings/pyproject.toml | 14 ++++++++++++-- cuda_core/cuda/core/_version.py | 5 ----- cuda_core/pyproject.toml | 13 +++++++++++-- cuda_pathfinder/cuda/pathfinder/_version.py | 4 ---- cuda_pathfinder/pyproject.toml | 13 +++++++++++-- cuda_python/pyproject.toml | 6 +++++- cuda_python/setup.py | 19 ++++++++++++------- .../cuda_python_test_helpers/__init__.py | 2 ++ cuda_python_test_helpers/pyproject.toml | 9 +++++++-- 11 files changed, 63 insertions(+), 29 deletions(-) delete mode 100644 cuda_bindings/cuda/bindings/_version.py delete mode 100644 cuda_core/cuda/core/_version.py delete mode 100644 cuda_pathfinder/cuda/pathfinder/_version.py diff --git a/.gitignore b/.gitignore index 1455b1dfc2..4aeb772e15 100644 --- a/.gitignore +++ b/.gitignore @@ -48,6 +48,9 @@ cuda_bindings/cuda/bindings/nvrtc.pxd cuda_bindings/cuda/bindings/nvrtc.pyx cuda_bindings/cuda/bindings/utils/_get_handle.pyx +# Version files from setuptools_scm +_version.py + # Distribution / packaging .Python build/ diff --git a/cuda_bindings/cuda/bindings/_version.py b/cuda_bindings/cuda/bindings/_version.py deleted file mode 100644 index 3448e498c5..0000000000 --- a/cuda_bindings/cuda/bindings/_version.py +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE - -__version__ = "13.1.1" diff --git a/cuda_bindings/pyproject.toml b/cuda_bindings/pyproject.toml index d1cf360cad..84bfe72d65 100644 --- a/cuda_bindings/pyproject.toml +++ b/cuda_bindings/pyproject.toml @@ -1,7 +1,12 @@ # SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved. # SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE [build-system] -requires = ["setuptools>=77.0.0", "cython>=3.2,<3.3", "pyclibrary>=0.1.7"] +requires = [ + "setuptools>=80.0.0", + "setuptools_scm[simple]>=8", + "cython>=3.2,<3.3", + "pyclibrary>=0.1.7", +] build-backend = "setuptools.build_meta" [project] @@ -51,7 +56,6 @@ Documentation = "https://nvidia.github.io/cuda-python/" include = ["cuda*"] [tool.setuptools.dynamic] -version = { attr = "cuda.bindings._version.__version__" } readme = { file = ["DESCRIPTION.rst"], content-type = "text/x-rst" } [tool.cibuildwheel] @@ -72,3 +76,9 @@ required_plugins = "pytest-benchmark" addopts = "--benchmark-disable --showlocals" norecursedirs = ["tests/cython", "examples"] xfail_strict = true + +[tool.setuptools_scm] +root = ".." +version_file = "cuda/bindings/_version.py" +tag_regex = "^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"] diff --git a/cuda_core/cuda/core/_version.py b/cuda_core/cuda/core/_version.py deleted file mode 100644 index 44683fadb3..0000000000 --- a/cuda_core/cuda/core/_version.py +++ /dev/null @@ -1,5 +0,0 @@ -# SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# -# SPDX-License-Identifier: Apache-2.0 - -__version__ = "0.5.0" diff --git a/cuda_core/pyproject.toml b/cuda_core/pyproject.toml index 94a9e931cc..97ea97fcf6 100644 --- a/cuda_core/pyproject.toml +++ b/cuda_core/pyproject.toml @@ -3,7 +3,11 @@ # SPDX-License-Identifier: Apache-2.0 [build-system] -requires = ["setuptools>=77.0.0", "Cython>=3.2,<3.3"] +requires = [ + "setuptools>=80", + "setuptools-scm[simple]>=8", + "Cython>=3.2,<3.3" +] build-backend = "build_hooks" backend-path = ["."] @@ -72,9 +76,14 @@ include = ["cuda.core*"] "cuda.core._include" = ["*.h", "*.hpp", "*.cuh"] [tool.setuptools.dynamic] -version = { attr = "cuda.core._version.__version__" } readme = { file = ["DESCRIPTION.rst"], content-type = "text/x-rst" } +[tool.setuptools_scm] +root = ".." +version_file = "cuda/core/_version.py" +tag_regex = "^cuda-core-(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "cuda-core-v*[0-9]*"] + [tool.cibuildwheel] skip = "*-musllinux_*" enable = "cpython-freethreading" diff --git a/cuda_pathfinder/cuda/pathfinder/_version.py b/cuda_pathfinder/cuda/pathfinder/_version.py deleted file mode 100644 index 2a04d1dbf8..0000000000 --- a/cuda_pathfinder/cuda/pathfinder/_version.py +++ /dev/null @@ -1,4 +0,0 @@ -# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved. -# SPDX-License-Identifier: Apache-2.0 - -__version__ = "1.3.4a0" diff --git a/cuda_pathfinder/pyproject.toml b/cuda_pathfinder/pyproject.toml index d446c1a60d..a8df1ac233 100644 --- a/cuda_pathfinder/pyproject.toml +++ b/cuda_pathfinder/pyproject.toml @@ -62,13 +62,22 @@ Documentation = "https://nvidia.github.io/cuda-python/" packages = { find = { include = ["cuda*"] } } [tool.setuptools.dynamic] -version = { attr = "cuda.pathfinder._version.__version__" } readme = { file = ["DESCRIPTION.rst"], content-type = "text/x-rst" } [build-system] -requires = ["setuptools>=64", "wheel"] +requires = [ + "setuptools>=80.0.0", + "setuptools_scm[simple]>=8", + "wheel" +] build-backend = "setuptools.build_meta" +[tool.setuptools_scm] +root = ".." +version_file = "cuda/pathfinder/_version.py" +tag_regex = "^cuda-pathfinder-(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +git_describe_command = [ "git", "describe", "--dirty", "--tags", "--long", "--match", "cuda-pathfinder-v*[0-9]*" ] + [tool.pytest.ini_options] addopts = "--showlocals" diff --git a/cuda_python/pyproject.toml b/cuda_python/pyproject.toml index 9048f5818b..d0f33d6883 100644 --- a/cuda_python/pyproject.toml +++ b/cuda_python/pyproject.toml @@ -3,7 +3,7 @@ # SPDX-License-Identifier: LicenseRef-NVIDIA-SOFTWARE-LICENSE [build-system] -requires = ["setuptools>=77.0.0",] +requires = ["setuptools>=80.0.0", "setuptools-scm[simple]>=8"] build-backend = "setuptools.build_meta" [project] @@ -40,3 +40,7 @@ homepage = "https://nvidia.github.io/cuda-python/" documentation = "https://nvidia.github.io/cuda-python/" repository = "https://github.com/NVIDIA/cuda-python/" issues = "https://github.com/NVIDIA/cuda-python/issues/" + +# The [tool.setuptools_scm] section is handled in setup.py since we need to +# dynamically set the dependency to cuda_bindings based on the dynamically +# determinded version diff --git a/cuda_python/setup.py b/cuda_python/setup.py index 0d91a34887..6f633ca2b5 100644 --- a/cuda_python/setup.py +++ b/cuda_python/setup.py @@ -4,15 +4,20 @@ import ast +from packaging.version import Version from setuptools import setup +from setuptools_scm import get_version + +version = get_version( + root="..", + relative_to=__file__, + tag_regex="^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$", + git_describe_command=["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"], +) + + +version = Version(version).base_version -# We want to keep the version in sync with cuda.bindings, but setuptools would not let -# us to refer to any files outside of the project root, so we have to employ our own -# run-time lookup using setup()... -with open("../cuda_bindings/cuda/bindings/_version.py") as f: - for line in f: - if line.startswith("__version__"): - version = ast.parse(line).body[0].value.value setup( version=version, diff --git a/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py b/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py index fca190c103..aacc540808 100644 --- a/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py +++ b/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py @@ -11,6 +11,8 @@ from cuda.core._utils.cuda_utils import handle_return +from ._version import __version__ + __all__ = [ "IS_WINDOWS", "IS_WSL", diff --git a/cuda_python_test_helpers/pyproject.toml b/cuda_python_test_helpers/pyproject.toml index 85652b61c5..6bbb010efc 100644 --- a/cuda_python_test_helpers/pyproject.toml +++ b/cuda_python_test_helpers/pyproject.toml @@ -2,12 +2,11 @@ # SPDX-License-Identifier: Apache-2.0 [build-system] -requires = ["setuptools>=77.0.0"] +requires = ["setuptools>=80.0.0", "setuptools-scm[simple]>=8"] build-backend = "setuptools.build_meta" [project] name = "cuda-python-test-helpers" -version = "0.1.0" description = "Shared test helpers for CUDA Python projects" readme = {file = "README.md", content-type = "text/markdown"} authors = [{ name = "NVIDIA Corporation" }] @@ -21,5 +20,11 @@ classifiers = [ [tool.setuptools] packages = ["cuda_python_test_helpers"] +[tool.setuptools_scm] +root = ".." +version_file = "cuda_python_test_helpers/_version.py" +tag_regex = "^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"] + [project.urls] repository = "https://github.com/NVIDIA/cuda-python" From ce130222d0b4cfbe52cf5042c248f0c2e7193481 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Thu, 18 Dec 2025 14:10:01 -0500 Subject: [PATCH 02/12] Sort commits --- cuda_pathfinder/cuda/pathfinder/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cuda_pathfinder/cuda/pathfinder/__init__.py b/cuda_pathfinder/cuda/pathfinder/__init__.py index 143c4b45cc..5258890a9d 100644 --- a/cuda_pathfinder/cuda/pathfinder/__init__.py +++ b/cuda_pathfinder/cuda/pathfinder/__init__.py @@ -3,6 +3,8 @@ """cuda.pathfinder public APIs""" +from cuda.pathfinder._version import __version__ as __version__ + from cuda.pathfinder._dynamic_libs.load_dl_common import DynamicLibNotFoundError as DynamicLibNotFoundError from cuda.pathfinder._dynamic_libs.load_dl_common import LoadedDL as LoadedDL from cuda.pathfinder._dynamic_libs.load_nvidia_dynamic_lib import load_nvidia_dynamic_lib as load_nvidia_dynamic_lib @@ -11,7 +13,6 @@ ) from cuda.pathfinder._headers.find_nvidia_headers import find_nvidia_header_directory as find_nvidia_header_directory from cuda.pathfinder._headers.supported_nvidia_headers import SUPPORTED_HEADERS_CTK as _SUPPORTED_HEADERS_CTK -from cuda.pathfinder._version import __version__ as __version__ # Indirections to help Sphinx find the docstrings. #: Mapping from short CUDA Toolkit (CTK) library names to their canonical From b9b4384992f789da4fe2d2831aa400b89ab84fc8 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Thu, 18 Dec 2025 14:44:51 -0500 Subject: [PATCH 03/12] Revert the version changes to cuda_python_test_helpers Fancy auto versioning isn't really compatible with the "use without installing" model for this package --- .../cuda_python_test_helpers/__init__.py | 2 -- cuda_python_test_helpers/pyproject.toml | 9 ++------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py b/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py index aacc540808..fca190c103 100644 --- a/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py +++ b/cuda_python_test_helpers/cuda_python_test_helpers/__init__.py @@ -11,8 +11,6 @@ from cuda.core._utils.cuda_utils import handle_return -from ._version import __version__ - __all__ = [ "IS_WINDOWS", "IS_WSL", diff --git a/cuda_python_test_helpers/pyproject.toml b/cuda_python_test_helpers/pyproject.toml index 6bbb010efc..85652b61c5 100644 --- a/cuda_python_test_helpers/pyproject.toml +++ b/cuda_python_test_helpers/pyproject.toml @@ -2,11 +2,12 @@ # SPDX-License-Identifier: Apache-2.0 [build-system] -requires = ["setuptools>=80.0.0", "setuptools-scm[simple]>=8"] +requires = ["setuptools>=77.0.0"] build-backend = "setuptools.build_meta" [project] name = "cuda-python-test-helpers" +version = "0.1.0" description = "Shared test helpers for CUDA Python projects" readme = {file = "README.md", content-type = "text/markdown"} authors = [{ name = "NVIDIA Corporation" }] @@ -20,11 +21,5 @@ classifiers = [ [tool.setuptools] packages = ["cuda_python_test_helpers"] -[tool.setuptools_scm] -root = ".." -version_file = "cuda_python_test_helpers/_version.py" -tag_regex = "^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" -git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"] - [project.urls] repository = "https://github.com/NVIDIA/cuda-python" From 14531f3415b33569ac48eefd898f090d1da35dda Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Thu, 18 Dec 2025 15:22:55 -0500 Subject: [PATCH 04/12] Don't include release candidate / alpha / beta suffixes in the versioning of the subpackages. --- cuda_bindings/pyproject.toml | 3 ++- cuda_core/pyproject.toml | 3 ++- cuda_pathfinder/pyproject.toml | 3 ++- cuda_python/setup.py | 3 ++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/cuda_bindings/pyproject.toml b/cuda_bindings/pyproject.toml index 84bfe72d65..7c4bddb434 100644 --- a/cuda_bindings/pyproject.toml +++ b/cuda_bindings/pyproject.toml @@ -80,5 +80,6 @@ xfail_strict = true [tool.setuptools_scm] root = ".." version_file = "cuda/bindings/_version.py" -tag_regex = "^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +# We deliberately do not want to include the version suffixes (a/b/rc) in cuda-bindings versioning +tag_regex = "^(?Pv\\d+\\.\\d+\\.\\d+)" git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"] diff --git a/cuda_core/pyproject.toml b/cuda_core/pyproject.toml index 97ea97fcf6..058148f97b 100644 --- a/cuda_core/pyproject.toml +++ b/cuda_core/pyproject.toml @@ -81,7 +81,8 @@ readme = { file = ["DESCRIPTION.rst"], content-type = "text/x-rst" } [tool.setuptools_scm] root = ".." version_file = "cuda/core/_version.py" -tag_regex = "^cuda-core-(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +# We deliberately do not want to include the version suffixes (a/b/rc) in cuda-core versioning +tag_regex = "^cuda-core-(?Pv\\d+\\.\\d+\\.\\d+)" git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "cuda-core-v*[0-9]*"] [tool.cibuildwheel] diff --git a/cuda_pathfinder/pyproject.toml b/cuda_pathfinder/pyproject.toml index a8df1ac233..8f2e89eaab 100644 --- a/cuda_pathfinder/pyproject.toml +++ b/cuda_pathfinder/pyproject.toml @@ -75,7 +75,8 @@ build-backend = "setuptools.build_meta" [tool.setuptools_scm] root = ".." version_file = "cuda/pathfinder/_version.py" -tag_regex = "^cuda-pathfinder-(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$" +# We deliberately do not want to include the version suffixes (a/b/rc) in cuda-pathfinder versioning +tag_regex = "^cuda-pathfinder-(?Pv\\d+\\.\\d+\\.\\d+)" git_describe_command = [ "git", "describe", "--dirty", "--tags", "--long", "--match", "cuda-pathfinder-v*[0-9]*" ] [tool.pytest.ini_options] diff --git a/cuda_python/setup.py b/cuda_python/setup.py index 6f633ca2b5..83afc8d72f 100644 --- a/cuda_python/setup.py +++ b/cuda_python/setup.py @@ -11,7 +11,8 @@ version = get_version( root="..", relative_to=__file__, - tag_regex="^(?Pv\\d+\\.\\d+\\.\\d+((a|b|rc)\\d+)?)$", + # We deliberately do not want to include the version suffixes (a/b/rc) in cuda-python versioning + tag_regex="^(?Pv\\d+\\.\\d+\\.\\d+)", git_describe_command=["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"], ) From a45938fe988bf49955ea08b1004b9920c331c910 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Thu, 18 Dec 2025 16:33:53 -0500 Subject: [PATCH 05/12] Remove the "bump the version" step --- .github/ISSUE_TEMPLATE/release_checklist.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/release_checklist.yml b/.github/ISSUE_TEMPLATE/release_checklist.yml index 2007c3b067..0fa2765797 100644 --- a/.github/ISSUE_TEMPLATE/release_checklist.yml +++ b/.github/ISSUE_TEMPLATE/release_checklist.yml @@ -20,7 +20,6 @@ body: - label: File an internal nvbug to communicate test plan & release schedule with QA - label: Ensure all pending PRs are reviewed, tested, and merged - label: Check (or update if needed) the dependency requirements - - label: Bump the version - label: Create a public rc tag - label: "Point QA to fetch public artifacts (wheels) from the GHA run ID, example: `gh run download 12323257563 -p \"cuda-core*\" -R NVIDIA/cuda-python`" - label: Wait for QA reports and fix any issues found From 243d13913f2cd843634c707191192a68f16c7612 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 09:22:24 -0500 Subject: [PATCH 06/12] Search for cuda_bindings wheel locally --- .github/workflows/test-wheel-linux.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-wheel-linux.yml b/.github/workflows/test-wheel-linux.yml index 75a0c4193b..0459dba398 100644 --- a/.github/workflows/test-wheel-linux.yml +++ b/.github/workflows/test-wheel-linux.yml @@ -268,10 +268,12 @@ jobs: - name: Ensure cuda-python installable run: | + echo Showing wheels locally in $PWD + ls *.whl if [[ "${{ matrix.LOCAL_CTK }}" == 1 ]]; then - pip install cuda_python*.whl + pip install cuda_python*.whl --find-links . else - pip install $(ls cuda_python*.whl)[all] + pip install $(ls cuda_python*.whl)[all] --find-links . fi - name: Install cuda.pathfinder extra wheels for testing From 6f5597acfd831968c9086dfac93f40cdcc9cc958 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 09:59:09 -0500 Subject: [PATCH 07/12] Try a different --find-links directory --- .github/workflows/test-wheel-linux.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-wheel-linux.yml b/.github/workflows/test-wheel-linux.yml index 0459dba398..ff76db74f1 100644 --- a/.github/workflows/test-wheel-linux.yml +++ b/.github/workflows/test-wheel-linux.yml @@ -269,11 +269,14 @@ jobs: - name: Ensure cuda-python installable run: | echo Showing wheels locally in $PWD - ls *.whl + ls ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}/*.whl + # We need to find the `cuda_bindings` dependency from a local + # directory, rather than on PyPI, since the version hasn't been + # released yet. if [[ "${{ matrix.LOCAL_CTK }}" == 1 ]]; then - pip install cuda_python*.whl --find-links . + pip install cuda_python*.whl --find-links ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }} else - pip install $(ls cuda_python*.whl)[all] --find-links . + pip install $(ls cuda_python*.whl)[all] --find-links ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }} fi - name: Install cuda.pathfinder extra wheels for testing From 68ace966e565bb6b6dfec7fbfb413ef5ac3a94a1 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 10:44:48 -0500 Subject: [PATCH 08/12] Get more info --- .github/workflows/test-wheel-linux.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test-wheel-linux.yml b/.github/workflows/test-wheel-linux.yml index ff76db74f1..1eccc541c3 100644 --- a/.github/workflows/test-wheel-linux.yml +++ b/.github/workflows/test-wheel-linux.yml @@ -283,6 +283,7 @@ jobs: run: | set -euo pipefail pushd cuda_pathfinder + ls -R pip install --only-binary=:all: -v . --group "test-cu${TEST_CUDA_MAJOR}" pip list popd From c7b6956c014cc13fcfd164a48b51e4e95dd4b2f4 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 11:02:01 -0500 Subject: [PATCH 09/12] Fix cuda_python version specifier --- cuda_python/setup.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/cuda_python/setup.py b/cuda_python/setup.py index 83afc8d72f..a1a70d4076 100644 --- a/cuda_python/setup.py +++ b/cuda_python/setup.py @@ -17,16 +17,24 @@ ) -version = Version(version).base_version +base_version = Version(version).base_version + + +if base_version == version: + # Tagged release + matcher = "~=" +else: + # Pre-release version + matcher = "==" setup( version=version, install_requires=[ - f"cuda-bindings~={version}", + f"cuda-bindings{matcher}{version}", "cuda-pathfinder~=1.1", ], extras_require={ - "all": [f"cuda-bindings[all]~={version}"], + "all": [f"cuda-bindings[all]{matcher}{version}"], }, ) From 75bb3814f271215e913b770758904600c6f65edb Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 11:15:57 -0500 Subject: [PATCH 10/12] Fix pathfinder install --- .github/workflows/test-wheel-linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-wheel-linux.yml b/.github/workflows/test-wheel-linux.yml index 1eccc541c3..87f3df244f 100644 --- a/.github/workflows/test-wheel-linux.yml +++ b/.github/workflows/test-wheel-linux.yml @@ -284,7 +284,7 @@ jobs: set -euo pipefail pushd cuda_pathfinder ls -R - pip install --only-binary=:all: -v . --group "test-cu${TEST_CUDA_MAJOR}" + pip install --only-binary=:all: -v ./*.whl --group "test-cu${TEST_CUDA_MAJOR}" pip list popd From 3dfd4715f2a114faa1f9913bbc99da4b17b68e94 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 11:47:40 -0500 Subject: [PATCH 11/12] Revert some changes in the Linux wheel, add comments --- .github/workflows/test-wheel-linux.yml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/test-wheel-linux.yml b/.github/workflows/test-wheel-linux.yml index 87f3df244f..97d7bfb198 100644 --- a/.github/workflows/test-wheel-linux.yml +++ b/.github/workflows/test-wheel-linux.yml @@ -268,22 +268,18 @@ jobs: - name: Ensure cuda-python installable run: | - echo Showing wheels locally in $PWD - ls ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }}/*.whl - # We need to find the `cuda_bindings` dependency from a local - # directory, rather than on PyPI, since the version hasn't been - # released yet. if [[ "${{ matrix.LOCAL_CTK }}" == 1 ]]; then - pip install cuda_python*.whl --find-links ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }} + pip install cuda_python*.whl else - pip install $(ls cuda_python*.whl)[all] --find-links ${{ env.CUDA_BINDINGS_ARTIFACTS_DIR }} + pip install $(ls cuda_python*.whl)[all] fi - name: Install cuda.pathfinder extra wheels for testing run: | set -euo pipefail pushd cuda_pathfinder - ls -R + # Install pathfinder from the pre-built wheel, since building from + # source won't work in this context (we don't have a git checkout). pip install --only-binary=:all: -v ./*.whl --group "test-cu${TEST_CUDA_MAJOR}" pip list popd From 1426277ea52ceb1e8fc24e5bfa42f77bf9b7a3b0 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Fri, 19 Dec 2025 13:28:07 -0500 Subject: [PATCH 12/12] Simplify import --- cuda_pathfinder/cuda/pathfinder/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cuda_pathfinder/cuda/pathfinder/__init__.py b/cuda_pathfinder/cuda/pathfinder/__init__.py index 5258890a9d..afffd54263 100644 --- a/cuda_pathfinder/cuda/pathfinder/__init__.py +++ b/cuda_pathfinder/cuda/pathfinder/__init__.py @@ -3,7 +3,7 @@ """cuda.pathfinder public APIs""" -from cuda.pathfinder._version import __version__ as __version__ +from cuda.pathfinder._version import __version__ # noqa: F401 from cuda.pathfinder._dynamic_libs.load_dl_common import DynamicLibNotFoundError as DynamicLibNotFoundError from cuda.pathfinder._dynamic_libs.load_dl_common import LoadedDL as LoadedDL