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 fails to start because of jemalloc #4647

Closed
adminy opened this issue Jun 29, 2024 · 5 comments
Closed

uv fails to start because of jemalloc #4647

adminy opened this issue Jun 29, 2024 · 5 comments

Comments

@adminy
Copy link

adminy commented Jun 29, 2024

<jemalloc>: Unsupported system page size
<jemalloc>: Unsupported system page size
memory allocation of 5 bytes failed
[1]    22202 abort (core dumped)  uv

A minimal code snippet that reproduces the bug.

uv venv or any uv command.

The current uv platform.

NixOS derivation running on raspberry Pi latest kernel with the aarch64 target.

The current uv version (uv --version).

0.2.15 ( I think, not sure because of the error)

@zanieb
Copy link
Member

zanieb commented Jun 29, 2024

Looks like jemalloc is not supported on that operating system e.g. home-assistant/core#105768

Home-assistant provides a DISABLE_JEMALLOC option to work-around this, we might need to do similar?

It looks like they also changed the page size (i.e. JEMALLOC_SYS_WITH_LG_PAGE) which may solve the issue? home-assistant/docker-base#248 and more discussion at qdrant/qdrant#3945 (comment)

@konstin
Copy link
Member

konstin commented Jul 1, 2024

This is the same problem as we had in astral-sh/ruff#3791, we can try the same mitigation (JEMALLOC_SYS_WITH_LG_PAGE=16 during build)

@konstin konstin added the bug Something isn't working label Jul 1, 2024
@charliermarsh
Copy link
Member

I believe we have that same mitigation in our build already @konstin.

@konstin
Copy link
Member

konstin commented Jul 1, 2024

This looks like a bug in the nixos derivation then, which doesn't set JEMALLOC_SYS_WITH_LG_PAGE=16 for the aarch64 target.

@adminy can you confirm that uv works with the official package (either from github or pypi)?

@konstin konstin removed the bug Something isn't working label Jul 9, 2024
@zanieb
Copy link
Member

zanieb commented Aug 26, 2024

I'm going to close this as stale. #6528 tracks this issue for our own binaries.

@zanieb zanieb closed this as completed Aug 26, 2024
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

No branches or pull requests

4 participants