Skip to content

Enable native wheel builds and testing on Power and Z#15844

Open
jakelishman wants to merge 11 commits intoQiskit:mainfrom
jakelishman:native-power-z
Open

Enable native wheel builds and testing on Power and Z#15844
jakelishman wants to merge 11 commits intoQiskit:mainfrom
jakelishman:native-power-z

Conversation

@jakelishman
Copy link
Copy Markdown
Member

We have recently been granted access to IBM-hosted images for ppc64le and s390x. We should be able to not only avoid the QEMU emulation during the wheel builds now (although strictly we could already have been cross-compiling, since we moved to Rust), but also to run the test suite on the new images.

Summary

Details and comments

See also:

@jakelishman jakelishman requested a review from a team as a code owner March 20, 2026 17:36
@jakelishman jakelishman added the ci: test wheels Run the wheel-build scripts as an additional CI run for this PR label Mar 20, 2026
@qiskit-bot
Copy link
Copy Markdown
Collaborator

One or more of the following people are relevant to this code:

  • @Qiskit/terra-core

We have recently been granted access to IBM-hosted images for ppc64le
and s390x.  We should be able to not only avoid the QEMU emulation
during the wheel builds now (although strictly we could already have
been cross-compiling, since we moved to Rust), but also to run the test
suite on the new images.
@IvanIsCoding
Copy link
Copy Markdown
Contributor

So I still need to tweak the runners for the rustworkx release, but with regards to Python: in Qiskit/rustworkx#1568, my most successful attempt at getting a custom version of Python installed was with https://github.com/astral-sh/setup-uv.

Astral published a standalone Python for ppc64 and s390x, which was quite handy

@jakelishman
Copy link
Copy Markdown
Member Author

Ah, thanks Ivan - that'll probably massively cut down my iteration time. I haven't had time to look at this properly yet (not sure when I will), so I'd basically just been making random changes to the Python setup and hoping haha

@jakelishman
Copy link
Copy Markdown
Member Author

jakelishman commented Mar 24, 2026

Ok, I think an important point here from doing a little spelunking is that the pypa/cibuildwheel action unilaterally calls actions/setup-python, and that's the immediate problem here. I either have to trick setup-python or swap away from using the GitHub Action for cibuildwheel.

edit: or propose an override mechanism to cibuildwheel, I guess.

@IvanIsCoding
Copy link
Copy Markdown
Contributor

Ok, I think an important point here from doing a little spelunking is that the pypa/cibuildwheel action unilaterally calls actions/setup-python, and that's the immediate problem here. I either have to trick setup-python or swap away from using the GitHub Action for cibuildwheel.

edit: or propose an override mechanism to cibuildwheel, I guess.

In my experience, uv run cibuildwheel seems to work. I will try to dig the workflow that worked, but uv can invoke the tool and then civuildwheel spans Docker

@IvanIsCoding
Copy link
Copy Markdown
Contributor

Indeed: https://github.com/IvanIsCoding/celq/blob/8778fa6cec4e3b8a49a158a48dca13ff800e9185/.github/workflows/release_pypi.yml#L68

uvx cibuildwheel worked nicely for my personal project. I eventually subbed it for Zigbuild but that is another topic

@jakelishman
Copy link
Copy Markdown
Member Author

uv run isn't dissimilar to making a venv and running the binary from there, but I would like to avoid introducing uv to Qiskit's CI where possible, especially with the future a bit less certain after Astral's acquisition by OpenAI.

Now that I found the problem, actually getting cibuildwheel to run is easy enough. The next step is figuring out a story for us for scipy on s390xX. It might build, but I'm asking around about the pre-built story here. NumPy is easier, if we have to build from source, though I'd like to avoid that if I can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci: test wheels Run the wheel-build scripts as an additional CI run for this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants