cnpryer / huak

My experimental Python package manager.
https://cnpryer.github.io/huak/
MIT License
615 stars 37 forks source link

Add compatibility for poetry pyproject.toml structure and lock file #654

Open orgroman opened 1 year ago

orgroman commented 1 year ago

Description

I think one of the most challenging things about taking a new tool such as the one developed here is that it always comes with a new format (Cargo.toml for python) that we need to support.

I think poetry is extremely slow and a new tool in rust Is definitely a good alternative. But, I prefer not to break compatibility with existing tools unless there's a very good reason to do so.

It seems like the poetry pyproject.toml structure is very similar to the Cargo.toml and poetry is already popular... Why not support installing directly from poetry files and exporting lock files same command compatibility? Is there a good reason to introduce a new file structure?

cnpryer commented 1 year ago

Hi!poetry currently has a proprietary configuration it uses based on a modified PEP 621. pyproject.toml is a new spec that the ecosystem is moving towards. I personally would like to support one spec, but it's possible to support files like setup.py and setup.cfg.

We can also offer a migrate command eventually which is what hatch and pdm provide. rye will likely end up doing something similar, although it'll probably be more like an import to start.

cnpryer commented 1 year ago

A lockfile is another topic, which separately is in scope for huak.