-
Notifications
You must be signed in to change notification settings - Fork 413
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
Defer finding uv binary to shutil #4576
base: main
Are you sure you want to change the base?
Conversation
remove the spaces I have missed
Hi! I don't think we want this behavior - it's only the intent of the script to find the uv binary associated with the Python module not another one on the system. If people want to find any uv binary, yeah Perhaps we just need to clarify the documentation here instead. |
All good! Is there any interest in configuring
in order to target |
It'd be nice to support Nix but I don't think it makes sense for us to scan in arbitrary locations (i.e. up five levels) for the |
It does do that, by initializing the library root at The problems for this case start when Python allows package location declarations via |
Hello! Following up. Is there any interest in supporting the python library being pulled in via |
Hi! Sorry I'm not entirely understanding what you're proposing now. Can you clarify? |
Summary
Currently the
find_uv_binary
function searches some amount of pre-defined locations. Finding the binary itself can be achieved in a simpler way by deferring the logic toshutil.which
, which does the following for us for free:exe
extension logic in WindowsIn addition, leaving the location logic to
PATH
andshutil.which
has the additional advantage of being compatible with tools that expose binaries viaPATH
(ie Nix), and any other package managers that work in ways we don't expectTest Plan
No new functions -- previously written tests should cover correctness. Marked as Draft until all tests pass