Skip to content

Commit 344d7bd

Browse files
rparolinclaude
andcommitted
test(cuda.core): track the numba_debug removal in the release checklist
The version-gated `test_numba_debug_removal_is_due_at_2_0` fails the build the moment `cuda.core.__version__` crosses 2.0. That bump lands on an ordinary release-prep PR during code freeze, so the test turns red at the worst possible time and is indistinguishable from a real regression to anyone who did not write it. Drop it, and put the reminder where release managers already look: - Remove the test and the now-unused `import cuda.core`. - Add a release-checklist item to sweep deprecations whose stated removal version has arrived, with matching guidance in RELEASE-core.md. The sweep greps `deprecated::` rather than `\.\. deprecated::` so it also catches the two `Device.max_links` sites, which spell the directive `.. version-deprecated::`. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 05f1990 commit 344d7bd

3 files changed

Lines changed: 22 additions & 20 deletions

File tree

‎.github/ISSUE_TEMPLATE/release_checklist.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ body:
2020
- label: File an internal nvbug to communicate test plan & release schedule with QA
2121
- label: Ensure all pending PRs are reviewed, tested, and merged
2222
- label: Check (or update if needed) the dependency requirements
23+
- label: Sweep deprecations whose stated removal version has arrived (`grep -rn 'deprecated::' cuda_core/cuda`) and remove any that are due
2324
- label: "Finalize the doc update, including release notes (\"Note: Touching docstrings/type annotations in code is OK during code freeze, apply your best judgement!\")"
2425
- label: Update the docs for the new version
2526
- label: Create a public release tag

‎.github/RELEASE-core.md‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,27 @@ requirements are current.
6666

6767
---
6868

69+
## Sweep deprecations whose removal version has arrived
70+
71+
Deprecated APIs are marked in the source with a Sphinx `deprecated`
72+
directive naming the version that introduced the deprecation, and their
73+
docstrings state the version in which they will be removed. Find them all
74+
with:
75+
76+
```console
77+
$ grep -rn 'deprecated::' cuda_core/cuda
78+
```
79+
80+
For each hit, check the stated removal version against the version being
81+
released. If the release has reached or passed it, remove the API, its
82+
runtime `DeprecationWarning`, and any tests asserting that warning.
83+
84+
This must happen *before* the release tag is cut. Removals are breaking
85+
changes, so they are only permitted at a major-version boundary per the
86+
[support policy](https://nvidia.github.io/cuda-python/cuda-core/latest/support.html).
87+
88+
---
89+
6990
## Finalize the doc update, including release notes
7091

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

‎cuda_core/tests/test_linker.py‎

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77

88
import pytest
99

10-
import cuda.core
1110
from cuda.core import Device, Linker, LinkerOptions, Program, ProgramOptions, _linker
1211
from cuda.core._module import ObjectCode
1312
from cuda.core._program import _can_load_generated_ptx
@@ -438,25 +437,6 @@ def test_prepare_driver_options_unsupported_raises(driver_binding, kwargs, match
438437
opts._prepare_driver_options()
439438

440439

441-
@pytest.mark.agent_authored(model="claude-opus-5")
442-
def test_numba_debug_removal_is_due_at_2_0():
443-
"""Forcing function for the deprecation queued in #2640.
444-
445-
``LinkerOptions.numba_debug`` is deprecated in 1.2.0 and must be removed at
446-
the next major-version boundary. Nothing else in the repo tracks a scheduled
447-
removal -- the existing precedent (``Device.max_links``) only says "a future
448-
release" -- so this test fails the build the moment the version crosses 2.0,
449-
rather than letting a dead field survive into the 2.x line unnoticed.
450-
"""
451-
major = int(cuda.core.__version__.split(".")[0])
452-
if major >= 2:
453-
pytest.fail(
454-
"cuda.core is now 2.x: remove the deprecated LinkerOptions.numba_debug field, "
455-
"its __post_init__ DeprecationWarning, and this test."
456-
)
457-
assert hasattr(LinkerOptions(arch="sm_80"), "numba_debug")
458-
459-
460440
@pytest.mark.agent_authored(model="claude-opus-5")
461441
@pytest.mark.parametrize("value", [True, False])
462442
def test_numba_debug_warns_and_is_ignored(value):

0 commit comments

Comments
 (0)