• Register
Log In
1 vote

Problem :

Getting bellow python and django error 
'virtualenv' is not recognized as an internal or external command, operable program or batch file.

6.9k points

2 Answers

1 vote

Solution :

Please follow bellow steps to get rid of the issue
  • The windows PATH variable must have an entry with your python installation and the scripts subfolder as following C:\Program Files (x86)\Python36-32\ & C:\Program Files (x86)\Python36-32\Scripts\
  • While using pip install virtualenv, please make sure that you run cmd as administrator. Or else, there will be an access denied error during installation and virtualenv will not be installed properly.
  • Make sure that virtualenv has been installed correctly. Also check in the python scripts subfolder  there must exist an .exe named virtualenv.exe. If not, uninstall will pip uninstall virtualenv and install again.
36.1k points
0 votes


STEP 1:  You need to setup a virtual environment using

pip install virtualenv # got install successfully

STEP 2:  You create a virtual name

mkvirtualenv test

STEP 3: Get your own environment

uninstall using:

pip uninstall virtualenvwrapper-win
pip uninstall virtualenv

install using:

pip install virtualenvwrapper-win

STEP 4:  Go to where you want create django app on that folder.

After that, run this command on command prompt

python -m virtualenv .
C:\Users\gshiv\Desktop\django>python -m virtualenv .)

where django is the my folder i want run virtualenv and .(dot) indicates virtualenv install all it's folder in django folder otherwise you can use other folder name instead .(dot) this time virtulenv creates a folder in main folder(django) .

after running this command: run .\scripts\activate now you can see this type of line on cmd-prompt (django) C:\Users\gshiv\Desktop\django>

Main folder name before the source path. now you can install any modules for your project that belongs to that main folder only.

12.8k points

Related questions

0 votes
1 answer 40 views
Problem : Today I ran into a weird error trying to install Django as follows 'pip3' is not recognized as an internal or external command, operable program or batch file.
asked Nov 15, 2019 peterlaw 6.9k points
1 vote
1 answer 44 views
Problem: I installed flask in my system by running the command: pip install flask Collecting flask Downloading https://files.pythonhosted.org/packages/f2/28/2a03252dfb9ebf377f40fba6a7841b47083260bf8bd8e737b0c6952df83f/Flask-1.1.2-py2.py3-none-any.whl (94kB) |████████████████████████████████| ... operable program or batch file. Whats the problem running this can any one tell me? Thanks in advance.
asked May 12 samhaz 5k points
0 votes
1 answer 24 views
I am new to python programming. I am using atom IDE or atom editor for my python programs but every time I try to run a code or a script from my atom editor it gives me an error like : atom 'python' is not recognized as an internal or external command, operable ... and atom for 64 bit windows. Can anyone figure out what the problem really is and how can I solve this problem and run my code.
asked Mar 10 LizzyM 5.7k points
0 votes
1 answer 385 views
Problem : I am new to type script and unable to compile my type script file. When I try to hit Ctrl+Shift+B in my VS Code, I face below error " ‘Tsc' is not recognized as an internal or external command, operable program or batch file." I used ... C:\Users\mphil\AppData\Roaming\npm\node_modules\typescript\bin\tsc C:\Users\mphil\AppData\Roaming\npm `-- typescript@2.1.5 How to fix above error?
asked Feb 15 mphil 2.3k points
0 votes
1 answer 472 views
Problem : I am beginner in the node.js .Currently I am trying to install node.js using the below command npm install nodemon --save. But when I try to run a server with below command nodemon server.js. then in my terminal I face below error: “Nodemon is not recognized as internal or external command, operable program or batch file”
asked Feb 13 mphil 2.3k points