-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Implement --user
flag and user scheme support for uv pip
#2352
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
Closed
Closed
Changes from 20 commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
a6a4b77
Initial implementation of user scheme
imfing 9c35a6a
Ensure venv scheme paths exist
imfing 62ba8c9
Merge remote-tracking branch 'upstream/main' into user-scheme
imfing 425f4f7
Fix merge issues
imfing 5cef5d8
Add include_system_site_packages to PyVenvConfiguration
imfing bbd910d
Refactor to from_user_scheme
imfing 642c987
Update pip install `--user` arg docstring
imfing 8cf2d97
Merge remote-tracking branch 'upstream/main' into user-scheme
imfing dcc7c29
Support user site in pip list
imfing 0bb5b6a
Support user site for `pip show`
imfing 7bc1895
Support user site for `pip freeze`
imfing ad97a62
Fix python arg type conversion
imfing 947f93b
Format file
imfing dea359c
Merge remote-tracking branch 'upstream/main' into pip-user-scheme
imfing 2f905e4
Update comment for pip install user arg
imfing 880da62
Add comments to _infer_user
imfing d2df185
Add include dir to ensure user scheme paths
imfing 7a9af2f
Merge remote-tracking branch 'upstream/main' into pip-user-scheme
imfing eb38890
Run cargo fmt --all
imfing 97bf336
Fix CI errors
imfing 1991f70
Update crates/uv-interpreter/src/python_environment.rs
imfing 6749fa7
Use fs_err instead of fs
imfing 67f4821
Merge remote-tracking branch 'upstream/main' into pip-user-scheme
imfing f6e9a43
Merge remote-tracking branch 'upstream/main' into pip-user-scheme
imfing 5f49ffc
Fix merge issues
imfing File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this intentionally not cache?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've noticed that
query_cached
usesthe executable's last modified time
as a cache key. In the case of user scheme, the interpreter may remain the same, e.g. the system Python interpreter, but theInterpreterInfo.scheme
changes to the user site, e.g.~/.local
.I will take a further look into using
uv_cache
to cache the script execution here.