-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Inconsistent Dependency Handling Across Systems with Different glibc
Versions
#11120
Comments
I don't think this is a uv problem, this is just the reality of using packages installed in one context in another context. Paramiko (edit: or, as Charlie subsequently pointed out, a dependency of it) chooses to build wheels that dynamically link libc, so a compatible version of libc needs to be around at runtime. |
(Thanks for the clear reproduction steps though!) |
Hmm... Like, you're accessing the exact same virtual environment? You need different wheels when running against different glibc versions -- that virtual environment isn't seamlessly compatible across platforms. Notice that cryptography publishes wheels for 2.17 and 2.28: https://pypi.org/project/cryptography/#files. uv doesn't introspect which wheel is already-installed when you execute |
@zanieb I think the error is actually in cryptography. |
If you install on the older Ubuntu, it should work on the newer one. Alternatively, you could request a specific
where But this is only available in the lower-level |
We can think about how to handle this case better though, agree that user-experience is not ideal. |
Yes, I tried to generalize the use case. If I'm installing it on the older Ubuntu it works fine on the newer one. (this is actually what we are doing now). The use case is that we have stronger computers with newer OS to develop on, and we have many "old" computers which acts as controllers for some embedded HW. My CI job is starts on the "strong" PC and distribute the jobs to the "old" PCs. |
Yeah, I think you should be able to specify your minimum-supported glibc version somehow. That would at least solve this case (though wouldn't solve the general case of, like, the platform changing from under us). |
I don't know if it's better to let Maybe a better approach would be to handle it like the existing interface in |
Yeah there are basically two options:
(2) would be automatic, but it would also mean that if you're sharing the environment across two incompatible machines in real-time, things would break down. |
Exactly, this is why I prefer (1), this way I can create the environment with the desire minimum |
Summary
When using UV to create environments on systems with different
glibc
versions (e.g., Ubuntu 22.04 and Ubuntu 18.04), packages that depend onglibc
(likeparamiko
) do not handle the version difference gracefully.In setups where environments are shared across multiple systems via NFS, an environment created on Ubuntu 22.04 functions correctly on the same OS. However, when accessed from Ubuntu 18.04 (which has a lower
glibc
version), it leads to runtime errors due to incompatible shared library dependencies. The necessary dependencies are not reinstalled or resolved during environment execution.Steps to reproduce:
Platform
Ubuntu18.04, Ubuntu22.04
Version
uv 0.5.25
Python version
Python 3.9.20
The text was updated successfully, but these errors were encountered: