Skip to content

kernels: Add version 0.18.0 - #4253

Draft
luhenry wants to merge 14 commits into
mainfrom
kernels
Draft

luhenry wants to merge 14 commits into
mainfrom
kernels

Conversation

@luhenry

@luhenry luhenry commented Nov 2, 2026 •

Copy link
Copy Markdown
Member

Compiles the kernels._rust PyO3 extension (kernel metadata, locking, digest and signing logic from the kernels-common crate, with rustls/aws-lc). Upstream publishes 28 Linux wheels and no riscv64 one.

Mirrors upstream's publish_kernels.yml linux job and the test steps of its test_kernels.yaml, in the same shape as the existing kernels-data port.

Differs from upstream

  • cibuildwheel replaces PyO3/maturin-action - same build path as build-kernels-data.yml
  • musllinux dropped - rustup.rs ships no riscv64 musl toolchain
  • LICENSE staged into kernels/ - maturin globs licences beside pyproject.toml; upstream wheels ship none

Matrix: cp38-abi3 (built on cp312, tested on cp312/cp313/cp314) + cp314t, the two tags upstream publishes.

Testing

  • CPU torch from our registry instead of upstream's CUDA 2.13/2.14 matrix
  • test_tvm_ffi.py ignored - its Hub kernel ships x86_64 builds only, and apache-tvm-ffi has no cp313/cp314 riscv64 wheel
  • the nvidia-cutlass-dsl dependency re-run is dropped - no riscv64 build exists

License: OK

First CI run pending.

luhenry added a commit that referenced this pull request Nov 2, 2026
matplotlib (unpinned, in CIBW_TEST_REQUIRES) pulls in pillow with no
version constraint; pip reached past our registry's published riscv64
pillow wheel to a newer sdist-only release, which fails to build with
RequiredDependencyException: jpeg (no libjpeg-devel in the image). Same
pattern as the existing cryptography/rfc3161-client entry on this same
line, and as gotcha 291.
tests/test_cli_describe_api.py imports httpx, which huggingface-hub 1.x
pulls in and 2.x replaced with httpx2. Upstream's uv.lock tests against
huggingface-hub 1.32.0, so match it.
The suite downloads kernels-community/relu and
kernels-test-untrusted/ci-test-kernel from the Hub, which publish
x86_64/aarch64 (and CUDA-only) builds only, and kernelizes on "cuda";
upstream runs it on GPU runners only, so these fail with "Cannot find a
build variant for this system" on riscv64.

On cp314t, kernels.variants also drops every arch kernel on free-threaded
Python <3.15, which the variant-resolution tests' hard-coded x86_64/aarch64
systems don't account for (arch-independent: upstream's test CI never runs
a free-threaded interpreter), so those are deselected on that leg only.
Both manylinux_riscv64 legs (cp38-abi3 and cp314t) failed the CLI-without-torch
check with AttributeError: module 'torch' has no attribute 'version'. pytest
exercises torch heavily enough that it writes files into its own installed
site-packages/torch tree; pip's RECORD-based uninstall only removes what it
itself installed, leaving that tree behind as an empty-but-importable
namespace package instead of a clean ModuleNotFoundError. Force the directory
gone before re-importing kernels, matching the clean removal uv's uninstall
gives upstream's own CI.
_publish-wheel.yml now requires a matrix input (main's "publish:
Validate effective wheel targets"), but this PR branch forked before
that landed and kernels has never been merged to main, so
build-kernels.yml never picked up the matching one-line update every
already-published package's workflow got. The merge ref combines the
new required-input _publish-wheel.yml with this branch's old
build-kernels.yml, so any run has failed startup with "Input matrix is
required, but not provided".

Pass it the same way the mass-update commit did for every other
package's publish job.

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant