Home > database >  How delete virtualenv in windows 10?
How delete virtualenv in windows 10?

Time:07-04

I have a problem when I delete my python virtualenv in windows 10. so I need a solution.

How to uninstall virtualenv without any error in windows

CodePudding user response:

1.at first, you need to activate virtualenv by

source venv_name\Scripts\activate

2.Then create requirements.txt file by

pip freeze > requirements.txt

3.then delete all python package inside your virtualenv by

pip uninstall -r requirements.txt -y

4.then deactivate virtualenv by

 deactivate 

5.at last delete your virtualenv by

rm -r venv_name

CodePudding user response:

You can just go ahead and delete the whole virtualenv folder from your project. The you just need to specify a new path for python interpreter that includes your python.exe file, and all your needed libraries in your project, that are usually in C:\Users\<your windows username>\AppData\Local\Programs\Python by default if you haven't changed the path during python installation. If you tell us which IDE you use to write your python code we could help you more accurately.

  • Related