Skip to content

Commit b220b81

Browse files
rwgkgithub-actions[bot]
authored andcommitted
[no-ci] Refreeze enum tables (revert 2383, add comment) (#2792)
* Revert "cuda.core: refresh frozen CUresult explanation table for CUDA 13.3 (#2383)" This reverts commit 3df6115. * Add comment: Do not update it past CUDA Toolkit v13.1.1 * Narrow CI workaround for cufile ABI issue (cherry picked from commit 7b89d2c)
1 parent 6d3d20a commit b220b81

3 files changed

Lines changed: 8 additions & 26 deletions

File tree

‎.github/RELEASE-core.md‎

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -89,21 +89,6 @@ changes, so they are only permitted at a major-version boundary per the
8989

9090
---
9191

92-
## Refresh frozen fallback explanation tables
93-
94-
When this release adds support for a new CUDA Toolkit version, check
95-
whether the CTK release added any new `CUresult` or `cudaError_t` codes.
96-
If so, update the frozen fallback tables so error messages stay
97-
informative for consumers on older `cuda-bindings` versions:
98-
99-
- `cuda_core/cuda/core/_utils/driver_cu_result_explanations_frozen.py`
100-
- `cuda_core/cuda/core/_utils/runtime_cuda_error_explanations_frozen.py`
101-
102-
The corresponding tests in `test_utils_enum_explanations_helpers.py`
103-
will fail if an entry is missing.
104-
105-
---
106-
10792
## Finalize the doc update, including release notes
10893

10994
Review every PR included in the release. For each one, check whether new

‎cuda_core/cuda/core/_utils/driver_cu_result_explanations_frozen.py‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,14 @@
11
# SPDX-FileCopyrightText: Copyright (c) 2025-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
22
# SPDX-License-Identifier: Apache-2.0
33

4-
# CUDA Toolkit v13.3
4+
# Like the runtime counterpart, this fallback is a deliberately frozen
5+
# compatibility snapshot, not a release-maintained mirror of CUDA's enums.
6+
# Do not update it past CUDA Toolkit v13.1.1. Bindings releases new enough to
7+
# define later codes provide explanations through enum-member docstrings; if an
8+
# older binding receives one from a newer driver, it falls through to
9+
# cuGetErrorString(). Synchronizing this table with later Toolkit releases would
10+
# restore the duplicate maintenance burden removed by PR #1860.
11+
# CUDA Toolkit v13.1.1
512
_FALLBACK_EXPLANATIONS = {
613
0: (
714
"The API call returned with no errors. In the case of query calls, this"
@@ -346,6 +353,5 @@
346353
" stream is in a detached state. This can occur if the green context associated"
347354
" with the stream has been destroyed, limiting the stream's operational capabilities."
348355
),
349-
918: "This error indicates that a graph recapture failed and had to be terminated.",
350356
999: "This indicates that an unknown internal error has occurred.",
351357
}

‎cuda_core/tests/test_utils_enum_explanations_helpers.py‎

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -168,12 +168,3 @@ def test_runtime_explanations_module_skips_fallback_import_when_docstrings_avail
168168

169169
assert "cuda.core._utils.runtime_cuda_error_explanations_frozen" not in sys.modules
170170
assert isinstance(runtime_explanations.RUNTIME_CUDA_ERROR_EXPLANATIONS, DocstringBackedExplanations)
171-
172-
173-
@pytest.mark.human_authored
174-
def test_frozen_driver_table_covers_all_curesult_members():
175-
from cuda.bindings import driver
176-
from cuda.core._utils.driver_cu_result_explanations_frozen import _FALLBACK_EXPLANATIONS
177-
178-
missing = [m.name for m in driver.CUresult if int(m) not in _FALLBACK_EXPLANATIONS]
179-
assert not missing, f"Missing frozen fallback explanations for: {missing}"

0 commit comments

Comments
 (0)