-
Notifications
You must be signed in to change notification settings - Fork 760
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 --target
support to sync
and install
#3257
Conversation
50b2848
to
6b3c5c3
Compare
866474e
to
30861d0
Compare
30861d0
to
c3b304d
Compare
This is different than pip right? Want to note this in the compatibility doc? |
Hmm, I don't think the user experience actually differs from pip in significant ways, or at least in ways that would work in pip but wouldn't work in uv. |
Hmm, I tried this out: $ cargo run --release --bin uv -- pip install importlib_metadata --target tmpdir
$ ls
bin/ importlib_metadata-7.1.0.dist-info/ zipp/
importlib_metadata/ include/ zipp-3.18.1.dist-info/ This looks close to what I'd expect, though the At least for the use case of building zipapps, which is what I use |
Yeah, but if you |
Yes, but pip adds all of these, as far as I can tell? It just adds them to the top-level. If you |
I understand that you don't need these things for a zipapp. What I'm trying to understand is why it's a problem to include them, if it matches pip's behavior. |
I think it's just surprising that these were here; I've not bundled a library with scripts or headers in a zipapp before so have never seen them and didn't know pip would stick them there. |
Perhaps I can change it to create those directories lazily so it's less surprising (since they typically would not be created at all in that case). |
Okay, #3274 should give you something closer to what you're used to :) |
Nice, that feels a lot more pip-like. :) |
## Summary Based on feedback in #3257 (comment).
Works great! Thank you. |
Just tried it out... With (I'm getting this error:)
|
Mmm, I could see arguments either way given our stance on environments, but probably shouldn't be required, no. You can run with |
You can use --python and pass thr path to the interpreter, it works great
even with embedded versions of python with no venv
…On Sat, Apr 27, 2024, 6:42 p.m. Charlie Marsh ***@***.***> wrote:
Mmm, I could see arguments either way given our stance on environments,
but probably shouldn't be required, no. You can run with --system in the
meantime.
—
Reply to this email directly, view it on GitHub
<#3257 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAIXWF6KKNYFQXXREELY5CLY7QSVPAVCNFSM6AAAAABGX3QPZOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAOBRGIZDAMZQGM>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Success story: Our package install time went from 4m27s to 0m8s! |
Summary
The approach taken here is to model
--target
as an install scheme in which all the directories are just subdirectories of the--target
. From there, everything else... just works? Like, upgrade, uninstalls, editables, etc. all "just work".Closes #1517.