3

chromedriver.exe file is in the folder it works.

the version is 80.0.3987.116. also the chrome's version is 80.0.3987.116.

driver = webdriver.Chrome()

this doesn't work. with that error message.

WebDriverException: Message: unknown error: DevToolsActivePort file doesn't exist

I thought this error is because of updating chrome hours ago

Then I changed my code with chromeoptions

chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument("--headless")
chrome_options.add_argument("--no-sandbox")
chrome_options.add_argument('--disable-dev-shm-usage')
chrome_options.add_argument("--remote-debugging-port=9222")
driver = webdriver.Chrome('chromedriver', options= chrome_options)

also doesn't work with another error.

SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 80

The version is matched with chrome version.

I tried installing a different version of chromedriver and got the same error.

SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 79

how can i fix it?

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352
Mingu Hyun
  • 45
  • 1
  • 4

2 Answers2

1

This error message...

SessionNotCreatedException: Message: session not created: This version of ChromeDriver only supports Chrome version 80

...implies that the ChromeDriver v80 was unable to initiate/spawn a new Browsing Context i.e. Chrome Browser where is version is other then 80.0.


Your main issue is the incompatibility between the version of the binaries you are using as follows:

  • You mentioned about using chromedriver=80 and chrome=80 but somehow while your program execution ChromeDriver other then v80 is being invoked.
  • So, it's quite evident your have other versions of ChromeDriver other then chromedriver=81.0 present within your system and is present within the system PATH variable which gets invoked while you:

    driver = webdriver.Chrome()
    

Solution

The easiest solution will be to override the default chromedriver binary location with chromedriver v80.0 binary location as follows:

from selenium import webdriver

driver = webdriver.Chrome(executable_path='/path/to/chromedriver')
driver.get('http://google.com/')

Reference

You can find a couple of relevant discussions in:

undetected Selenium
  • 183,867
  • 41
  • 278
  • 352
0

I solved this error by updating the Chrome Webdriver version using - https://chromedriver.storage.googleapis.com/index.html?path=80.0.3987.106/ hope it helps !! Thanks.