Skip to content

ci: migrate 6 workflows (with per-leg overrides) to needs.setup.outputs.matrix (extra-include batch 2/4) - #4928

Open
luhenry wants to merge 1 commit into
mainfrom
fix/matrix-extra-2
Open

luhenry wants to merge 1 commit into
mainfrom
fix/matrix-extra-2

Conversation

@luhenry

@luhenry luhenry commented Nov 18, 2026 •

Copy link
Copy Markdown
Member

Part of the repo-wide migration to needs.setup.outputs.matrix (same bug class as #4914/#4915: stale hardcoded python:/libc: matrix lists). This batch covers the 6 files whose build_wheels job layers a per-python or per-libc include: override on top of the hardcoded list, so each override had to be converted into an inline ternary expression at its point of use rather than just swapped for fromJSON(needs.setup.outputs.matrix).

Packages touched and how each override was preserved

  • fastparquet — include: [{python: cp314t, test_skip: '*'}] → CIBW_TEST_SKIP: ${{ matrix.python == 'cp314t' && '*' || '' }}.
  • geventhttpclient — same cp314t -> test_skip shape, same ternary.
  • gmpy2 — same cp314t -> test_skip shape, same ternary.
  • gseapy — same cp314t -> test_skip shape, same ternary.
  • hierarchicalforecast — three separate overrides, all converted in place:
    • cp312/cp313 -> test_requires: statsforecast → CIBW_TEST_REQUIRES: ... ${{ contains(fromJSON('["cp312","cp313"]'), matrix.python) && 'statsforecast' || '' }}
    • cp314 -> pytest_args: --ignore=... → inlined into CIBW_TEST_COMMAND's tail: ${{ matrix.python == 'cp314' && '--ignore=tests/test_evaluation.py --ignore=tests/test_utils.py' || '' }}
    • cp314t -> test_skip: '*' → CIBW_TEST_SKIP ternary, same as the others.
  • freeze-core — two jobs:
    • build_wheels had libc: [manylinux, musllinux] (no override) — renamed every ${{ matrix.libc }} to ${{ matrix.platform }} (job name, CIBW_BUILD, artifact name); both platforms still build exactly as before.
    • test_wheels had include: [{python: cpNNN, python-version: 'N.NN'}, ...] — this mapping is already what needs.setup.outputs.matrix carries natively, so the override block was dropped outright rather than converted to a ternary.

Platform filtering

Every one of these build_wheels jobs (except freeze-core's, which genuinely builds both) hardcodes a manylinux-only cibuildwheel only: (fastparquet, gmpy2, gseapy, hierarchicalforecast) or CIBW_BUILD (geventhttpclient). needs.setup.outputs.matrix now also emits musllinux rows wherever docs/packages/<pkg>.yaml declares musllinux files: entries (even unfilled/pending ones) — fastparquet, geventhttpclient and gmpy2 all do. Without a filter, those musllinux matrix rows would silently re-run the same hardcoded-manylinux build and then collide on the upload-artifact name with the manylinux row from the same run. Added matrix.platform == 'manylinux' to each affected job's if: (fastparquet, geventhttpclient, gmpy2, freeze-core's test_wheels, and defensively on gseapy/hierarchicalforecast even though their yaml currently has no musllinux entries at all).

python-exclude additions

All six previously hardcoded python: ["cp312","cp313","cp314","cp314t"] — narrower than needs.setup.outputs.matrix would otherwise produce from each package's yaml. Added to each setup: job's with: to preserve that exact coverage:

  • fastparquet, gseapy, hierarchicalforecast: python-exclude: 'cp39 cp310 cp311'
  • geventhttpclient, gmpy2: python-exclude: 'cp39 cp310 cp311 cp315*'
  • freeze-core: python-exclude: 'cp39 cp311 cp315*'

Mismatch found

hierarchicalforecast: the old hardcoded list included a cp314t leg (with test_skip: '*', i.e. it built but never tested it), but docs/packages/hierarchicalforecast.yaml has never declared a 3.14t file entry for this package at all — so that leg was building an untracked, unpublishable wheel for no reason. Confirmed via uv run --quiet ci_scripts/pending_versions.py --python-matrix --python-exclude 'cp39 cp310 cp311' --glob '*' hierarchicalforecast, whose output tops out at cp314. This is the same stale-matrix bug class as #4914/#4915; the structural fix here resolves it on its own, since cp314t simply never appears in needs.setup.outputs.matrix for this package.

Every other package's python x platform set, after the python-exclude additions above, reproduces the old hardcoded set exactly (verified the same way, per package).

Scope

.github/workflows/* only — no docs/packages/*.yaml, .queue.yml, or skills/ changes.

…ts.matrix

Replace the hardcoded python/libc matrix in build_wheels (and freeze-core's
test_wheels) with needs.setup.outputs.matrix for fastparquet, freeze-core,
geventhttpclient, gmpy2, gseapy and hierarchicalforecast, converting each
file's extra include: override into an inline matrix-field ternary at its
point of use:

- fastparquet, geventhttpclient, gmpy2, gseapy: cp314t -> CIBW_TEST_SKIP: '*'
- hierarchicalforecast: cp312/cp313 -> CIBW_TEST_REQUIRES statsforecast,
  cp314 -> CIBW_TEST_COMMAND --ignore flags, cp314t -> CIBW_TEST_SKIP: '*'
- freeze-core test_wheels: the python -> python-version include block is
  dropped outright, since needs.setup.outputs.matrix already carries
  python-version

matrix.libc is renamed to matrix.platform throughout freeze-core (the only
one of the six with a libc axis); its build_wheels job already builds both
platforms from matrix.platform, unchanged.

Every build_wheels job here hardcodes a manylinux-only cibuildwheel `only:`
(or, for freeze-core, iterates both platforms already), so a job-level
`matrix.platform == 'manylinux'` filter is added wherever the package's
docs/packages/<pkg>.yaml carries musllinux file entries, to stop musllinux
matrix rows from silently re-running (and artifact-colliding with) the same
manylinux-only build. freeze-core's test_wheels gets the same filter, since
it only ever exercised the manylinux wheel.

python-exclude is added to each setup job to preserve the prior workflow's
narrower python coverage (all six previously built only cp312-cp314t):
- fastparquet, gseapy, hierarchicalforecast: 'cp39 cp310 cp311'
- geventhttpclient, gmpy2: 'cp39 cp310 cp311 cp315*'
- freeze-core: 'cp39 cp311 cp315*'

Verified against `ci_scripts/pending_versions.py --python-matrix` for each
package: with the exclude lists above, every one now reproduces exactly the
old hardcoded python x platform set, except hierarchicalforecast, whose old
list also carried a cp314t leg that docs/packages/hierarchicalforecast.yaml
has never declared a 3.14t file entry for -- a pre-existing stale-matrix
mismatch (same class as #4914/#4915) that this structural change resolves
by simply dropping the dead leg.

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