[Answered ]-Pip install error: ModuleNotFoundError No module named 'setuptools'

1👍

virtualenvwrapper-win is only intended for the DOS cmd.exe. From the README:

These scripts should work on any version of Windows (Windows XP, Windows Vista, Windows 7/8/10).

However, they only work in the regular command prompt. They will not work in Powershell. There are other virtualenvwrapper projects out there for Powershell.

1👍

Try installing the virtualenvwrapper-win module manually by downloading the ZIP archive from here:
https://pypi.python.org/pypi/virtualenvwrapper-win

  • In your PowerShell console, go to the directory the archive downloaded to (mine goes to C:\Users\user\Downloads\) and run this to extract the archive: Expand-Archive .\virtualenvwrapper-win-1.2.1.zip

  • Still in PowerShell and in the same directory as above, run: cd .\virtualenvwrapper-win-1.2.1\virtualenvwrapper-win-1.2.1\

  • Next, run: python setup.py install

If all went well, you should see something like this:

    PS C:\Users\user\Downloads\virtualenvwrapper-win-1.2.1\virtualenvwrapper-win-1.2.1> python .\setup.py install
    running install
    running bdist_egg
    running egg_info
    writing virtualenvwrapper_win.egg-info\PKG-INFO
    writing dependency_links to virtualenvwrapper_win.egg-info\dependency_links.txt
    writing requirements to virtualenvwrapper_win.egg-info\requires.txt
    writing top-level names to virtualenvwrapper_win.egg-info\top_level.txt
    reading manifest file 'virtualenvwrapper_win.egg-info\SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    writing manifest file 'virtualenvwrapper_win.egg-info\SOURCES.txt'
    installing library code to build\bdist.win-amd64\egg
    running install_lib
    warning: install_lib: 'build\lib' does not exist -- no Python modules to install

    creating build
    creating build\bdist.win-amd64
    creating build\bdist.win-amd64\egg
    creating build\bdist.win-amd64\egg\EGG-INFO
    installing scripts to build\bdist.win-amd64\egg\EGG-INFO\scripts
    running install_scripts
    running build_scripts
    creating build\scripts-3.6
    copying scripts\add2virtualenv.bat -> build\scripts-3.6
    copying scripts\cd-.bat -> build\scripts-3.6
    copying scripts\cdproject.bat -> build\scripts-3.6
    copying scripts\cdsitepackages.bat -> build\scripts-3.6
    copying scripts\cdvirtualenv.bat -> build\scripts-3.6
    copying scripts\folder_delete.bat -> build\scripts-3.6
    copying scripts\lssitepackages.bat -> build\scripts-3.6
    copying scripts\lsvirtualenv.bat -> build\scripts-3.6
    copying scripts\mkvirtualenv.bat -> build\scripts-3.6
    copying scripts\rmvirtualenv.bat -> build\scripts-3.6
    copying scripts\setprojectdir.bat -> build\scripts-3.6
    copying scripts\toggleglobalsitepackages.bat -> build\scripts-3.6
    copying scripts\whereis.bat -> build\scripts-3.6
    copying scripts\workon.bat -> build\scripts-3.6
    creating build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\add2virtualenv.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\cd-.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\cdproject.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\cdsitepackages.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\cdvirtualenv.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\folder_delete.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\lssitepackages.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\lsvirtualenv.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\mkvirtualenv.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\rmvirtualenv.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\setprojectdir.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\toggleglobalsitepackages.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\whereis.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying build\scripts-3.6\workon.bat -> build\bdist.win-amd64\egg\EGG-INFO\scripts
    copying virtualenvwrapper_win.egg-info\PKG-INFO -> build\bdist.win-amd64\egg\EGG-INFO
    copying virtualenvwrapper_win.egg-info\SOURCES.txt -> build\bdist.win-amd64\egg\EGG-INFO
    copying virtualenvwrapper_win.egg-info\dependency_links.txt -> build\bdist.win-amd64\egg\EGG-INFO
    copying virtualenvwrapper_win.egg-info\not-zip-safe -> build\bdist.win-amd64\egg\EGG-INFO
    copying virtualenvwrapper_win.egg-info\requires.txt -> build\bdist.win-amd64\egg\EGG-INFO
    copying virtualenvwrapper_win.egg-info\top_level.txt -> build\bdist.win-amd64\egg\EGG-INFO
    creating dist
    creating 'dist\virtualenvwrapper_win-1.2.1-py3.6.egg' and adding 'build\bdist.win-amd64\egg' to it
    removing 'build\bdist.win-amd64\egg' (and everything under it)
    Processing virtualenvwrapper_win-1.2.1-py3.6.egg
    creating c:\users\user\appdata\local\programs\python\python36\lib\site-packages\virtualenvwrapper_win-1.2.1-py3.6.egg
    Extracting virtualenvwrapper_win-1.2.1-py3.6.egg to c:\users\user\appdata\local\programs\python\python36\lib\site-packages
    Adding virtualenvwrapper-win 1.2.1 to easy-install.pth file
    Installing add2virtualenv.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing cd-.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing cdproject.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing cdsitepackages.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing cdvirtualenv.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing folder_delete.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing lssitepackages.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing lsvirtualenv.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing mkvirtualenv.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing rmvirtualenv.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing setprojectdir.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing toggleglobalsitepackages.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing whereis.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing workon.bat script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts

    Installed c:\users\user\appdata\local\programs\python\python36\lib\site-packages\virtualenvwrapper_win-1.2.1-py3.6.egg
    Processing dependencies for virtualenvwrapper-win==1.2.1
    Searching for virtualenv==15.1.0
    Best match: virtualenv 15.1.0
    Adding virtualenv 15.1.0 to easy-install.pth file
    Installing virtualenv-script.py script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts
    Installing virtualenv.exe script to C:\Users\user\AppData\Local\Programs\Python\Python36\Scripts

    Using c:\users\user\appdata\local\programs\python\python36\lib\site-packages
    Finished processing dependencies for virtualenvwrapper-win==1.2.1

Leave a comment