Closed RomainBrault closed 2 weeks ago
also a @cached_property instead of @property might be relevant.
I am strongly against this. The sane behavior is to manage our version of UV; otherwise we have no idea whether what we get it compatible or not with the functionality we want to provide.
What's the problem this feature will solve?
Currently uv is installed in tox's virtualenv.
If a user have its own uv in another virutalenv, it might cause confusion and more management (e.g. updates)
Describe the solution you'd like
Follow PyPA's build implementation:
https://github.com/pypa/build/blob/main/src/build/env.py
In tox uv we could modify in https://github.com/tox-dev/tox-uv/blob/main/src/tox_uv/_venv.py:
by
Remove the toplevel import and make the dependency optional in pyproject.toml
Additional context
To me the difficult part here is the test / coverage. I don't really know how to do.
It will also require to add some documentation, e.g.
By default tox-uv doesn't ship with uv. If you don´t have uv installed on your system, you can either 1) Let tox-uv managed uv with
pip install tox-uv[uv
2) Install uvThe drawback I'm seeing is that it might break systems where people didn't have uv install as a global tool and used only uv through tox-uv.
Alternative Solutions
Do not make the uv dependency optional but prioritize system uv over tox-uv's uv.