Skip to content

refactor(pathfinder): drop the constant argument of _ctk_windows_wheel_dirs - #3627

Open
rparolin wants to merge 2 commits into
pathfinder-readability/16-type-check-own-importsfrom
pathfinder-readability/18-drop-constant-wheel-dir-arg
Open

rparolin wants to merge 2 commits into
pathfinder-readability/16-type-check-own-importsfrom
pathfinder-readability/18-drop-constant-wheel-dir-arg

Conversation

@rparolin

@rparolin rparolin commented Nov 26, 2026 •

Copy link
Copy Markdown
Collaborator

— codex on behalf of Ralf —

Description

Part 18 of 23 of a readability stack for cuda.pathfinder (stack: #3623 → #3602 → #3603 → #3604 → #3605 → #3606 → #3607 → #3608 → #3609 → #3610 → #3611 → #3613 → #3618 → #3619 → #3620 → #3621 → #3622 → #3627 → #3628 → #3629 → #3630 → #3631 → #3632). No behavior change.

All 27 calls of _ctk_windows_wheel_dirs passed "nvidia/cu13/bin" as the first argument. The helper now holds that directory itself and takes only the CUDA 12 wheel directory, the part that differs per library.

No behavior change. All 50 descriptor records compare equal before and after.

Testing

  • Full cuda_pathfinder test suite at this commit: 1297 passed, 6 skipped (Linux, Python 3.14).
  • pre-commit clean, including mypy-pathfinder. mypy also passes with --platform win32.
  • The step-by-step comparisons against main are still byte-identical (Linux, simulated Windows x64 and arm64), and all 526 public-API scenarios give the same result as fix(pathfinder): check for an already-loaded library before searching the disk #3623.
  • Not run on Windows. Windows rules are exercised by tests that simulate Windows on Linux.

PLC Local Security Evidence (Advisory)

Local advisory checks only, run over the whole stack. Not release-gate results.

Check Status Tool Details
Secrets SKIP Pulse Secret Scanner scanner image not available locally (registry login); the repo trufflehog pre-commit hook passed
SAST WARN Semgrep 1 finding, not from this stack: the existing subprocess.run call in the canary probe, now in canary_probe.py
Dependencies WARN pip-audit / osv-scanner no manifest or lockfile in scope, so the local scan could not run; this stack changes no dependencies
License N/A - no dependencies changed
Container N/A - no container changed

Checklist

  • I have read the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

🤖 Generated with Claude Code

@copy-pr-bot

copy-pr-bot Bot commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@github-actions github-actions Bot added the cuda.pathfinder Everything related to the cuda.pathfinder module label Nov 26, 2026
@rparolin
rparolin added this pull request to stack #3616 November 26, 2026 18:40
@rparolin rparolin added the enhancement Any code-related improvements label Nov 26, 2026
@rparolin rparolin added this to the cuda.pathfinder next milestone Nov 26, 2026
@rparolin rparolin self-assigned this Nov 26, 2026
@rparolin
rparolin requested review from juenglin and rwgk November 26, 2026 18:41
This was referenced Nov 26, 2026
@rparolin
rparolin marked this pull request as ready for review November 26, 2026 18:54
@coderabbitai

coderabbitai Bot commented Nov 26, 2026 •

Copy link
Copy Markdown

Explain Change →

Important

Review skipped

Review was skipped as selected files did not have any reviewable changes.

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 9b2d530 and e9a82dd.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review

No actionable comments were generated in the recent review.

Summary

Summary by CodeRabbit

  • Bug Fixes
    • Improved CUDA 13 library discovery on Windows, with search paths tailored to x64 and ARM64 systems and a fallback path for x64.

The CTK Windows wheel path helper now constructs CUDA 13 search paths directly. The wheel descriptors pass only their library-specific CUDA 12 fallback directory.

Changes: CTK Windows wheel search paths

Layer / File(s) Summary
Define and apply Windows wheel paths
cuda_pathfinder/cuda/pathfinder/_dynamic_libs/descriptor_catalog.py
The helper constructs nvidia/cu13/bin/x86_64 and nvidia/cu13/bin/arm64 paths. The x64 search retains the supplied CUDA 12 fallback. The CTK Windows wheel descriptors now pass only their library-specific CUDA 12 fallback directory.

Suggested reviewers: isvoid

Change: Refactor

Merge Risk: Minimal · previous review 9b2d5

This is a refactor of Windows wheel search directory construction with no intended behavior change. No actionable merge-blocking risk was identified.

Security architecture risk: Minimal · up to 9b2d5

The refactor preserves where CUDA libraries are searched for on Windows, including the search order and the CUDA 12 fallback. No new security exposure was identified in the change.

- [ ] Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 323beb4 and 9b2d530.

Files selected for processing: 1

  • cuda_pathfinder/cuda/pathfinder/_dynamic_libs/descriptor_catalog.py

Included review availability: This review used your included allowance. Your plan provides up to 12 included reviews per hour; 3 remain after this review.

rparolin and others added 2 commits November 26, 2026 11:17
…l_dirs

All 27 calls passed `"nvidia/cu13/bin"` as the first argument. The
helper now holds that directory itself and takes only the CUDA 12 wheel
directory, which is the part that differs per library.

The catalog is unchanged: all 50 descriptor records compare equal before
and after.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Signed-off-by: Rob Parolin <rparolin@nvidia.com>
Signed-off-by: Ralf W. Grosse-Kunstleve <rgrossekunst@nvidia.com>
@rwgk
rwgk removed this pull request from stack #3616 November 26, 2026 19:19
@github-actions

Copy link
Copy Markdown
Contributor

@rwgk
rwgk force-pushed the pathfinder-readability/18-drop-constant-wheel-dir-arg branch from 9b2d530 to e9a82dd Compare November 26, 2026 19:19
@copy-pr-bot

copy-pr-bot Bot commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@rwgk
rwgk changed the base branch from pathfinder-readability/17-check-loaded-before-searching to pathfinder-readability/16-type-check-own-imports November 26, 2026 19:19
@rwgk
rwgk added this pull request to stack #3633 November 26, 2026 19:19

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cuda.pathfinder Everything related to the cuda.pathfinder module enhancement Any code-related improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants