1

Im following this tutorial: https://www.codingforentrepreneurs.com/blog/install-python-django-on-windows/

on step 7, I tried running pipenv shell in the same directory called cfehome, and also in a different directory, but it doesnt say the (cfehome) before the path, so i thought it hadnt been activated, but when I run the command again, it says environment already activated.

Also, the tutorial states when i run pip freeze, i should get no output. but i do get an output with the names of different libraries.

I followed all other steps and they gave the desired output so I dont know why this step is not?

Vanessa
  • 31
  • 1
  • 6
  • The fact that you don't see "cfehome" is probably because you're shell is different than what is assumed by the tutorial; I don't know how well `pipenv` handles powershell. But it appears your environment was installed and activated. – 9769953 May 24 '20 at 03:32
  • `pip freeze` should indeed show a list of installed packages. In the linked text, it mentions you should see no output, because you should have not installed any packages at that point. – 9769953 May 24 '20 at 03:38
  • @0_0 yes i thought I would see some other name or something, or cfehome cause thats the same of the directory!! (since i followed all steps i thought the environment is called whatever the directory is called), but ya the pip freeze thing makes sense cause they dont expect me to have any packages installed. thanks so much :) – Vanessa May 25 '20 at 13:14

1 Answers1

3

for more details, you can take a look at stackoverflow virtualenv-wont-activate-on-windows 4th answer by Do Nhu Vy. He has explained in detail taking screenshots one by one.

On Windows, open Windows PowerShell as Administrator

create a virtual environment

pip install virtualenv
virtualenv foo      
cd .\foo
.\Scripts\activate
  1. install virtual environment by running command pip install virtualenv
  2. make a virtual environment by running command virtualenv env_name , here env_name is name of virtual environment
  3. go into virtaul environment directory by cd cd .\env_name
  4. activate virtual environment by command .\Scripts\activate
Sheraram_Prajapat
  • 589
  • 1
  • 9
  • 27