Skip to content

uv python install consumes a lot of memory #10060

@jooon

Description

@jooon

While investigating #10057 and rerunning the uv python install command to get a shorter test case I noticed uv became slower and slower the more I used it. It seems to read and rewrite a _sysconfigdata__linux_x86_64-linux-gnu.py file which keeps getting bigger and bigger for every run.

$ uv --version
uv 0.5.11
$ uv python uninstall --all
Searching for Python installations
No Python installations found
$ time (for i in {1..25}; do uv python install 3.12.8; done)
Installed Python 3.12.8 in 1.06s
 + cpython-3.12.8-linux-x86_64-gnu

real	0m27.687s
user	0m17.309s
sys	0m8.580s
$ cd /home/jon/.local/share/uv/python/cpython-3.12.8-linux-x86_64-gnu/lib/python3.12/
$ du -hs _sysconfigdata__linux_x86_64-linux-gnu.py
2.3G	_sysconfigdata__linux_x86_64-linux-gnu.py

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions