SafariDriver click on a button not working with safari 13.0.1

I am using Selenium 3.141 with SafariDriver included with Safari 13.0.1 (14608.2.11.1.11).

I have problems with interacting with elements, in this case clinking on a button.


1) Create a new SafariDriver

2) Navigate to a page with a button element

3) Find the button element

4) Click on the button element


RESULT: The click is not performed on the button element but any element below the button element.

This is not working from the recent update to safari 13.0.1.

Replies

I also am running into this bug.

As a workaround, I am now using driver.executeScript to simulate the click in javascript.

Although this works, it is obviously not the ideal solution.

I am also experiencing this issue using same steps as above. I've upgraded to 13.0.2; however, it did not resolve issue.

I run into the same issue today so I was wondering whether you have found a solid solution yet appart from @rhpijnacker's solution to fix it.
It also seems to be broken for .getText( ).

Hey team, I run into the same situation some days ago. And some folks too.
I find this https://github.com/webdriverio/webdriverio/issues/4787
where it takes to https://bugs.webkit.org/show_bug.cgi?id=202589but no action are taken.
Please, where can I track the issue that will fix this?, thanks!!

I am amazed to report that the issue has been fixed in "less than 2 years" in Big Sur release.

I upgraded Mac OS to Big Sur and safari to version 15, click is still not working for me. I am executing javascript for click() action.

i am using Big Sur, OS version 14.1 and the click with send keys / click(), jse all these 3 doesnt work . did anyone find a solution to this ?

I also experience the same issue on macOS Monterey 12.2.1, Safari 15.3. Selenium clicks are not performing any actions. Only JS clicks are working.

I also tried running it on Mac Ventura 13.4 with Safari 16.5 and selenium-webdriver 4.8.2, but the click action doesn't work. This issue still persists.

  • Is there any updates on this? I am also facing this issue for my Macbook Air M2 (Mac Ventura 13.4) with Safari 16.5.

Add a Comment

Same here with:

  • Sonoma 14.3.1
  • M3 Pro
  • Safari 17.3.1
  • Selenium 4.18.0

Trying to check/uncheck any of the checkboxes in this public test page (https://the-internet.herokuapp.com/checkboxes), made exactly for this kind of dummy selenium tests, doesn't work. It works on all browsers but Safari.

The only things working in Safari is clicking with js, which is a horrible workaround:

JavascriptExecutor executor = (JavascriptExecutor) webDriver;
executor.executeScript("arguments[0].click();", firstCheckbox);