1 Reply
      Latest reply on Jun 19, 2019 2:27 AM by cnparmar
      bleedblue99 Level 1 Level 1 (0 points)

        I am using explicit wait like below to check if element is clickable.

        WebDriverWait(driver, 30).until( expected_conditions.element_to_be_clickable((By.CSS_SELECTOR, "#search"))) 

        But I get error

         <class 'selenium.common.exceptions.WebDriverException'> Message: The command 'GET /session/.../displayed' was not found. 

        If I use time.sleep() it works fine instead of explicir wait it works fine. I have initialized safari driver as

        from selenium.webdriver import Safari driver = Safari() 

        Here is stacktrace

        File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/support/wait.py", line 71, in until
          value = method(self._driver)
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/support/expected_conditions.py", line 283, in __call__
          element = visibility_of_element_located(self.locator)(driver)
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/support/expected_conditions.py", line 127, in __call__
          return _element_if_visible(_find_element(driver, self.locator))
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/support/expected_conditions.py", line 147, in _element_if_visible
          return element if element.is_displayed() == visibility else False
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/remote/webelement.py", line 490, in is_displayed
          return self._execute(Command.IS_ELEMENT_DISPLAYED)['value']
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/remote/webelement.py", line 628, in _execute
          return self._parent.execute(command, params)
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/remote/webdriver.py", line 314, in execute
          self.error_handler.check_response(response)
          File "/Users/Library/Python/2.7/lib/python/site-packages/selenium/webdriver/remote/errorhandler.py", line 242, in check_response
          raise exception_class(message, screen, stacktrace)
        WebDriverException: Message: The command 'GET /session/7.../displayed' was not found.