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

UV binary not working on raspberry pi 5 #10942

Open
nhumrich opened this issue Jan 24, 2025 · 5 comments
Open

UV binary not working on raspberry pi 5 #10942

nhumrich opened this issue Jan 24, 2025 · 5 comments
Labels
bug Something isn't working releases Related to building and distributing release artifacts of uv

Comments

@nhumrich
Copy link

Summary

Apologies if this is a duplicate. I found two potential duplicates, but they were closed a while ago, and this issue is recent.

Possible duplicates: #4647 #6528

When building a docker image with UV on a raspberry pi 5, uv crashes. The error is:

0.081 <jemalloc>: Unsupported system page size
0.081 <jemalloc>: Unsupported system page size
0.081 memory allocation of 96 bytes failed
0.084 Aborted (core dumped)

This issue is new, as I have my automated builds run on a raspberry pi. I haven't changed my dockerfile, and my last successful build was on Dec 5. So the bug appears to be introduced after Dec 5.

I have tried updating the raspberry pi 5 packages and that doesn't solve anything.

Unfortunately, you might need a RPi5 to reproduce the issue. However, if you have one, you can reproduce by running docker build on this Dockerfile:

FROM python:3.12-slim

RUN --mount=from=ghcr.io/astral-sh/uv,source=/uv,target=/bin/uv \
    uv pip install pandas

I am unsure of the UV version, as it crashes and won't run, not even to show version. But the sha of the docker image its being mounted from is:
sha256:2381d6aa60c326b71fd40023f921a0a3b8f91b14d5db6b90402e65a635053709

If the uv version is the same as on a non-arm machine pulling, then its 0.5.24

Platform

raspberry pi 5

Version

0.5.24

Python version

3.12.8

@nhumrich nhumrich added the bug Something isn't working label Jan 24, 2025
@zanieb
Copy link
Member

zanieb commented Jan 24, 2025

Just to confirm, that SHA is for the latest ARM image

❯ docker run --platform linux/arm64 -it ghcr.io/astral-sh/uv
Unable to find image 'ghcr.io/astral-sh/uv:latest' locally
latest: Pulling from astral-sh/uv
dfc710471e71: Pull complete 
e567a4ebf4fe: Pull complete 
Digest: sha256:2381d6aa60c326b71fd40023f921a0a3b8f91b14d5db6b90402e65a635053709
Status: Downloaded newer image for ghcr.io/astral-sh/uv:latest
uv 0.5.24

@zanieb zanieb added the releases Related to building and distributing release artifacts of uv label Jan 24, 2025
@zanieb
Copy link
Member

zanieb commented Jan 24, 2025

I don't think we set JEMALLOC_SYS_WITH_LG_PAGE=16 in the Docker build.

Can you check if installing from the GitHub Release works instead?

@zanieb
Copy link
Member

zanieb commented Jan 24, 2025

Similarly, it'd be helpful if you tested #10943

@nhumrich
Copy link
Author

Modified the dockerfile to look like this


RUN apt update && apt install curl -y
RUN curl --proto '=https' --tlsv1.2 -LsSf https://github.com/astral-sh/uv/releases/download/0.5.24/uv-installer.sh | sh
RUN ~/.local/bin/uv version

And doing that, it DOES in fact work fine.

@zanieb
Copy link
Member

zanieb commented Jan 24, 2025

Cool thanks!

Surprised our Docker image ever worked on your machine then, tbh — something else must have changed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working releases Related to building and distributing release artifacts of uv
Projects
None yet
Development

No branches or pull requests

2 participants