Add Python 3.15 to the test matrix#2108
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 |
|
/ok to test |
|
/ok to test |
|
It seems we need to build PY315 in the https://github.com/NVIDIA/cuda-python/actions/runs/26123422715/job/76831314547?pr=2108#step:38:76 |
Backport of #2108 to the 12.9.x branch so that cuda-bindings 12.9.x wheels are available for Python 3.15, which the main branch needs in order to build cuda-core. - Add 3.15 / 3.15t to the build matrix - Upgrade cibuildwheel to v4.0.0rc1 (required for cpython-prerelease) - Enable cpython-prerelease in CIBW_ENABLE - Add amd64-only test entries for 3.15 / 3.15t (CUDA 12.9.1)
This is done in #2133. Need to merge it first and then apply the learnings there in this PR. |
* Add Python 3.15 to the build/test matrix Backport of #2108 to the 12.9.x branch so that cuda-bindings 12.9.x wheels are available for Python 3.15, which the main branch needs in order to build cuda-core. - Add 3.15 / 3.15t to the build matrix - Upgrade cibuildwheel to v4.0.0rc1 (required for cpython-prerelease) - Enable cpython-prerelease in CIBW_ENABLE - Add amd64-only test entries for 3.15 / 3.15t (CUDA 12.9.1) * Drop cpython-freethreading from CIBW_ENABLE (default in v4.0) * Drop 3.13t from matrix; fix GNU link.exe on Windows - Remove 3.13t from build matrix and all test matrices (already dropped on main). - Work around Meson finding GNU link.exe (from Git for Windows) instead of MSVC link.exe when building numpy from source for pre-release Python on Windows. * Expand test matrix: arm64 3.15, Windows 3.10-3.15 - Add arm64 entries for 3.15 / 3.15t (linux pull-request) - Add Windows pull-request entries for 3.10, 3.11, 3.14, 3.14t, 3.15, 3.15t to keep in sync with main * Windows test matrix: dual LOCAL_CTK for 3.10/3.11, use 12.9.1 for 3.13 * Pre-build numpy wheel for Python 3.15 (no pre-built wheel yet) NumPy does not ship pre-built wheels for Python 3.15 yet. Build the wheel from source during the build stage (where compilers are available), upload it as an artifact, and download/install it in the test stage before running cuda.bindings tests. * Build numpy in manylinux container for glibc compat; fix Windows glob Linux: build numpy via cibuildwheel inside the manylinux_2_28 container so the wheel is compatible with the ubuntu:22.04 test container (glibc 2.35). Previously, pip wheel on the host produced a linux_x86_64 wheel linked against glibc 2.38+, causing ImportError at test time. Windows: add explicit bash shell to the numpy install step in the test workflow — PowerShell does not expand *.whl globs. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fix numpy cibuildwheel: patch cpython-freethreading, unify platforms - Patch numpy 2.4.x pyproject.toml to remove the "cpython-freethreading" enable group, which is invalid in cibuildwheel v4.0 (fixed on numpy main but not yet released). - Consolidate Linux/Windows numpy builds into a single cibuildwheel step, matching how cuda.core and cuda.bindings are built. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Strip numpy cibuildwheel config; build without BLAS numpy 2.4.x ships [tool.cibuildwheel] config (OpenBLAS scripts, cpython-freethreading, ILP64 settings) incompatible with cibuildwheel v4.0. Strip the entire section from the sdist and build with -Dallow-noblas=true — we only need numpy for testing, not optimized linear algebra. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fix numpy pyproject.toml patch to preserve [tool.meson-python] The previous regex stripped everything from [tool.cibuildwheel] to EOF, which also removed [tool.meson-python] with its vendored meson path. Use a line-by-line approach to only remove cibuildwheel sections. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fix test_graphics_api_smoketest on py3.10/3.11 Windows On py3.10/3.11, pyglet raises FileNotFoundError (an OSError subclass) when opengl32.dll is missing, rather than AttributeError as on py3.12+. Add OSError to the except clause so the test skips gracefully. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Exclude Python 3.15 wheels from release publishing Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
It's merged now. Once the artifacts become available on the |
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
numpy 2.4.x has no pre-built wheel for Python 3.15 yet, and its [tool.cibuildwheel] config is incompatible with cibuildwheel v4.0. Build numpy from patched sdist via cibuildwheel with -Dallow-noblas=true on all platforms (linux-64, linux-aarch64, win-64). Also exclude python315 artifacts from release publishing since 3.15 is pre-release and not ready for PyPI. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…lib/cffi Remove the empty CIBW_REPAIR_WHEEL_COMMAND_WINDOWS that was overriding the pyproject.toml delvewheel config. The pyproject.toml already specifies `delvewheel repair --namespace-pkg cuda` which is the correct behavior. Keep matplotlib and cffi as test dependencies but gate them to python_version < 3.15 (no wheels available yet for 3.15). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
/ok to test 193cbf9 |
Main's CIBW_BUILD is cp315-* (not cp315-manylinux* like 12.9.x), so cibuildwheel builds both manylinux and musllinux numpy wheels. The musllinux wheel is incompatible with the glibc-based test runners. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
/ok to test 2f7a05b |
|
- Skip musllinux and win32 when building numpy (CIBW_BUILD=cp315-* matches both win32 and win_amd64; numpy has no pyproject.toml constraint after we strip its cibuildwheel config) - Mark 3.15/3.15t test jobs as continue-on-error so they don't block CI (3.15t segfaults on CPython beta, rlcompleter test changed behavior) - Skip test_opt_out_env_var_disables_patch_even_when_interactive on Python 3.15 (upstream fixed the rlcompleter bug this test relied on) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
/ok to test d1b8d82 |
nvidia-cutlass depends on scipy, which has no pre-built wheel for Python 3.15 yet. Version-gate the dependency so pathfinder tests can still install the rest of the test dependencies on 3.15. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Mark every temporary 3.15 hack (version-gated deps, numpy pre-build, continue-on-error, allow-prereleases, cpython-prerelease, release exclusion) with a TODO so they are easy to find and remove once 3.15 is officially supported. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
/ok to test 839f785 |
|
The 3.15t pathfinder "see what works" test segfaults, will track it in a separate issue. I configured the CI such that 3.15 test failures are not blocking the status check. This PR is ready for review. https://github.com/NVIDIA/cuda-python/actions/runs/27041829125/job/79822100279?pr=2108#step:28:75 |
nvidia-cutlass is not installed on 3.15 (scipy has no 3.15 wheel), so the pathfinder header discovery tests for cutlass and cute will always fail under all_must_work strictness. Skip those parametrized cases on 3.15+. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
/ok to test ff2eccb |
|
/ok to test d0e136b |
| # TODO: remove cpython-prerelease once 3.15 is officially supported | ||
| # Allow CPython pre-release builds (currently 3.15 / 3.15t). This is a | ||
| # no-op for stable Python versions because CIBW_BUILD still filters | ||
| # the target version. | ||
| CIBW_ENABLE: cpython-prerelease |
There was a problem hiding this comment.
Does this have any impact to us once 3.15 is released? We'd just need to readd this when 3.16 needs to ramp up.
Part of #2163.
Add Python 3.15 to the test matrix (Linux x86 only for now) so that we are ready for any issues by October.