CharlesPikachu / AIGames

use AI to play some games.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

启动训练小恐龙的时候selenium会读取页面的ERR_INTERNET_DISCONNECTED导致报错

SuperTyrael opened this issue · comments

commented
Traceback (most recent call last):
  File "TRexRush.py", line 50, in <module>
    main()
  File "TRexRush.py", line 40, in main
    game_cotroller = GameController(cfg)
  File "/Users/liam/Desktop/Git/AIGames/AITRexRush/Algorithm_1/modules/gameapis/controller.py", line 30, in __init__
    self.driver.get(cfg.GAME_URL)
  File "/Users/liam/opt/anaconda3/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 333, in get
    self.execute(Command.GET, {'url': url})
  File "/Users/liam/opt/anaconda3/lib/python3.7/site-packages/selenium/webdriver/remote/webdriver.py", line 321, in execute
    self.error_handler.check_response(response)
  File "/Users/liam/opt/anaconda3/lib/python3.7/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_INTERNET_DISCONNECTED
  (Session info: chrome=87.0.4280.88)

这是为啥?

Traceback (most recent call last):
File "C:\AITRexRush\Algorithm_1\TRexRush.py", line 50, in
main()
File "C:\AITRexRush\Algorithm_1\TRexRush.py", line 40, in main
game_cotroller = GameController(cfg)
File "C:\AITRexRush\Algorithm_1\modules\gameapis\controller.py", line 30, in init
self.driver.get(cfg.GAME_URL)
File "C:\AITRexRush\Algorithm_1\venv\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 436, in get
self.execute(Command.GET, {'url': url})
File "C:\AITRexRush\Algorithm_1\venv\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 424, in execute
self.error_handler.check_response(response)
File "C:\AITRexRush\Algorithm_1\venv\lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 247, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: unknown error: net::ERR_INTERNET_DISCONNECTED
(Session info: chrome=97.0.4692.71)

我也不知道为什么,跟你有着一样的问题