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

How to uninstall python package in r #1163

Open
sailseem opened this issue Feb 14, 2022 · 5 comments
Open

How to uninstall python package in r #1163

sailseem opened this issue Feb 14, 2022 · 5 comments

Comments

@sailseem
Copy link

Dear developer,
I found the function reticulate::py_install(packages ='’), I am wondering is there function like pip uninstall to remove the packages? Thanks

@benyamindsmith
Copy link

benyamindsmith commented Aug 10, 2022

I am wondering this also.

@pcstockman
Copy link

As am I.

@kevinushey
Copy link
Collaborator

kevinushey commented Aug 18, 2022

There isn't something directly, but you could hand-roll it with something like:

system2(reticulate::py_exe(), c("-m", "pip", "uninstall", <package>))

@ethanwhite
Copy link

ethanwhite commented Mar 4, 2023

This would definitely be a useful feature, especially in light of issues that can be solved by uninstalling mkl, which is installed by default. See #758 (comment)

That said, for the folks asking about this, if you're using conda, you do have access to conda_remove() which can be used to accomplish this:

reticulate::conda_remove('r-reticulate', packages = c('FirstPackageName', 'SecondPackageName'))

@lampropeltis9
Copy link

reticulate::conda_remove('r-reticulate', packages = c('FirstPackageName', 'SecondPackageName'))

Works pretty well. Thank you !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants
@ethanwhite @kevinushey @pcstockman @benyamindsmith @lampropeltis9 @sailseem and others