Skip to content

ci: migrate 3 maturin workflows to needs.setup.outputs.matrix (maturin batch 1/3) - #4931

Open
luhenry wants to merge 3 commits into
mainfrom
fix/matrix-maturin-1
Open

luhenry wants to merge 3 commits into
mainfrom
fix/matrix-maturin-1

Conversation

@luhenry

@luhenry luhenry commented Nov 18, 2026 •

Copy link
Copy Markdown
Member

Converts build_wheels' strategy.matrix in three maturin/PyO3 workflows from a hardcoded python:/libc: list to include: ${{ fromJSON(needs.setup.outputs.matrix) }}, matching the pattern already used by ~40 other maturin workflows (e.g. build-blasthttp.yml, build-python-flirt.yml).

blastdns - dropped the hardcoded python: [cp39..cp314t] plus its include:-based per-interpreter test (full/smoke/none) mapping. matrix.python/matrix.platform now come straight from the generated matrix; job/artifact names use matrix.platform instead of a literal manylinux_riscv64. The old test mapping is now a BLASTDNS_TEST env var computed from matrix.python (endsWith(matrix.python, 't') -> none, cp310-cp314 -> full, else smoke), preserving the exact existing split while generalizing to any future interpreter the same way the comments already justify (registry gap for non-cp310-314, hard orjson free-threaded incompatibility for any *t). Verified the manylinux combinations an uv run ci_scripts/pending_versions.py --python-matrix blastdns (with the default cp39 exclude) now produces exactly match the old hardcoded cp310-cp314t list. Two real deltas, not mismatches: (1) version 2.0.2 now also builds cp315/cp315t (docs/packages/blastdns.yaml already declares them, the old hardcoded list predates them); (2) the matrix also carries musllinux rows for every version, since docs/packages/blastdns.yaml declares a :musllinux target for every interpreter - the build step itself is unchanged (still glibc-only via maturin-action's manylinux: '2_39'), so those rows build and are named identically to the already-merged build-blasthttp.yml's musllinux rows. This is a pre-existing repo-wide gap (no musl target wiring), not something this PR introduces or fixes.

cedarpy - dropped the hardcoded python: [cp39..cp314t] plus the per-version exclude: (cp39 on 4.12.0/4.12.1/4.12.2). docs/packages/cedarpy.yaml has no musllinux entries at all, so matrix.platform is always manylinux; used it anyway for job/artifact naming (matches the build-python-flirt.yml precedent, which has the same all-manylinux shape). No python-exclude: addition needed: those three versions' YAML entries never declare a cp39 target, so the generated matrix already omits it exactly as the old exclude: did. Verified combinations match.

chompjs - this one is cibuildwheel-based (not maturin-action), already had a real python x libc matrix plus an include:-based orjson flag keyed on (python, libc). Mapped matrix.libc -> matrix.platform everywhere (only:, job name, artifact name) and replaced the orjson include with an inline condition (matrix.platform == 'manylinux' && python in {cp312,cp313,cp314}) in both CIBW_TEST_REQUIRES and CIBW_TEST_COMMAND. Added python-exclude: 'cp39 cp310 cp311' to the setup: job: the old hardcoded list started at cp312, but docs/packages/chompjs.yaml still declares cp39/cp310/cp311 targets, so without this exclude those three interpreters would start building for the first time. Verified --python-matrix --python-exclude 'cp39 cp310 cp311' produces exactly the old cp312/cp313/cp314/cp314t x manylinux/musllinux cross product (8 entries).

No docs/packages/*.yaml, .queue.yml or skills/ changes.

Replace the hardcoded python list (and its include-based per-interpreter
test-level mapping) in build_wheels' strategy.matrix with
include: fromJSON(needs.setup.outputs.matrix), and source matrix.platform
for job/artifact naming instead of a literal "manylinux_riscv64".

The per-interpreter test level (full/smoke/none) that used to come from a
matrix include is now computed once as a BLASTDNS_TEST env var from
matrix.python, preserving the exact cp39/cp310-cp314/cp314t split.
Replace the hardcoded python list and version-keyed exclude (cp39 for
4.12.0/4.12.1/4.12.2) in build_wheels' strategy.matrix with
include: fromJSON(needs.setup.outputs.matrix); the exclude is now implicit
since those versions' docs/packages/cedarpy.yaml entries never declare a
cp39 target. Source matrix.platform for job/artifact naming (always
"manylinux" today, matching docs/packages/cedarpy.yaml, which declares no
musllinux target).
Replace the hardcoded python/libc cross product (and the orjson include
keyed on both) in build_wheels' strategy.matrix with
include: fromJSON(needs.setup.outputs.matrix), mapping matrix.libc ->
matrix.platform throughout (only:, CIBW_TEST_REQUIRES/CIBW_TEST_COMMAND
inline conditions, job name, artifact name).

Add python-exclude: 'cp39 cp310 cp311' to the setup job to preserve the
prior restriction: the hardcoded list only ever started at cp312, even
though docs/packages/chompjs.yaml still declares cp39-cp311 targets.

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