Selenium Chromedriver Error Message: u'unknown error: unable to discover open pages

If you use selenium webdriver to automate regression test cases, you may have got the following error. Because a bug in chromedriver version 2.3 causes this error. According to Google Dev., this problem had fixed in version 2.6. 

Assigning the chrome driver to driver leads to this error by the line 38, which is self.driver = webdriver.Chrome(). To solve the problem, you need to change the chromedriver version 2.3 in your execution path, like C:\Windows\System32 under Windows, with newer version. You can download chrome driver from googleapis.

Error message may like this:
Traceback (most recent call last):
  File "D:\workspace\automation_project\", line 32, in <module>
    m = Project(browser, server)
  File "D:\workspace\automation_project\", line 38, in __init__
    self.driver = webdriver.Chrome()
  File "C:\Python27\lib\site-packages\selenium-2.35.0-py2.7.egg\selenium\webdriver\chrome\", line 64, in __init__
  File "C:\Python27\lib\site-packages\selenium-2.35.0-py2.7.egg\selenium\webdriver\remote\", line 72, in __init__
    self.start_session(desired_capabilities, browser_profile)
  File "C:\Python27\lib\site-packages\selenium-2.35.0-py2.7.egg\selenium\webdriver\remote\", line 114, in start_session
    'desiredCapabilities': desired_capabilities,
  File "C:\Python27\lib\site-packages\selenium-2.35.0-py2.7.egg\selenium\webdriver\remote\", line 165, in execute
  File "C:\Python27\lib\site-packages\selenium-2.35.0-py2.7.egg\selenium\webdriver\remote\", line 164, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.WebDriverException: Message: u'unknown error: unable to discover open pages\n  (Driver info: chromedriver=2.3,platform=Windows NT 6.3 x86_64)'

To setup your environment for internet explorer and chrome, you can read this post.


Popular posts from this blog

Testing WEB Sevices and Automating SOAP Services

Performance Testing on CI: Locust is running on Jenkins

Change Default Timeout and Wait Time of Capybara

Performance Testing on CI: Integration of Locust and Jenkins

Create an Alias for Interactive Console Work: Selenium and Capybara