Repository navigation
Conversation
|
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. |
|
/ok to test 1142000 |
|
1142000 to
5841a92
Compare
mdboom
left a comment
There was a problem hiding this comment.
The most blocking thing here is hard-coding the minor version in the git describe glob. It means there is an extra step required before tagging and merging a release. My agent seems nothing wrong with making it v13.*, though it would require updating a test here.
| - name: Set up Python for CI tool tests | ||
| uses: ./.github/actions/setup-hardened-python | ||
| with: | ||
| python-version: "3.12" |
There was a problem hiding this comment.
Why Python 3.12? We could use the latest, but probably the right conservative thing here to avoid breaking any outside users who might want to compile cuda-python themselves is to use the oldest supported (currently 3.11).
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
Changed the tooling jobs to Python 3.11, exercising the supported lower bound. implementation.
| - name: Test CI tools | ||
| run: | | ||
| python -m pip install pytest==9.1.0 pyyaml==6.0.3 setuptools-scm | ||
| python -m pytest -v --noconftest ci/tools/tests |
There was a problem hiding this comment.
Is there an explicit reason for --noconftest? That will be confusing if we ever want a conftest in the future.
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
Removed --noconftest and the stale explanation; these tests now use normal pytest collection. implementation.
|
|
||
| def main() -> int: | ||
| """Verify cuda_bindings_13/cuda_core pixi pins match ci/versions.yml.""" | ||
| """Verify current bindings and cuda_core pixi pins match ci/versions.yml.""" |
There was a problem hiding this comment.
Makes total sense for now. Maybe it's already higher up in the stack, but we should make sure to come back and add this check to legacy (12) as well. If not already in the stack, let's create an issue or just add a TODO comment here so it doesn't fall through the cracks.
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
#3315 extends this check to the CUDA 12 bindings root. implementation.
| root = ".." | ||
| version_file = "cuda/bindings/_version.py" | ||
| git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"] | ||
| git_describe_command = ["git", "describe", "--dirty", "--tags", "--long", "--match", "v13.4.*"] |
There was a problem hiding this comment.
Note to me: this is a UNIX glob pattern not a regex.
Do we need v13.4.* here? It kind of defeats the purpose of "simply" tagging to make a release, as we would now require a bump to this number at each minor release.
If it /must/ be this way, we need to update the release TODO instructions to add this extra step. By the time we tag the release, it will be too late to update this number, so it shouldn't be forgotten.
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
Changed the selector to v13.*, so toolkit-minor changes need no selector edit. The metadata check and documentation now follow that contract. implementation; metadata check.
| root="..", | ||
| relative_to=__file__, | ||
| git_describe_command=["git", "describe", "--dirty", "--tags", "--long", "--match", "v*[0-9]*"], | ||
| git_describe_command=["git", "describe", "--dirty", "--tags", "--long", "--match", "v13.4.*"], |
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
The metapackage uses the same v13.* selector. implementation.
|
|
||
| - name: Test CI tools | ||
| run: | | ||
| python -m pip install pytest==9.1.0 pyyaml==6.0.3 setuptools-scm |
There was a problem hiding this comment.
Nit: Since ci/tools is now a package, it should have a pyproject.toml and specify its dependencies there (making it easier to run the tests locally). That can be a "side quest", though. Maybe create an issue to come back to it.
EDIT: It looks like #3315 does this.
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
As noted in the edit, #3315 supplies ci/pyproject.toml. implementation.
| from .bindings_config import load_config | ||
|
|
||
| ROOT = Path(__file__).resolve().parents[2] | ||
| VERSIONS_FILE_PATH = ROOT / "ci" / "versions.yml" |
There was a problem hiding this comment.
Nit: Duplicated from bindings_config.py which should own knowing where the canonical location of this file is. Rather than checking for its existence here, bindings_config.py should (and already does) raise an exception when the file doesn't exist.
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
Removed the duplicate path constant and delegated loading to bindings_config. implementation.
| if not VERSIONS_FILE_PATH.is_file(): | ||
| print(f"error: {VERSIONS_FILE_PATH} not found", file=sys.stderr) | ||
| return 2 |
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
Removed the check; the configuration loader reports a missing file. implementation.
| build_version = yaml.safe_load(VERSIONS_FILE_PATH.read_text(encoding="utf-8"))["cuda"]["build"]["version"] | ||
| except (KeyError, TypeError): | ||
| print(f"error: cuda.build.version not found in {VERSIONS_FILE_PATH}", file=sys.stderr) | ||
| current = load_config(VERSIONS_FILE_PATH).package_for_release_status("current") |
There was a problem hiding this comment.
| current = load_config(VERSIONS_FILE_PATH).package_for_release_status("current") | |
| current = load_config().package_for_release_status("current") |
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
The caller uses the loader's default configuration path. implementation.
| print(f"error: cuda.build.version not found in {VERSIONS_FILE_PATH}", file=sys.stderr) | ||
| current = load_config(VERSIONS_FILE_PATH).package_for_release_status("current") | ||
| except (KeyError, TypeError, ValueError) as exc: | ||
| print(f"error: invalid CUDA toolkit pins in {VERSIONS_FILE_PATH}: {exc}", file=sys.stderr) |
There was a problem hiding this comment.
| print(f"error: invalid CUDA toolkit pins in {VERSIONS_FILE_PATH}: {exc}", file=sys.stderr) | |
| print(f"error: invalid CUDA toolkit pins in {bindings_config.DEFAULT_CONFIG}: {exc}", file=sys.stderr) |
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
The diagnostic refers to bindings_config.DEFAULT_CONFIG. implementation.
Signed-off-by: Ralf W. Grosse-Kunstleve <[email protected]>
Signed-off-by: Ralf W. Grosse-Kunstleve <[email protected]>
Signed-off-by: Ralf W. Grosse-Kunstleve <[email protected]>
98ed2a6 to
7798130
Compare
rwgk
left a comment
There was a problem hiding this comment.
— codex GPT-6 on behalf of Ralf —
The blocker in your review is addressed: the bindings and metapackage selectors use v13.*, with matching tests and guidance. Toolkit-minor updates no longer require a selector edit.
All 15 inline comments now have direct replies with source links. The smaller tooling/configuration changes are applied; the CUDA 12 Pixi check and CI package are supplied by #3315. This corrected layer can serve as the common prerequisite for the retained-tag/bootstrap cleanup discussed there.
— codex GPT-6 on behalf of Ralf —
Layer 1 of 7 of the staged "CUDA 12 bindings on
main" stack. Next: #3315. Stack map at the bottom.What this PR does
Two small preparations. Nothing CI does today changes.
ci/tools/bindings_config.py(60 lines) turns the existingcuda.build.version/cuda.prev_build.versionpins inci/versions.ymlinto two records:cuda_bindings_13is current (13.4.2),cuda_bindings_12is maintenance (12.9.1). The pixi pin check is its first consumer.ci/becomes an importable package, anddetect-changesnow runs the wholeci/tools/testssuite with pytest (before: only the planner test, viaunittest).cuda_bindings_13/pyproject.tomlandcuda_python/setup.pynarrow the setuptools-scm selector fromv*[0-9]*tov13.*. The planned retained CUDA 12 milestone is then excluded from CUDA 13 version derivation.After this merges
mainbuilds, tests, and releases exactly as before.v12.9.11a0tag onmaincan no longer disturb CUDA 13 version derivation (covered bytest_cuda12_milestone_does_not_change_current_package_versions, which derives its current release tag and expected line from the registry).Where to look
ci/tools/bindings_config.py: the data model the rest of the stack builds on.cuda_bindings_13/pyproject.tomlandcuda_python/setup.py: the two one-line selector changes.ci/tools/check_pixi_cuda_version.py: same check as before, now reading the registry.All changes (10 files, +213 / -25)
ci/tools/bindings_config.py(new):BindingsPackage,BindingsConfig,load_config().ci/__init__.py,ci/tools/__init__.py(new, empty): makepython -m ci.tools.<module>work.ci/tools/check_pixi_cuda_version.py: read pins through the registry; same checks.ci/tools/tests/test_bindings_config.py(new): registry normalization, pixi-check drift, and the "CUDA 12 milestone does not change CUDA 13 versions" test (real git repository, real pyproject/setup.py)..github/workflows/ci.yml:detect-changesinstalls pytest/pyyaml/setuptools-scm on hardened Python and runspytest ci/tools/tests..github/workflows/ci-nightly.yml: the release-tooling test job installs setuptools-scm too..pre-commit-config.yaml: the pixi hook runs aspython -m ci.tools.check_pixi_cuda_versionand also triggers on the two tool files.cuda_bindings_13/pyproject.toml,cuda_python/setup.py:--match v13.*.Validation
1142000b(run 41171069718, 104 jobs).77981309e15bed0531b4ca595acf89d4095c90af: 309 CI-tool tests and configured workflow lint passed. Full-stack CI on #3322 passed at126ed74fb5bbfbc91a04e50557cf936efef4da7f(105 successful jobs; one expected skip).Stack map: what
maincan do after each layer mergesmain...v12.*tagcuda_bindings_12/; the PR-time CPU source-build smoke covers both roots; three CUDA 12 runtime fixes are incuda.coreand the metapackage still consume12.9.xartifacts12.9.xbranchv12.9.Ntag onmain; CUDA 13 releases are unchanged12.9.xis frozenEvery layer was designed to be mergeable on its own and had a green full CI run at its pre-rebase head on 2026-10-31. The stack is the "individually mergeable pieces" alternative to #3174-#3182; both stacks reach the same end state except that this one keeps compatibility routes for older artifact sources and retained CUDA 13 tags.