CI: Test sdist builds for all user-facing packages#1909
CI: Test sdist builds for all user-facing packages#1909cpcloud wants to merge 4 commits intoNVIDIA:mainfrom
Conversation
|
e65f1ed to
113573e
Compare
Add a new test-sdist workflow that builds an sdist and then a wheel-from-sdist for each of the 4 user-facing packages (cuda_pathfinder, cuda_python, cuda_bindings, cuda_core). This catches regressions in MANIFEST.in or package-data configuration that could silently break sdist-based builds. Closes NVIDIA#1599 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Match existing test jobs' doc-only guard so docs-only PRs don't run source-build validation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
cuda_bindings build backend imports cuda.pathfinder, so pip's build isolation needs to find the locally-built cuda_pathfinder wheel instead of pulling from PyPI. Set PIP_FIND_LINKS to the pathfinder dist directory. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
actionlint rejects non-GitHub-hosted runner labels unless declared in .github/actionlint.yaml. This was causing pre-commit.ci failures on test-sdist.yml which uses linux-amd64-cpu8. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
7916cf3 to
47bccd8
Compare
|
Posting this separately as an optional suggestion. LGTM will be in another comment. Outcome of a few rounds of prompt/response using Cursor GPT-5.4 Extra High Fast AnalysisI think the current However,
So I would frame this as a robustness / explicitness issue more than an immediate correctness bug. The nice part is that I think removing that uncertainty is fairly easy. Suggestions1. Best balance: keep build isolation, add exact build constraintsThis seems like the best option to me. Keep the existing pattern:
But add exact For For
Why this is attractive:
2. Stronger but heavier: use
|
rwgk
left a comment
There was a problem hiding this comment.
Looks great.
One small caveat: the new test-sdist job only runs on Linux, so it does not fully prove platform-independent sdist completeness for packages that have platform-specific sources. For example, cuda_bindings/build_hooks.py selects different *_linux.pyx vs *_windows.pyx files, so a missing or stale Windows-only source could still slip through. I think this is still a useful test as-is; I would probably either add a small Windows follow-up job (at least for cuda_bindings, and likely cuda_core too), or keep this PR as-is but make it clear in the PR title and description that this is a Linux-side sdist smoke test rather than a full cross-platform proof.
Summary
.github/workflows/test-sdist.ymlreusable workflow that builds sdist then wheel-from-sdist for all 4 user-facing packagesPIP_FIND_LINKSci.ymlastest-sdistjob, gated byshould-skipanddoc-only, included inchecksCloses #1599
🤖 Generated with Claude Code