'How to import gym retro?

Am a beginner in Python but have some prog exp. Trying to do this tutorial, I even asked the creator for help via Patreon but not gotten much. https://www.youtube.com/watch?v=rzbFhu6So5U&t=391s

Setup Street Fighter

pip install gym gym-retro

Ouput, suggests already have yet still get errors?

First error:

ERROR: Command errored out with exit status 1:
   command: 'C:\Users\LiamR\anaconda3\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\LiamR\\AppData\\Local\\Temp\\pip-install-frru4j8r\\gym-retro_bdc3085827b84848a47b6e30d08f70cf\\setup.py'"'"'; __file__='"'"'C:\\Users\\LiamR\\AppData\\Local\\Temp\\pip-install-frru4j8r\\gym-retro_bdc3085827b84848a47b6e30d08f70cf\\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\LiamR\AppData\Local\Temp\pip-wheel-jro0si4j'
       cwd: C:\Users\LiamR\AppData\Local\Temp\pip-install-frru4j8r\gym-retro_bdc3085827b84848a47b6e30d08f70cf\

Middle is 7200 lines

End Erorr:

ERROR: Command errored out with exit status 1: 'C:\Users\LiamR\anaconda3\python.exe' -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\LiamR\\AppData\\Local\\Temp\\pip-install-frru4j8r\\gym-retro_bdc3085827b84848a47b6e30d08f70cf\\setup.py'"'"'; __file__='"'"'C:\\Users\\LiamR\\AppData\\Local\\Temp\\pip-install-frru4j8r\\gym-retro_bdc3085827b84848a47b6e30d08f70cf\\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\LiamR\AppData\Local\Temp\pip-record-crxknzne\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Users\LiamR\anaconda3\Include\gym-retro' Check the logs for full command output.


Solution 1:[1]

I got an error like this because I was using python 3.9 version so, I made a downgrade to 3.8 and it works.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 oguz ismail