-
Notifications
You must be signed in to change notification settings - Fork 339
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
Add support for latest uv project management features #1405
Comments
Maybe we should enable it if |
Since last uv's update, there are nearly no reason to have both poetry and uv I think, as uv aims at being a complete alternative to poetry-like tools, so if you have uv = {
enabled = true;
use_pyproject = true;
}; |
Alright then let's make sure |
I've started hacking around on a PR for this and from what I can tell this is blocked on To be honest, while looking at the source, this could use a fair bit of refactoring. Before I just dive in, is there a good place to discus what the actual behavior should be for the python language given the messiness of the ecosystem? |
My proposal: There's some useful bits which are shared across package management solutions
What would it take to make the change so that the package management configurations are mutually exclusive? Is there appetite for that, or is the current behaviour of |
i wouldn't go so far as to make them mutually exclusive in config. in monorepo setups you might have a submodule that uses a different package manager. there are a bunch of other weird possibilities, like using poetry for your main package manager but using uv to run scripts. |
Just piping in to say how much I already enjoy using devenv, and to add another voice to say this would be an awesome improvement. One question - would devenv be able to support UV managing the python installation itself? |
There's an interesting convo going on in the astral discord about dynamically linked binaries in NixOS as it relates to uv's installed binaries. From the NixOS docs: How to run non-nix executables?
Now, AFAICT this only applies to NixOS, i'm still learning about this issue/reasoning so i have no idea if it would be relevant to |
Awesome if you are preparing something @lamalex, that would be a huge improvement for python dev w/ devenv! Please let us know if you have difficulties or if you need more hands! Small question, the default |
Any WIP on this? I'm going to start digging into the code @lamalex let's throw something up if we can avoid duplicating work |
Adds an initUvScript if `uv.sync` is enabled. Calls `uv sync` to install python packages as defined in pyproject.toml fixes: cachix#1405
The current script generated to init env with uv checks for requirements.txt. However, uv now supports
uv sync
to deal with pyproject.toml, similarly to poetry. Cf https://astral.sh/blog/uv-unified-python-packagingBased on the presence of a pyproject.toml, would it be possible to replace the workflows around requirements.txt with a simple
uv sync
call?If you validate the approach, maybe I can work on a PR?
The text was updated successfully, but these errors were encountered: