Hello,
I got an error when trying to install robotframework-ride either via Visual Studio (Professional 2022) Python (3.9 installed via visual studio installer) Environment or pip (provided by visual studio) install.
I searched for vcvarsall.bat and found in : C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Auxiliary\Build
I tried adding it to PATH or setting VS100COMNTOOLS in command prompt before running pip install but that didn't help.
I have the Python native development-tools installed and Live Share installed.
----- Installing 'robotframework-ride' -----
Collecting robotframework-ride
Using cached robotframework-ride-1.7.4.2.tar.gz (846 kB)
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'done'
Collecting wxPython<=4.0.7.post2
Using cached wxPython-4.0.7.post2.tar.gz (68.9 MB)
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'done'
Collecting PyPubSub
Using cached Pypubsub-4.0.3-py3-none-any.whl (61 kB)
Collecting Pygments
Using cached Pygments-2.10.0-py3-none-any.whl (1.0 MB)
Collecting Pywin32
Using cached pywin32-302-cp39-cp39-win_amd64.whl (9.3 MB)
Requirement already satisfied: pillow in c:\users\myntid\appdata\roaming\python\python39\site-packages (from wxPython<=4.0.7.post2->robotframework-ride) (8.4.0)
Requirement already satisfied: six in c:\users\myntid\appdata\roaming\python\python39\site-packages (from wxPython<=4.0.7.post2->robotframework-ride) (1.16.0)
Requirement already satisfied: numpy in c:\users\myntid\appdata\roaming\python\python39\site-packages (from wxPython<=4.0.7.post2->robotframework-ride) (1.21.4)
Using legacy 'setup.py install' for robotframework-ride, since package 'wheel' is not installed.
Using legacy 'setup.py install' for wxPython, since package 'wheel' is not installed.
Installing collected packages: wxPython, Pywin32, PyPubSub, Pygments, robotframework-ride
Running setup.py install for wxPython: started
Running setup.py install for wxPython: finished with status 'error'
ERROR: Command errored out with exit status 1:
command: 'C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\myntid\\AppData\\Local\\Temp\\pip-install-ozgdr8k0\\wxpython_a7138ebdeb574a07b80c474376e7aa7f\\setup.py'"'"'; __file__='"'"'C:\\Users\\myntid\\AppData\\Local\\Temp\\pip-install-ozgdr8k0\\wxpython_a7138ebdeb574a07b80c474376e7aa7f\\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\myntid\AppData\Local\Temp\pip-record-vywhqx7l\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\Include\wxPython'
cwd: C:\Users\myntid\AppData\Local\Temp\pip-install-ozgdr8k0\wxpython_a7138ebdeb574a07b80c474376e7aa7f\
Complete output (39 lines):
C:\Users\myntid\AppData\Roaming\Python\Python39\site-packages\setuptools\dist.py:723: UserWarning: Usage of dash-separated 'license-file' will not be supported in future versions. Please use the underscore name 'license_file' instead
warnings.warn(
C:\Users\myntid\AppData\Roaming\Python\Python39\site-packages\setuptools\dist.py:300: DistDeprecationWarning: use_2to3 is ignored.
warnings.warn(f"{attr} is ignored.", DistDeprecationWarning)
running install
C:\Users\myntid\AppData\Roaming\Python\Python39\site-packages\setuptools\command\install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
running build
Will build using: "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe"
3.9.7 (tags/v3.9.7:1016ef3, Aug 30 2021, 20:19:38) [MSC v.1929 64 bit (AMD64)]
Python's architecture is 64bit
cfg.VERSION: 4.0.7.post2
Running command: build
Running command: build_wx
Command '"C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe" -c "import distutils.msvc9compiler as msvc; mc = msvc.MSVCCompiler(); mc.initialize(); print(mc.cc)"' failed with exit code 1.
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\lib\distutils\msvc9compiler.py", line 371, in initialize
vc_env = query_vcvarsall(VERSION, plat_spec)
File "C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\lib\distutils\msvc9compiler.py", line 260, in query_vcvarsall
raise DistutilsPlatformError("Unable to find vcvarsall.bat")
distutils.errors.DistutilsPlatformError: Unable to find vcvarsall.bat
Finished command: build_wx (0.156s)
Finished command: build (0.156s)
WARNING: Building this way assumes that all generated files have been
generated already. If that is not the case then use build.py directly
to generate the source and perform the build stage. You can use
--skip-build with the bdist_* or install commands to avoid this
message and the wxWidgets and Phoenix build steps in the future.
"C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe" -u build.py build
Command '"C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe" -u build.py build' failed with exit code 1.
----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\myntid\\AppData\\Local\\Temp\\pip-install-ozgdr8k0\\wxpython_a7138ebdeb574a07b80c474376e7aa7f\\setup.py'"'"'; __file__='"'"'C:\\Users\\myntid\\AppData\\Local\\Temp\\pip-install-ozgdr8k0\\wxpython_a7138ebdeb574a07b80c474376e7aa7f\\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\myntid\AppData\Local\Temp\pip-record-vywhqx7l\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Program Files (x86)\Microsoft Visual Studio\Shared\Python39_64\Include\wxPython' Check the logs for full command output.
----- Failed to install 'robotframework-ride' -----