Fix missing binding version checks alongside driver version checks#2054
Merged
leofang merged 1 commit intoNVIDIA:mainfrom May 8, 2026
Merged
Conversation
Two source locations and one test helper only checked the driver version when gating features that also require the corresponding cuda-bindings version. When bindings are older than the driver, the driver check passes but the binding attribute/symbol is missing, causing AttributeError or similar runtime failures. - graph/_subclasses.pyx: _check_node_get_params() now also checks binding_version() >= (13, 2, 0) - _module.pyx: _get_arguments_info() now also checks cy_binding_version() >= (12, 4, 0) - tests/graph/test_graph_definition.py: _driver_has_node_get_params() renamed to _has_node_get_params() and checks both versions Closes NVIDIA#2052
Contributor
Member
Author
|
/ok to test 8e7bbac |
This comment has been minimized.
This comment has been minimized.
Andy-Jost
approved these changes
May 8, 2026
Contributor
|
We should add rules such as "always check both the driver and bindings version for feature gates" to a place where agents can find them. I don't know whether AGENTS.md is the right place, but we should collect these somewhere. |
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #2052. Audited all version checks introduced by #1825 and found two additional source-level instances (plus one test helper) where only the driver version was checked but the binding version was not.
When
cuda-bindingsis older than the CUDA driver, the driver version gate passes but the corresponding binding attribute/symbol is absent, causingAttributeError(Python-level) or similar failures (Cython-level).graph/_subclasses.pyx:_check_node_get_params()now also checksbinding_version() >= (13, 2, 0)(the bug reported in [BUG]:_has_cuGraphNodeGetParamscheck missed the binding version check #2052)_module.pyx:_get_arguments_info()now also checkscy_binding_version() >= (12, 4, 0)(gatescuKernelGetParamInfo, exposed viaKernel.num_arguments/Kernel.arguments_info)tests/graph/test_graph_definition.py:_driver_has_node_get_params()renamed to_has_node_get_params()and checks both versionsTest plan
ConditionalNodeinstead of crashingKernel.num_argumentsshould raiseNotImplementedErrorinstead of crashing