Docker-selenium: Element is not clickable at point - Scroll to click now mandatory?

Created on 13 Sep 2017  路  14Comments  路  Source: SeleniumHQ/docker-selenium

Meta -

Image(s): selenium/standalone-chrome
Docker-Selenium Image Version(s): 3.5.3
OS: OSX 10.11

Seems that 3.5.3 changed the behavior of clicking an element that you have to scroll down to see.

Code to reproduce (clicking the : "Chat Live Now" at the bottom of the page http://www.internap.com/)

# Python 2.7
# docker==2.5.1
# selenium==3.5.0
# retry==0.9.2

import docker
from retry.api import retry_call
from selenium import webdriver

def test_click_offscreen(version):
    selenium_container = None

    try:
        client = docker.from_env()
        selenium_container = client.containers.run("selenium/standalone-chrome:{}".format(version),
                                                   name="selenium-chrome",
                                                   detach=True,
                                                   ports={'4444/tcp': 31864})

        chrome = retry_call(webdriver.Remote, tries=10, delay=1, fkwargs=dict(
            command_executor="http://0.0.0.0:31864/wd/hub",
            desired_capabilities={
                'platform': 'ANY',
                'browserName': 'chrome',
                'chrome.binary': '/usr/bin/chromium-browser',
                'javascriptEnabled': True,
                'chrome.switches': ["--ignore-certificate-errors"]
            }))

        chrome.get("http://www.internap.com/")

        button = chrome.find_element_by_class_name('chat-web')

        button.click()
        return "GOOD!"
    except Exception as e:
        return "NOPE: {}".format(e)
    finally:
        if selenium_container:
            selenium_container.remove(force=True)


print("TESTING 3.5.2 : " + test_click_offscreen("3.5.2"))
print("TESTING 3.5.3 : " + test_click_offscreen("3.5.3"))

will print

TESTING 3.5.2 : GOOD!
TESTING 3.5.3 : NOPE: Message: unknown error: Element is not clickable at point (81, 3716)
  (Session info: chrome=61.0.3163.79)
  (Driver info: chromedriver=2.31.488763 (092de99f48a300323ecf8c2a4e2e7cab51de5ba8),platform=Linux 4.9.46-moby x86_64)

Expected Behavior -

If an element is not visible on screen but is visible on the page i would expect the driver to click it anyway.

This behavior is present in 3.5.2

Actual Behavior -

The error Message: unknown error: Element is not clickable at point (81, 3716) is returned.

Most helpful comment

This issue should be fixed when upgrading to chromedriver 2.32, mentioned on 560

Chromedriver bug is here

All 14 comments

Same issue occuring here in Chrome debug in 3.5.3. Not had the issue in previous versions.

I'm having the same issue as well. Broke a lot of my UI automation scripts for RT... Does anyone know a turnaround? I've tried forcing the scroll but it does nothing.

This issue should be fixed when upgrading to chromedriver 2.32, mentioned on 560

Chromedriver bug is here

@derinbay thank you! I upgraded the chromedriver after updating browser. Not sure why it didn't pick it up last time. I've just downloaded it again and rebooted my machine. It's working now with selenium 3.5.3.

That's great but the problem stays for this version. Since i'm using the remote driver it uses the driver in the docker image.

The docker image selenium/standalone-chrome:3.5.3 derives from selenium/node-chrome:3.5.3 which uses driver 2.31

https://hub.docker.com/r/selenium/node-chrome/~/dockerfile/

...
ARG CHROME_DRIVER_VERSION=2.31
...

So would that mean the 3.5.3 chrome image is not compatible with itself?

@lindycoder You're right, You cannot use this image. We're waiting for an updated image as well. I turned back to 3.4.0 image on our systems by the way.

@derinbay cool, for my part 3.5.2 seems fine for my needs

This was already released with 3.5.3-boron, as mentioned in #560.

Feel free to reopen in case the issue was not solved.

I am still seeing this problem even after upgrading to 2.34. Note that my project requires the use of PyVirtualDisplay.

Environment:
chrome=63.0.3239.108
Driver info: chromedriver=2.34.522913
ubuntu 16.04 LTS
Python 3.6.3
PyVirtualDisplay (0.2.1)

Traceback (most recent call last): <snip> selenium.common.exceptions.WebDriverException: Message: unknown error: Element <button aria-label="... opens pop up" class="actionable actionable_button actionable_full-width actionable_large-button actionable_no-outline actionable_prefix actionable_secondary-dark-affix" type="button" data-a=" ... ">...</button> **is not clickable at point (494, 436). Other element would receive the click:** <h2 class=" ... " id="heading-11">...</h2> (Session info: chrome=63.0.3239.108) (Driver info: chromedriver=2.34.522913 (36222509aa6e819815938cbf2709b4849735537c),platform=Linux 4.10.0-42-generic x86_64)

Hey i have this issue too, but in my case some shitty overlay comes up, i put this in as workaround, but when i run headless throws the erro.

> time.sleep(10) pyautogui.press('esc') #escape overlay time.sleep(3)

headless,
^[('element not visible\n (Session info: headless chrome=63.0.3239.108)\n (Driver info: chromedriver=2.34.522913 (36222509aa6e819815938cbf2709b4849735537c),platform=Linux 4.13.0-21-generic x86_64)', None, None)

I am getting the same issue for one image element, is not clickable at point (106, 349). Other element would receive the click:
(Session info: chrome=69.0.3497.42)
(Driver info: chromedriver=2.41.578706 (5f725d1b4f0a4acbf5259df887244095596231db),platform=Mac OS X 10.11.6 x86_64)

@vibmish

I've had a problem like this where a checkbox is kind of underneath a

For with fixed it by sending a "space" keypress to the checkbox and we found that only we only had the problem on chrome.

So maybe you could try with a firefox selenium container see if you get the same problem

EDIT: By the way I don't think this problem is related to the scrolling issue

@lindycoder ok thanks

Was this page helpful?
0 / 5 - 0 ratings