Skip to content

Only throw alpha spec and use_cuda_wheels warnings for Python output types - #155

Merged
rapids-bot[bot] merged 2 commits into
rapidsai:mainfrom
KyleFromNVIDIA:dependencies-yaml-python-output-types
Sep 16, 2026
Merged

rapids-bot[bot] merged 2 commits into
rapidsai:mainfrom
KyleFromNVIDIA:dependencies-yaml-python-output-types

Conversation

@KyleFromNVIDIA

Copy link
Copy Markdown
Member

These warnings were previously being issued even for Conda output, while the cuda_suffixed warning correctly ignored it for Conda. Apply the exclusion to alpha spec and use_cuda_wheels too.

…t types

These warnings were previously being issued even for Conda output, while
the `cuda_suffixed` warning correctly ignored it for Conda. Apply the
exclusion to alpha spec and `use_cuda_wheels` too.
@KyleFromNVIDIA
KyleFromNVIDIA requested a review from a team as a code owner September 16, 2026 18:56
@coderabbitai

coderabbitai Bot commented Sep 16, 2026 •

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 0d160d34-a269-4666-ae6d-b33b2d3542c1

📥 Commits

Reviewing files that changed from the base of the PR and between 352a42e and a60aaa3.

📒 Files selected for processing (7)
  • src/rapids_pre_commit_hooks/alpha_spec.py
  • src/rapids_pre_commit_hooks/dependencies/cuda_suffixed.py
  • src/rapids_pre_commit_hooks/dependencies/use_cuda_wheels.py
  • src/rapids_pre_commit_hooks/utils/dependencies_yaml.py
  • tests/rapids_pre_commit_hooks/dependencies/test_use_cuda_wheels.py
  • tests/rapids_pre_commit_hooks/test_alpha_spec.py
  • tests/rapids_pre_commit_hooks/utils/test_dependencies_yaml.py

Included review availability: Your plan provides up to 12 included reviews per hour; 11 remain after this review.


📝 Summary

Summary by CodeRabbit

  • Bug Fixes

    • Alpha-spec package validation now applies only to Python dependency outputs: requirements, constraints, and pyproject.
    • CUDA wheel checks now correctly distinguish Python dependency outputs from other output types.
    • Non-Python outputs, such as Conda outputs, no longer receive warnings intended for Python dependency configurations.
  • Tests

    • Added coverage for Python and non-Python output handling across alpha-spec and CUDA wheel validation.
    • Added tests confirming supported Python output types are recognized correctly.

Walkthrough

Changes

The hooks now classify Python output types consistently. Alpha-spec and CUDA wheel validation use item-level context and suppress package warnings for non-Python outputs. Tests cover classification, deferred validation, and Conda cases.

Python output validation

Layer / File(s) Summary
Shared output-type classification
src/rapids_pre_commit_hooks/utils/dependencies_yaml.py, tests/rapids_pre_commit_hooks/utils/test_dependencies_yaml.py
Adds is_python_output_type and tests its supported values.
Alpha-spec item validation
src/rapids_pre_commit_hooks/alpha_spec.py, tests/rapids_pre_commit_hooks/test_alpha_spec.py
Tracks Python output state, collects package nodes, and performs deferred package validation. Integration tests cover Python and Conda outputs.
CUDA wheel dependency validation
src/rapids_pre_commit_hooks/dependencies/cuda_suffixed.py, src/rapids_pre_commit_hooks/dependencies/use_cuda_wheels.py, tests/rapids_pre_commit_hooks/dependencies/test_use_cuda_wheels.py
Uses shared output classification, tracks common and specific item contexts, defers matrix checks, and suppresses warnings for non-Python outputs. Tests cover common packages, matrices, and Conda integration cases.

Priority: ⬇️ Low

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Bug fix

Suggested reviewers: jameslamb

Merge Risk: ⚪ Minimal · up to a60aa

The change scopes dependency warnings to Python output types, with no actionable merge risk identified in the supplied evidence.

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: alpha spec and use_cuda_wheels warnings now apply only to Python output types.
Description check ✅ Passed The description directly explains the warning behavior change and the exclusion of Conda output.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@bdice bdice left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems reasonable to me.

@KyleFromNVIDIA

Copy link
Copy Markdown
Member Author

/merge

@rapids-bot
rapids-bot Bot merged commit a815b2f into rapidsai:main Sep 16, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants