Hacker News new | past | comments | ask | show | jobs | submit login

uv isn't a performance improvement on pip but a ground-up rewrite in a completely different language.



Source on the logic being different from pip?

Last I checked it's nothing more than a port of pip to rust.


I’m unclear on how you “port” a library from Python to Rust, it’s a ground up rewrite with a familiar interface to pip but fundamentally doesn’t share any code.


It's actually pretty easy to call python from rust and rust from python. An incremental port of a python library into rust would definitely be possible.

I'm not sure it would be a good idea. Python patterns don't necessarily make good rust patterns. Even ignoring larger code structure (e.g. single ownership*) you'd practically have to do a second pass to stop using python compatible types (except in the exposed interface) if you wanted an idiomatic rust library at the end of it. But it's definitely possible.

* Which you don't "have to" do in rust, you can use `Rc<RefCell>` everywhere and imitate python instead. It's just throwing some of the advantages of rust and adding some noise to type signatures.


It is not.

> Limitations

> While uv supports a large subset of the pip interface, it does not support the entire feature set. In some cases, those differences are intentional; in others, they're a result of uv's early stage of development.

> For details, see our pip compatibility guide[1]

> Like pip-compile, uv generates a platform-specific requirements.txt file (unlike, e.g., poetry and pdm, which generate platform-agnostic poetry.lock and pdm.lock files). As such, uv's requirements.txt files may not be portable across platforms and Python versions.

[1] - https://github.com/astral-sh/uv/blob/main/PIP_COMPATIBILITY....


both can be true.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: