Skip to content

moyopy: add build-moyopy.yml for riscv64 wheels - #1062

Open
luhenry wants to merge 6 commits into
mainfrom
moyopy
Open

moyopy: add build-moyopy.yml for riscv64 wheels#1062
luhenry wants to merge 6 commits into
mainfrom
moyopy

Conversation

@luhenry

@luhenry luhenry commented Sep 6, 2026

Copy link
Copy Markdown
Member

Compiles moyo's Rust crystal-symmetry library into the moyopy PyO3 extension module. Upstream publishes no riscv64 wheel.

Mirrors upstream's rw-python-release.yaml.

Differs from upstream

  • cibuildwheel replaces PyO3/maturin-action - this repo's standard riscv64 build path
  • LICENSE-APACHE/LICENSE-MIT staged into moyopy/ before build - maturin globs licences relative to pyproject.toml's directory and upstream ships none

Matrix: cp310-abi3 (pyo3's abi3-py310 floor) + cp314t; no cp313t (cibuildwheel ships no such build identifier)

Testing

  • same as upstream, minus prek (lint-only, unused by pytest)
  • test-sources stages only python/tests, not the sibling python/moyopy source package, so the installed wheel isn't shadowed

License: OK

Builds moyo's Rust crystal-symmetry library into the moyopy PyO3
extension via cibuildwheel + maturin, mirroring upstream's
rw-python-release.yaml narrowed to the riscv64 image.
pymatgen hard-requires orjson, and orjson's build script refuses to
compile under a free-threaded interpreter. Narrow test coverage for
that one identifier instead of dropping the build.
pymatgen (test-requires, sdist-only on riscv64) pulls in scipy/numpy/pandas/
orjson as runtime deps; without PIP_ONLY_BINARY pip resolved PyPI's newer
sdist-only releases over our registry's riscv64 wheels and tried to compile
scipy from source, failing on missing OpenBLAS.
…ed deps

pillow (pulled in via matplotlib) surfaced the same only-binary gap gotcha
291 fixed for numpy/scipy/pandas/orjson: pip reached past our registry's
riscv64 wheel to a newer PyPI sdist-only pillow release and failed to
compile it (missing libjpeg headers). Checked pymatgen-core's declared
deps for the rest of the same class: matplotlib, contourpy, and kiwisolver
(all dragged in by matplotlib) and spglib (a direct dep) all lack a
riscv64 wheel on public PyPI's newest release but have one on ours, so
add all five in one pass.
build-spglib.yml's own matrix only builds cp312+ riscv64 wheels, so
forcing spglib wheel-only starved cp310/cp311 test venvs of any
candidate at all. pip's resolver responded by backtracking through
pymatgen's entire release history looking for one old enough to not
depend on spglib, and crashed 85 minutes later on pymatgen 4.4.11's
ancient numpy-distutils setup.py -- a red herring unrelated to which
numpy version pip resolved.

spglib's registry version doesn't lag PyPI's today, so leaving it
unpinned still prefers our wheel where one exists (cp312+) and falls
back to building the sdist where it doesn't (cp310/cp311); spglib's
build-time tools (cmake/ninja) ship interpreter-agnostic py3-none
wheels on the registry already, and build-spglib.yml needs no
before-build step, so the same toolchain an sdist build invokes is
already proven on this image.
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