uv
uv copied to clipboard
uv ignores packages installed in lib64/
On Fedora 39 (and presumably some other distros), Python packages can be installed in two directories, lib/ and lib64. E.g. system packages can be both in:
- /usr/lib/python3.12/site-packages
- /usr/lib64/python3.12/site-packages
The same applies for venvs, including venvs managed by uv.
It seems that the location is determined by the presence of C-extensions: pure python packages go to lib, while those containing native code go to platform-specific directory in lib64. See https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_mandatory_macros
uv pip install handles the installation correctly, e.g.
$ uv venv --seed
$ uv pip install numpy
Resolved 4 packages in 25ms
Installed 4 packages in 13ms
+ annotated-types==0.6.0
+ pydantic==2.6.4
+ pydantic-core==2.16.3
+ typing-extensions==4.10.0
This will install pydantic_core into .venv/lib64/python3.12/site-packages/ and the rest into .venv/lib/python3.12/site-packages/
However, running uv pip list omits pydantic-core
$ uv pip list
Package Version
----------------- -------
annotated-types 0.6.0
pip 24.0
pydantic 2.6.4
typing-extensions 4.10.0
Similarly, uv pip show pydantic-core does not find the package, and
$ uv pip check
Checked 4 packages in 0.57ms
Found 1 incompatibility
The package `pydantic` requires `pydantic-core ==2.16.3`, but it's not installed.
The equivalent pip commands all work as expected.
uv version: 0.1.22