llSourcell / OpenAI_Game_Bot_Live_stream

This is the code for the "How to Install OpenAI's Universe and Make a Game Bot" live session by Siraj Raval on Youtube
39 stars 36 forks source link

ImportError: No module named 'gym.benchmarks' while pytest #10

Open Nannigalaxy opened 5 years ago

Nannigalaxy commented 5 years ago

I looked into many such related issues but none helped me. I even tried downgrading gym to 0.9.5.

(openai) nannigalaxy@nd:~/Documents/openai/universe/universe$ docker run --privileged --rm -e DOCKER_NET_HOST=172.17.0.1 -v /var/run/docker.sock:/var/run/docker.sock universe pytest
============================= test session starts ==============================
platform linux -- Python 3.5.2, pytest-3.8.0, py-1.6.0, pluggy-0.7.1
rootdir: /usr/local/universe, inifile:
collected 0 items / 7 errors

==================================== ERRORS ====================================
________ ERROR collecting tests/functional/test_core_envs_semantics.py _________
ImportError while importing test module '/usr/local/universe/tests/functional/test_core_envs_semantics.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
tests/functional/test_core_envs_semantics.py:8: in <module>
    from universe import wrappers
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
________________ ERROR collecting tests/functional/test_envs.py ________________
ImportError while importing test module '/usr/local/universe/tests/functional/test_envs.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
tests/functional/test_envs.py:7: in <module>
    from universe import wrappers
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
____________ ERROR collecting universe/envs/tests/test_semantics.py ____________
ImportError while importing test module '/usr/local/universe/universe/envs/tests/test_semantics.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
________ ERROR collecting universe/rewarder/tests/test_reward_buffer.py ________
ImportError while importing test module '/usr/local/universe/universe/rewarder/tests/test_reward_buffer.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
universe/rewarder/tests/test_reward_buffer.py:1: in <module>
    from universe.rewarder import reward_buffer
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
________ ERROR collecting universe/vectorized/tests/test_monitoring.py _________
ImportError while importing test module '/usr/local/universe/universe/vectorized/tests/test_monitoring.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
universe/vectorized/tests/test_monitoring.py:4: in <module>
    import gym.monitoring
E   ImportError: No module named 'gym.monitoring'
____________ ERROR collecting universe/wrappers/tests/test_joint.py ____________
ImportError while importing test module '/usr/local/universe/universe/wrappers/tests/test_joint.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
universe/wrappers/tests/test_joint.py:2: in <module>
    import universe
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
_________ ERROR collecting universe/wrappers/tests/test_time_limit.py __________
ImportError while importing test module '/usr/local/universe/universe/wrappers/tests/test_time_limit.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
universe/wrappers/tests/test_time_limit.py:3: in <module>
    import universe
universe/__init__.py:20: in <module>
    import universe.scoreboard
universe/scoreboard/__init__.py:1: in <module>
    from gym.benchmarks import scoring
E   ImportError: No module named 'gym.benchmarks'
!!!!!!!!!!!!!!!!!!! Interrupted: 7 errors during collection !!!!!!!!!!!!!!!!!!!!
=========================== 7 error in 1.01 seconds ============================
(openai) nannigalaxy@nd:~/Documents/openai/universe$ pip list
Package          Version   Location                                   
---------------- --------- -------------------------------------------
attrs            18.2.0    
autobahn         18.9.2    
Automat          0.7.0     
certifi          2018.8.24 
chardet          3.0.4     
constantly       15.1.0    
docker           3.5.0     
docker-py        1.10.3    
docker-pycreds   0.2.1     
fastzbarlight    0.0.14    
future           0.16.0    
go-vncdriver     0.4.19    
gym              0.9.5     
hyperlink        18.0.0    
idna             2.7       
incremental      17.5.0    
numpy            1.15.1    
Pillow           5.2.0     
pip              18.0      
pyglet           1.3.2     
PyHamcrest       1.9.0     
PyYAML           3.13      
requests         2.10.0    
setuptools       40.2.0    
six              1.11.0    
Twisted          18.7.0    
txaio            18.8.1    
ujson            1.35      
universe         0.21.5    /home/nannigalaxy/Documents/openai/universe
urllib3          1.23      
websocket-client 0.53.0    
wheel            0.31.1    
zope.interface   4.5.0     

OS: Ubuntu 18.04 I been searching for solution all day. any kind of help will be appreciated Thank you