Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

manylinux support is missing for riscv64 #8889

Closed
markdryan opened this issue Nov 7, 2024 · 2 comments · Fixed by #8934
Closed

manylinux support is missing for riscv64 #8889

markdryan opened this issue Nov 7, 2024 · 2 comments · Fixed by #8934
Labels
bug Something isn't working

Comments

@markdryan
Copy link
Contributor

It's not currently possible to install riscv64 manylinux wheels using uv. If I try locally with the command

$ uv pip install PyYAML-6.0.2-cp311-cp311-manylinux_2_35_riscv64.whl 
Using Python 3.11.4 environment at /home/HOME/uv-venv
Resolved 1 package in 156ms
error: Failed to determine installation plan
  Caused by: A path dependency is incompatible with the current platform: PyYAML-6.0.2-cp311-cp311-manylinux_2_35_riscv64.whl

I get the error shown. Although the manylinux container images do not yet support riscv64, auditwheel does, so it is possible to create manylinux wheels for riscv64. These wheels can be installed by pip, but not by uv.

According to the auditwheel policy file for manylinux, the oldest version of manylinux that supports riscv64 is 2.31. Locally, I have tried modifying get_minimum_manylinux_minor so that it returns 31 for riscv64. Doing so allows the command shown above to work correctly, e.g.,

$ uv pip install PyYAML-6.0.2-cp311-cp311-manylinux_2_35_riscv64.whl 
Using Python 3.11.4 environment at /home/HOME/uv-venv
Resolved 1 package in 165ms
Prepared 1 package in 174ms
Uninstalled 1 package in 14ms
Installed 1 package in 37ms
 - pyyaml==6.0.2
 + pyyaml==6.0.2 (from file:///home/HOME/PyYAML-6.0.2-cp311-cp311-manylinux_2_35_riscv64.whl)

I'd like to submit this small change to uv to enable it to install manylinux wheels on riscv64. Would such a patch be acceptable?

Note, that RISE is currently building and distributing a small set of riscv64 binary wheels on its gitlab. The majority of these wheels are manylinux_2_35 wheels and they cannot currently be installed by uv. They can however, be installed using pip >=24.1.

@konstin konstin added the bug Something isn't working label Nov 7, 2024
@konstin
Copy link
Member

konstin commented Nov 7, 2024

A PR to add risc64 manylinux support would be great!

It's totally not a requirement for the PR, but if you happen to have instructions how to test riscv things on an x86_64 or aarch64 machine, this helps the team to reproduce and debug riscv-specific problems (i've for example used qemu docker for other architectures before).

markdryan added a commit to markdryan/uv that referenced this issue Nov 8, 2024
auditwheel is capable of generating riscv64 wheels for manylinux_2_31
and above.  Here we modify uv-platform-tags so that those wheels can
be installed using uv.

Fixes: astral-sh#8889
markdryan added a commit to markdryan/uv that referenced this issue Nov 8, 2024
auditwheel is capable of generating riscv64 wheels for manylinux_2_31
and above.  Here we modify uv-platform-tags so that those wheels can
be installed using uv.

Fixes: astral-sh#8889
@markdryan
Copy link
Contributor Author

's totally not a requirement for the PR, but if you happen to have instructions how to test riscv things on an x86_64 or aarch64 machine, this helps the team to reproduce and debug riscv-specific problems (i've for example used qemu docker for other architectures before).

I used a combination of a riscv64 container image running on an amd64 host to build the uv wheel which I then tested on a riscv64 VM running Ubuntu 23.10. The riscv64 wheels distributed by RISE are also built and tested inside riscv64 container images running on an amd64 host.

A few observations. I did try and run the uv tests in the riscv64 container image but I got a fair few failures (with and without the manylinux patch). Some of these were timeouts and some seemed to be caused by missing riscv64 packages at PyPi. The build of the wheel itself probably took about an hour with maturin.

I did try originally building and testing on a VisionFive2 (a riscv64 SBC) running Ubuntu 24.04 but the build was killed after about an hour due to an OOM error. My VisionFive2 only has 8GB of RAM.

markdryan added a commit to markdryan/uv that referenced this issue Nov 8, 2024
auditwheel is capable of generating riscv64 wheels for manylinux_2_31
and above.  Here we modify uv-platform-tags so that those wheels can
be installed using uv.

Fixes: astral-sh#8889
@konstin konstin closed this as completed in a11d27b Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants