Skip to content

pylance: add build-pylance.yml for riscv64 wheels - #1622

Merged
luhenry merged 2 commits into
mainfrom
pylance
Sep 11, 2026
Merged

pylance: add build-pylance.yml for riscv64 wheels#1622
luhenry merged 2 commits into
mainfrom
pylance

Conversation

@luhenry

@luhenry luhenry commented Sep 8, 2026

Copy link
Copy Markdown
Member

Compiles Lance's Rust core (arrow, datafusion, lance-index, lance-namespace) into a pyo3 abi3 extension via maturin - pylance is lance's own Python binding, living under python/ in the same repo. Upstream publishes no riscv64 wheel.

Mirrors upstream's pypi-publish.yml.

Differs from upstream

  • protoc from Rocky 10's CRB repo, not a downloaded release zip - same as build-lancedb.yml
  • codegen-units raised from 1 to 16 - the shipped release profile is too slow for this runner
  • Skips the x86_64/aarch64/loongarch64-only fp16kernels feature - no riscv64 equivalent

Matrix: cp312 only - pyo3 carries abi3-py310 unconditionally, so one build covers every interpreter (as build-lancedb.yml does)

Testing

  • Same suite as upstream's make test (no marker filtering), with pytest-xdist's auto workers
  • ml_dtypes has no riscv64 wheel and builds from its (pure C++) sdist instead

License: OK

Patches

  • 0001-lance-linalg-add-a-portable-riscv64-simd-fallback.patch - To upstream. Adds a portable fallback for SIMD types that only compile on x86_64/aarch64/loongarch64; reproduces on riscv64 only.

Built on cp312; TBD passed, TBD skipped.

pylance is lance's own Python binding (python/ subdir of lancedb/lance,
maturin/PyO3-based). Ships one cp310-abi3 wheel per upstream's own CI
matrix, built here on cp312. lance-linalg's f32/f64/i32 SIMD types
compile only for x86_64/aarch64/loongarch64 upstream (unlike u8, which
already has a portable fallback); patches/pylance/11.0.0/0001*.patch
adds the same shape of fallback, verified against an isolated copy of
the module with cargo check for riscv64gc-unknown-linux-gnu plus
aarch64/x86_64 regressions.
The test asserts LANCE_LOG_FILE under an unwritable parent directory
never gets created, expecting a permission failure to fall back to
stderr logging. The cibuildwheel test phase runs as root in the
manylinux container, and root can create arbitrary paths, so the
assertion never held here (gotcha 39/83: this is a root-vs-container
quirk, not riscv64-specific).
@luhenry
luhenry merged commit b6db015 into main Sep 11, 2026
6 checks passed
@luhenry
luhenry deleted the pylance branch September 11, 2026 14:00
@luhenry luhenry linked an issue Sep 11, 2026 that may be closed by this pull request
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.

pylance riscv64 support

1 participant