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
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ on:
branches:
- "pull-request/[0-9]+"
- "main"
- "release/*"

jobs:
ci-vars:
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/test-wheel-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ jobs:
steps:
- name: Checkout ${{ github.event.repository.name }}
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 1

- name: Validate Test Type
run: |
Expand Down Expand Up @@ -97,8 +95,6 @@ jobs:

- name: Checkout ${{ github.event.repository.name }}
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0

- name: Setup proxy cache
uses: nv-gha-runners/setup-proxy-cache@main
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/test-wheel-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ jobs:
steps:
- name: Checkout ${{ github.event.repository.name }}
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 1

- name: Validate Test Type
run: |
Expand Down Expand Up @@ -76,8 +74,6 @@ jobs:
steps:
- name: Checkout ${{ github.event.repository.name }}
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 0

- name: Setup proxy cache
uses: nv-gha-runners/setup-proxy-cache@main
Expand Down
6 changes: 3 additions & 3 deletions cuda_core/cuda/core/experimental/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
# SPDX-License-Identifier: Apache-2.0

try:
import cuda.bindings
from cuda import bindings
except ImportError:
raise ImportError("cuda.bindings 12.x or 13.x must be installed") from None
else:
cuda_major, cuda_minor = cuda.bindings.__version__.split(".")[:2]
cuda_major, cuda_minor = bindings.__version__.split(".")[:2]
if cuda_major not in ("12", "13"):
raise ImportError("cuda.bindings 12.x or 13.x must be installed")

Expand All @@ -24,7 +24,7 @@
else:
del versioned_mod
finally:
del cuda.bindings, importlib, subdir, cuda_major, cuda_minor
del bindings, importlib, subdir, cuda_major, cuda_minor

import sys # noqa: E402
import warnings # noqa: E402
Expand Down
5 changes: 4 additions & 1 deletion cuda_core/cuda/core/experimental/_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,10 @@ def complete(self, options: GraphCompleteOptions | None = None) -> Graph:
raise RuntimeError(
"Instantiation for device launch failed due to the nodes belonging to different contexts."
)
elif params.result_out == driver.CUgraphInstantiateResult.CUDA_GRAPH_INSTANTIATE_CONDITIONAL_HANDLE_UNUSED:
elif (
_py_major_minor >= (12, 8)
and params.result_out == driver.CUgraphInstantiateResult.CUDA_GRAPH_INSTANTIATE_CONDITIONAL_HANDLE_UNUSED
):
raise RuntimeError("One or more conditional handles are not associated with conditional builders.")
elif params.result_out != driver.CUgraphInstantiateResult.CUDA_GRAPH_INSTANTIATE_SUCCESS:
raise RuntimeError(f"Graph instantiation failed with unexpected error code: {params.result_out}")
Expand Down
8 changes: 4 additions & 4 deletions cuda_core/tests/test_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ def test_graph_conditional_if_else(init_cuda, condition_value):
try:
gb_if, gb_else = gb.if_else(handle)
except RuntimeError as e:
with pytest.raises(RuntimeError, match="^Driver version"):
with pytest.raises(RuntimeError, match="^(Driver|Binding) version"):
raise e
gb.end_building()
b.close()
Expand Down Expand Up @@ -377,7 +377,7 @@ def test_graph_conditional_switch(init_cuda, condition_value):
try:
gb_case = list(gb.switch(handle, 3))
except RuntimeError as e:
with pytest.raises(RuntimeError, match="^Driver version"):
with pytest.raises(RuntimeError, match="^(Driver|Binding) version"):
raise e
gb.end_building()
b.close()
Expand Down Expand Up @@ -568,7 +568,7 @@ def build_graph(condition_value):
try:
gb_case = list(gb.switch(handle, 3))
except Exception as e:
with pytest.raises(RuntimeError, match="^Driver version"):
with pytest.raises(RuntimeError, match="^(Driver|Binding) version"):
raise e
gb.end_building()
raise e
Expand Down Expand Up @@ -599,7 +599,7 @@ def build_graph(condition_value):
try:
graph_variants = [build_graph(0), build_graph(1), build_graph(2)]
except Exception as e:
with pytest.raises(RuntimeError, match="^Driver version"):
with pytest.raises(RuntimeError, match="^(Driver|Binding) version"):
raise e
b.close()
pytest.skip("Driver does not support conditional switch")
Expand Down
Loading