Ошибка command errored out with exit status 1

I am trying to download auto-py-to-exe on a different (windows) device than I usually use through pip. However when run I get the error (sorry it is so very very long):

ERROR: Command errored out with exit status 1:
     command: 'c:\users\tom\appdata\local\programs\python\python38-32\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\tom\\AppData\\Local\\Temp\\pip-install-aplljhe0\\gevent\\setup.py'"'"'; __file__='"'"'C:\\Users\\tom\\AppData\\Local\\Temp\\pip-install-aplljhe0\\gevent\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\tom\AppData\Local\Temp\pip-install-aplljhe0\gevent\pip-egg-info'
         cwd: C:\Users\tom\AppData\Local\Temp\pip-install-aplljhe0\gevent\
    Complete output (113 lines):
    Traceback (most recent call last):
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 489, in _find_latest_available_vc_ver
        return self.find_available_vc_vers()[-1]
    IndexError: list index out of range

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
        yield saved
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
        yield
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
        _execfile(setup_script, ns)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
        exec(code, globals, locals)
      File "C:\Users\tom\AppData\Local\Temp\easy_install-29et0so1\cffi-1.14.0\setup.py", line 127, in <module>
        HUB_PRIMITIVES = Extension(name="gevent.__hub_primitives",
      File "C:\Users\tom\AppData\Local\Temp\easy_install-29et0so1\cffi-1.14.0\setup.py", line 105, in uses_msvc
        include_dirs=include_dirs)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 225, in try_compile
        self._compile(body, headers, include_dirs, lang)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 132, in _compile
        self.compiler.compile([src], include_dirs=include_dirs)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 360, in compile
        self.initialize()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 253, in initialize
        vc_env = _get_vc_env(plat_spec)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 185, in msvc14_get_vc_env
        return EnvironmentInfo(plat_spec, vc_min_ver=14.0).return_env()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 843, in __init__
        self.si = SystemInfo(self.ri, vc_ver)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 485, in __init__
        self.vc_ver = vc_ver or self._find_latest_available_vc_ver()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 492, in _find_latest_available_vc_ver
        raise distutils.errors.DistutilsPlatformError(err)
    distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\tom\AppData\Local\Temp\pip-install-aplljhe0\gevent\setup.py", line 427, in <module>
        run_setup(EXT_MODULES, run_make=_BUILDING)
      File "C:\Users\tom\AppData\Local\Temp\pip-install-aplljhe0\gevent\setup.py", line 328, in run_setup
        setup(
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 144, in setup
        _install_setup_requires(attrs)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 139, in _install_setup_requires
        dist.fetch_build_eggs(dist.setup_requires)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 716, in fetch_build_eggs
        resolved_dists = pkg_resources.working_set.resolve(
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 780, in resolve
        dist = best[req.key] = env.best_match(
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1065, in best_match
        return self.obtain(req, installer)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1077, in obtain
        return installer(requirement)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 786, in fetch_build_egg
        return cmd.easy_install(req)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 679, in easy_install
        return self.install_item(spec, dist.location, tmpdir, deps)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 705, in install_item
        dists = self.install_eggs(spec, download, tmpdir)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 890, in install_eggs
        return self.build_and_install(setup_script, setup_base)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1158, in build_and_install
        self.run_setup(setup_script, setup_base, args)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1144, in run_setup
        run_setup(setup_script, args)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 253, in run_setup
        raise
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__
        self.gen.throw(type, value, traceback)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
        yield
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__
        self.gen.throw(type, value, traceback)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 166, in save_modules
        saved_exc.resume()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 141, in resume
        six.reraise(type, exc, self._tb)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\_vendor\six.py", line 685, in reraise
        raise value.with_traceback(tb)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules
        yield saved
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context
        yield
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup
        _execfile(setup_script, ns)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile
        exec(code, globals, locals)
      File "C:\Users\tom\AppData\Local\Temp\easy_install-29et0so1\cffi-1.14.0\setup.py", line 127, in <module>
        HUB_PRIMITIVES = Extension(name="gevent.__hub_primitives",
      File "C:\Users\tom\AppData\Local\Temp\easy_install-29et0so1\cffi-1.14.0\setup.py", line 105, in uses_msvc
        include_dirs=include_dirs)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 225, in try_compile
        self._compile(body, headers, include_dirs, lang)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\command\config.py", line 132, in _compile
        self.compiler.compile([src], include_dirs=include_dirs)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 360, in compile
        self.initialize()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 253, in initialize
        vc_env = _get_vc_env(plat_spec)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 185, in msvc14_get_vc_env
        return EnvironmentInfo(plat_spec, vc_min_ver=14.0).return_env()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 843, in __init__
        self.si = SystemInfo(self.ri, vc_ver)
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 485, in __init__
        self.vc_ver = vc_ver or self._find_latest_available_vc_ver()
      File "c:\users\tom\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\msvc.py", line 492, in _find_latest_available_vc_ver
        raise distutils.errors.DistutilsPlatformError(err)
    distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Even though it does state that I need Visual Studio C++ 14.0 my computer won’t install it and I have not needed it before. I checked This Stack Overflow Question but it relates to another pip install and has no answers. If the only answer is to install Visual Studio then I am kinda screwed.

I am having this error during installing dlib and face-recognition. (cmake is done)

Collecting dlib==19.18.0
Using cached dlib-19.18.0.tar.gz (3.1 MB)
Building wheels for collected packages: dlib
Building wheel for dlib (setup.py): started
Building wheel for dlib (setup.py): finished with status ‘error’
Running setup.py clean for dlib
Failed to build dlib
Installing collected packages: dlib
Running setup.py install for dlib: started
Running setup.py install for dlib: finished with status ‘error’

ERROR: Command errored out with exit status 1:
command: ‘C:\Users\Haider\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe’ -u -c ‘import io, os, sys, setuptools, tokenize; sys.argv[0] = ‘»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘; file='»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘;f = getattr(tokenize, ‘»‘»‘open'»‘»‘, open)(file) if os.path.exists(file) else io.StringIO(‘»‘»‘from setuptools import setup; setup()'»‘»‘);code = f.read().replace(‘»‘»‘\r\n'»‘»‘, ‘»‘»‘\n'»‘»‘);f.close();exec(compile(code, file, ‘»‘»‘exec'»‘»‘))’ bdist_wheel -d ‘C:\Users\Haider\AppData\Local\Temp\pip-wheel-usp4krfi’
cwd: C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9
Complete output (55 lines):
running bdist_wheel
running build
running build_py
package init file ‘dlib_init_.py’ not found (or not a regular file)
warning: build_py: byte-compiling is disabled, skipping.

running build_ext
Traceback (most recent call last):
File «C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py», line 120, in get_cmake_version
out = subprocess.check_output([‘cmake’, ‘—version’])
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py», line 424, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py», line 505, in run
with Popen(*popenargs, **kwargs) as process:
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py», line 951, in init
self._execute_child(args, executable, preexec_fn, close_fds,
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py», line 1420, in _execute_child
hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File «», line 1, in
File «C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py», line 223, in
setup(
File «C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\setuptools_init_.py», line 153, in setup
return distutils.core.setup(attrs)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\core.py», line 148, in setup
dist.run_commands()
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py», line 966, in run_commands
self.run_command(cmd)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py», line 985, in run_command
cmd_obj.run()
File «C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\wheel\bdist_wheel.py», line 299, in run
self.run_command(‘build’)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py», line 313, in run_command
self.distribution.run_command(command)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py», line 985, in run_command
cmd_obj.run()
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\command\build.py», line 135, in run
self.run_command(cmd_name)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py», line 313, in run_command
self.distribution.run_command(command)
File «C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py», line 985, in run_command
cmd_obj.run()
File «C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py», line 129, in run
cmake_version = self.get_cmake_version()
File «C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py», line 122, in get_cmake_version
raise RuntimeError(«\n
*****************************************************************\n» +
RuntimeError:


CMake must be installed to build the following extensions: dlib



ERROR: Failed building wheel for dlib
ERROR: Command errored out with exit status 1:
command: ‘C:\Users\Haider\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe’ -u -c ‘import io, os, sys, setuptools, tokenize; sys.argv[0] = ‘»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘; file='»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘;f = getattr(tokenize, ‘»‘»‘open'»‘»‘, open)(file) if os.path.exists(file) else io.StringIO(‘»‘»‘from setuptools import setup; setup()'»‘»‘);code = f.read().replace(‘»‘»‘\r\n'»‘»‘, ‘»‘»‘\n'»‘»‘);f.close();exec(compile(code, file, ‘»‘»‘exec'»‘»‘))’ install —record ‘C:\Users\Haider\AppData\Local\Temp\pip-record-lyp_jhye\install-record.txt’ —single-version-externally-managed —user —prefix= —compile —install-headers ‘C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\Include\dlib’
cwd: C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9
Complete output (57 lines):
running install
running build
running build_py
package init file ‘dlib_init_.py’ not found (or not a regular file)
warning: build_py: byte-compiling is disabled, skipping.

running build_ext
Traceback (most recent call last):
  File "C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py", line 120, in get_cmake_version
    out = subprocess.check_output(['cmake', '--version'])
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 424, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 505, in run
    with Popen(*popenargs, **kwargs) as process:
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 951, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\subprocess.py", line 1420, in _execute_child
    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py", line 223, in <module>
    setup(
  File "C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\setuptools\__init__.py", line 153, in setup
    return distutils.core.setup(**attrs)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\core.py", line 148, in setup
    dist.run_commands()
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 966, in run_commands
    self.run_command(cmd)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
    cmd_obj.run()
  File "C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\site-packages\setuptools\command\install.py", line 61, in run
    return orig.install.run(self)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\command\install.py", line 546, in run
    self.run_command('build')
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
    cmd_obj.run()
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\command\build.py", line 135, in run
    self.run_command(cmd_name)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.9_3.9.1520.0_x64__qbz5n2kfra8p0\lib\distutils\dist.py", line 985, in run_command
    cmd_obj.run()
  File "C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py", line 129, in run
    cmake_version = self.get_cmake_version()
  File "C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py", line 122, in get_cmake_version
    raise RuntimeError("\n*******************************************************************\n" +
RuntimeError:
*******************************************************************
 CMake must be installed to build the following extensions: dlib
*******************************************************************

----------------------------------------

ERROR: Command errored out with exit status 1: ‘C:\Users\Haider\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\python.exe’ -u -c ‘import io, os, sys, setuptools, tokenize; sys.argv[0] = ‘»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘; file='»‘»‘C:\Users\Haider\AppData\Local\Temp\pip-install-57j0zzf2\dlib_c4a81041578145ff85c50fb1f74112f9\setup.py'»‘»‘;f = getattr(tokenize, ‘»‘»‘open'»‘»‘, open)(file) if os.path.exists(file) else io.StringIO(‘»‘»‘from setuptools import setup; setup()'»‘»‘);code = f.read().replace(‘»‘»‘\r\n'»‘»‘, ‘»‘»‘\n'»‘»‘);f.close();exec(compile(code, file, ‘»‘»‘exec'»‘»‘))’ install —record ‘C:\Users\Haider\AppData\Local\Temp\pip-record-lyp_jhye\install-record.txt’ —single-version-externally-managed —user —prefix= —compile —install-headers ‘C:\Users\Haider\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.9_qbz5n2kfra8p0\LocalCache\local-packages\Python39\Include\dlib’ Check the logs for full command output.

If you are installing auto-py-to-exe package on Python 3.8 or below, you will get an error stating ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

In this tutorial, we will look into what exactly is ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output and how to fix it.

The auto-py-to-exe library is mainly used to convert the python file(.py) into an executable file (.exe) and run it on windows.

As shown below, we can install the package directly through the pip command in Python 3.8.

$ pip install auto-py-to-exe

The package has an additional dependency on bottle-websocket, which in turn has a dependency on the gevent.

gevent did not release a stable version that offers prebuilt wheels for Python 3.8 during the time of release. Hence, the pip will pick the prebuilt wheels and try to build the gevent==1.4 version from the source dist, resulting in the below error.

ERROR: Command errored out with exit status 1:
    raise distutils.errors.DistutilsPlatformError(err)
    distutils.errors.DistutilsPlatformError: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Later they had released the new version, which works without any issue. Let us look at the fix for this issue.

Solution

Currently, there are many versions of gevent released, including prebuilt wheels for Python 3.8 on Windows. You can just execute the below command to install the auto-py-to-exe package.

pip install auto-py-to-exe

If this is not working for you, you can try an alternate solution listed below.

pip3 install --upgrade pip setuptools wheel

If you are not able to install setuptools through pip you can also download Microsoft Visual C++ Build Tools and install it manually.

OR

pip install --no-use-wheel --upgrade distribute
pip install --upgrade setuptools

Once you perform this operation, you can install the auto-py-to-exe package. The same solution applies to other libraries, too, which have a dependency on gevent.

Avatar Of Srinivas Ramakrishna

Srinivas Ramakrishna is a Solution Architect and has 14+ Years of Experience in the Software Industry. He has published many articles on Medium, Hackernoon, dev.to and solved many problems in StackOverflow. He has core expertise in various technologies such as Microsoft .NET Core, Python, Node.JS, JavaScript, Cloud (Azure), RDBMS (MSSQL), React, Powershell, etc.

Sign Up for Our Newsletters

Subscribe to get notified of the latest articles. We will never spam you. Be a part of our ever-growing community.

By checking this box, you confirm that you have read and are agreeing to our terms of use regarding the storage of the data submitted through this form.

In this Python tutorial, we will see how to fix the error, Command errored out with exit status 1 in Python.

The error was coming when I was trying to install the Python strings module by running the below command:

pip install strings

The complete error was coming like below:

ERROR: Command errored out with exit status 1:
command: ‘c:\python\python38\python.exe’ -c ‘import sys, setuptools, tokenize; sys.argv[0] = ‘”‘”‘C:\Users\Administrator.SHAREPOINTSKY\AppData\Local\Temp\pip-install-e261r6ji\strings\setup.py’”‘”‘; file=’”‘”‘C:\Users\Administrator.SHAREPOINTSKY\AppData\Local\Temp\pip-install-e261r6ji\strings\setup.py’”‘”‘;f=getattr(tokenize, ‘”‘”‘open’”‘”‘, open)(file);code=f.read().replace(‘”‘”‘\r\n’”‘”‘, ‘”‘”‘\n’”‘”‘);f.close();exec(compile(code, file, ‘”‘”‘exec’”‘”‘))’ egg_info –egg-base ‘C:\Users\Administrator.SHAREPOINTSKY\AppData\Local\Temp\pip-pip-egg-info-hu8mfm_g’
cwd: C:\Users\Administrator.SHAREPOINTSKY\AppData\Local\Temp\pip-install-e261r6ji\strings\
Complete output (5 lines):
Traceback (most recent call last):
File “”, line 1, in
File “C:\Users\Administrator.SHAREPOINTSKY\AppData\Local\Temp\pip-install-e261r6ji\strings\setup.py”, line 5, in
import strings
ModuleNotFoundError: No module named ‘strings’
—————————————-
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Below image shows the screenshot of error:

Command errored out with exit status 1

Command errored out with exit status 1

There was no issue with the command, one file with name string.py was causing the issue.

As you can see below there was filename string.py in the same folder which was causing the issue.

To fix the issue, we need to simply delete the string.py file from the folder.

Ideally, we should not create any file with name as string.py.

Command errored out with exit status 1 python
Command errored out with exit status 1 python

AttributeError: partially initialized module ‘random’ has no attribute ‘randint’

The above same file name (string.py) issue might give the below error also,

AttributeError: partially initialized module ‘random’ has no attribute ‘randint’ (most likely due to a circular import).

Follow the same delete the file solution to fix this issue also.

You may like the following python tutorials:

  • Python epoch to DateTime + Examples
  • Priority queue in Python
  • Python 3 pickle typeerror a bytes-like object is required not ‘str’
  • Python binary search and linear search
  • Sorting algorithms in Python
  • Working with JSON data in Python
  • Python GUI Programming
  • Increment and Decrement operators in Python
  • Constructor in Python
  • How to convert dictionary to JSON in Python

Here, we learned how to fix the below two errors in Python:

  • Command errored out with exit status 1 python
  • AttributeError: partially initialized module ‘random’ has no attribute ‘randint’

Fewlines4Biju Bijay

I am Bijay Kumar, a Microsoft MVP in SharePoint. Apart from SharePoint, I started working on Python, Machine learning, and artificial intelligence for the last 5 years. During this time I got expertise in various Python libraries also like Tkinter, Pandas, NumPy, Turtle, Django, Matplotlib, Tensorflow, Scipy, Scikit-Learn, etc… for various clients in the United States, Canada, the United Kingdom, Australia, New Zealand, etc. Check out my profile.

When installing packages using pip, you might encounter the following error:

ERROR: Command errored out with exit status 1: python setup.py egg_info 
Check the logs for full command output.

This error is a general error that occurs when Python fails to perform the installation you requested. The exit code 1 means Python chooses to terminate the progress because of a specific issue.

This error can happen for many reasons depending on the package you try to install.

To resolve the error, you need to look into the error message for specific details regarding your package. Let me show you two specific examples from which you can try to find yours.

1. Installing pyscopg2 package

When installing the psycopg2 package, this error might occur:

----------------------------------------
ERROR: Command errored out with exit status 1: 
python setup.py egg_info Check the logs for full command output.

To see the real cause of this error, you need to look above the horizontal lines:

Error: pg_config executable not found.

pg_config is required to build psycopg2 from source.  Please add the directory
containing pg_config to the $PATH or specify the full executable path with the
option:

    python setup.py build_ext --pg-config /path/to/pg_config build ...

or with the pg_config option in 'setup.cfg'.

If you prefer to avoid building psycopg2 from source, please install the PyPI
'psycopg2-binary' package instead.

For further information please check the 'doc/src/install.rst' file (also at
<http://initd.org/psycopg/docs/install.html>).
----------------------------------------

When you read the message, the error occurs because the psycopg2 package requires the pg_config executable file to install properly.

You can get pg_config by installing Postgres in your system, as detailed here.

Once you have pg_config available, run the command to install pyscopg2 package again. It should work this time.

1. Installing NumPy package

In another example, installing a specific NumPy version also give this error:

building library "npymath" sources
error: Microsoft Visual C++ 14.0 or greater is required. 
Get it with "Microsoft C++ Build Tools": 
https://visualstudio.microsoft.com/visual-cpp-build-tools/
----------------------------------------

To resolve this error, you need to install the Microsoft Visual C++ Build Tools which you can download here.

Once the build tools are installed, run the installation command again. Notice that you didn’t receive the error this time.

Conclusion

The Python ERROR: Command errored out with exit status 1 usually occurs when the requirements to install a package are not satisfied on your system.

To resolve this error, You need to meet the requirements, like installing the required software and making it available to access from the PATH environment variable.

You need to read the error message above the exit status 1 line to figure out the real cause of this error.

I hope this tutorial is helpful. See you in other tutorials! 👋

Понравилась статья? Поделить с друзьями:
  • Ошибка command contains unrecognized phrase keyword
  • Ошибка compile error cant find project or library
  • Ошибка comm error на хундай 300
  • Ошибка commandtext does not return a result set
  • Ошибка cpu на материнской плате msi