Skip to content
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

uv toolchain uninstall should either error or remove all Pythons #4816

Closed
charliermarsh opened this issue Jul 4, 2024 · 6 comments · Fixed by #4820
Closed

uv toolchain uninstall should either error or remove all Pythons #4816

charliermarsh opened this issue Jul 4, 2024 · 6 comments · Fixed by #4820
Assignees
Labels
cli Related to the command line interface preview Experimental behavior

Comments

@charliermarsh
Copy link
Member

Right now, it looks like it passes an empty request vector to the command.

Further down, there's a match against matches!(requests.as_slice(), [PythonRequest::Any]). Is that possible to trigger?

@charliermarsh charliermarsh added cli Related to the command line interface preview Experimental behavior labels Jul 4, 2024
@zanieb
Copy link
Member

zanieb commented Jul 4, 2024

I think we should probably not uninstall them all without some sort of explicit opt-in, although it would loosely match the semantics of install.

@zanieb
Copy link
Member

zanieb commented Jul 4, 2024

That match statement is just copied from the install implementation but isn't easy to get right now, maybe we should make it easier to construct the Any case in PythonRequest::parse e.g. with "any"

@charliermarsh
Copy link
Member Author

I think it should probably just error? Require at least one specifier.

@charliermarsh
Copy link
Member Author

Right now, how does the ::Any request work, how does one "create" that?

@charliermarsh
Copy link
Member Author

We could also accept all or have a --all flag that's mutually exclusive with targets.

@zanieb
Copy link
Member

zanieb commented Jul 4, 2024

Right now, how does the ::Any request work, how does one "create" that?

I think it's just the default request and you can't ask for it explicitly which seems weird. "all" makes sense in this context but not for requests in general. Lots of reasonable approaches here, I think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Related to the command line interface preview Experimental behavior
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants