简体   繁体   中英

Error in installing pip package auto-py-to-exe

I am trying to install auto-py-to-exe. In fact, I installed it but a months ago, I reinstalled my windows 10. After that, I am continuously trying to install auto-py-to-exe. Whenever I type pip install auto-py-to-exe in command prompt this output comes out

Collecting auto-py-to-exe
  Using cached auto_py_to_exe-2.7.11-py2.py3-none-any.whl (75 kB)
Collecting Eel==0.12.4
  Using cached Eel-0.12.4.tar.gz (15 kB)
Collecting pyinstaller>=4.1
  Using cached pyinstaller-4.1.tar.gz (3.5 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Collecting bottle
  Using cached bottle-0.12.19-py3-none-any.whl (89 kB)
Collecting bottle-websocket
  Using cached bottle-websocket-0.2.9.tar.gz (2.0 kB)
Collecting future
  Using cached future-0.18.2.tar.gz (829 kB)
Collecting whichcraft
  Using cached whichcraft-0.6.1-py2.py3-none-any.whl (5.2 kB)
Collecting pyinstaller-hooks-contrib>=2020.6
  Using cached pyinstaller_hooks_contrib-2020.11-py2.py3-none-any.whl (172 kB)
Collecting altgraph
  Using cached altgraph-0.17-py2.py3-none-any.whl (21 kB)
Requirement already satisfied: setuptools in c:\users\mniza\appdata\local\programs\python\python39\lib\site-packages (from pyinstaller>=4.1->auto-py-to-exe) (49.2.1)
Collecting pywin32-ctypes>=0.2.0; sys_platform == "win32"
  Using cached pywin32_ctypes-0.2.0-py2.py3-none-any.whl (28 kB)
Collecting pefile>=2017.8.1; sys_platform == "win32"
  Using cached pefile-2019.4.18.tar.gz (62 kB)
Collecting gevent-websocket
  Using cached gevent_websocket-0.10.1-py3-none-any.whl (22 kB)
Collecting gevent
  Using cached gevent-20.12.1.tar.gz (5.9 MB)
  Installing build dependencies ... error
  ERROR: Command errored out with exit status 1:
   command: 'c:\users\mniza\appdata\local\programs\python\python39\python.exe' 'c:\users\mniza\appdata\local\programs\python\python39\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools >= 40.8.0' wheel 'Cython >= 3.0a5' 'cffi >= 1.12.3 ; platform_python_implementation == '"'"'CPython'"'"'' 'greenlet >= 0.4.17, < 2.0 ; platform_python_implementation == '"'"'CPython'"'"''
       cwd: None
  Complete output (29 lines):
  Collecting setuptools>=40.8.0
    Using cached setuptools-51.1.1-py3-none-any.whl (2.0 MB)
  Collecting wheel
    Using cached wheel-0.36.2-py2.py3-none-any.whl (35 kB)
  Collecting Cython>=3.0a5
    Using cached Cython-3.0a6-py2.py3-none-any.whl (1.0 MB)
  Collecting cffi>=1.12.3
    Using cached cffi-1.14.4-cp39-cp39-win_amd64.whl (179 kB)
  Collecting greenlet<2.0,>=0.4.17
    Using cached greenlet-0.4.17.tar.gz (61 kB)
  Collecting pycparser
    Using cached pycparser-2.20-py2.py3-none-any.whl (112 kB)
  Using legacy 'setup.py install' for greenlet, since package 'wheel' is not installed.
  Installing collected packages: setuptools, wheel, Cython, pycparser, cffi, greenlet
      Running setup.py install for greenlet: started
      Running setup.py install for greenlet: finished with status 'error'
      ERROR: Command errored out with exit status 1:
       command: 'c:\users\mniza\appdata\local\programs\python\python39\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\mniza\\AppData\\Local\\Temp\\pip-install-c3p25el7\\greenlet\\setup.py'"'"'; __file__='"'"'C:\\Users\\mniza\\AppData\\Local\\Temp\\pip-install-c3p25el7\\greenlet\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\mniza\AppData\Local\Temp\pip-record-sq3sf8sv\install-record.txt' --single-version-externally-managed --prefix 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay' --compile --install-headers 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay\Include\greenlet'
           cwd: C:\Users\mniza\AppData\Local\Temp\pip-install-c3p25el7\greenlet\
      Complete output (5 lines):
      running install
      running build
      running build_ext
      building 'greenlet' extension
      error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/
      ----------------------------------------
  ERROR: Command errored out with exit status 1: 'c:\users\mniza\appdata\local\programs\python\python39\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\mniza\\AppData\\Local\\Temp\\pip-install-c3p25el7\\greenlet\\setup.py'"'"'; __file__='"'"'C:\\Users\\mniza\\AppData\\Local\\Temp\\pip-install-c3p25el7\\greenlet\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\mniza\AppData\Local\Temp\pip-record-sq3sf8sv\install-record.txt' --single-version-externally-managed --prefix 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay' --compile --install-headers 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay\Include\greenlet' Check the logs for full command output.
  WARNING: You are using pip version 20.2.3; however, version 20.3.3 is available.
  You should consider upgrading via the 'c:\users\mniza\appdata\local\programs\python\python39\python.exe -m pip install --upgrade pip' command.
  ----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\users\mniza\appdata\local\programs\python\python39\python.exe' 'c:\users\mniza\appdata\local\programs\python\python39\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\mniza\AppData\Local\Temp\pip-build-env-hh9ixh_9\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools >= 40.8.0' wheel 'Cython >= 3.0a5' 'cffi >= 1.12.3 ; platform_python_implementation == '"'"'CPython'"'"'' 'greenlet >= 0.4.17, < 2.0 ; platform_python_implementation == '"'"'CPython'"'"'' Check the logs for full command output.
WARNING: You are using pip version 20.2.3; however, version 20.3.3 is available.
You should consider upgrading via the 'c:\users\mniza\appdata\local\programs\python\python39\python.exe -m pip install --upgrade pip' command.

I assume that there is something wrong with Microsoft Visual C++ as I can see in the error error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/ error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/

But when I try to install Microsoft Visual C++ I see this window error in installing Microsoft Visual C++ 14.0 (picture)

I again checked the program list and I am a little bit confused which one should I uninstall and which one should I keep program list (picture) . Overall I am stuck in this issue for more than three weeks and I will be grateful if anyone can solve this issue.

At last, I have figured out what is the problem. First I have to install a suitable wheel file of greenlet from https://www.lfd.uci.edu/~gohlke/pythonlibs/#greenlet . And then open the command prompt in the directory of the wheel file. Then type pip install (filename) After that, again download the wheel file of gevent from https://www.lfd.uci.edu/~gohlke/pythonlibs/#gevent . As before open command prompt in the directory of the wheel file and type pip install (filename) again. After all of this, type pip install auto-py-to-exe

Hope this will to you as it worked to me!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM