Closed lacell75 closed 7 months ago
Please note that a deep selector is not part of the WebDriver specification but special to webdriver.io. As such I'm not sure what specifically this command is doing to retrieve requested elements.
Do you have a chance to create a minimized HTML page which reproduces the problem for you? When I check the changes for Marionette in Firefox 109 nothing actually is visible to me which could have caused a different behavior.
I actually was able to finally reproduce myself. Thanks a lot for the report! I filed an internal issue that can be found at: https://bugzilla.mozilla.org/show_bug.cgi?id=1824664.
As it looks like it is more a Firefox issue and not particular to our WebDriver implementation.
Great news!!
@whimboo I've run into the same issue and reported it here: https://github.com/webdriverio/webdriverio/issues/11360
I've run into the issue while testing a web application that is built using adobe spectrum web components.
@muhqu would you mind commenting on the before mentioned bug so that we know that others are affected as well? I might have to take another look at this. Thanks.
I would like to note that we encountered this problem while testing Vaadin webcomponents too. Actually, the problem is reproducible even with a very basic webcomponent that uses slots. I've prepared the following demonstration project, where you can reproduce it quite easily: https://github.com/bwajtr/selenium-firefox-gettext-webcomponents
Yes, we are aware and this issue was actually filed because Vaadin components have this problem. See the very first comment. But thanks a lot for the simplified testcase which demonstrates that this is an issue when using slot
.
@lacell75, @muhqu and @bwajtr would you be so kind helping us to test the fix that I have in place to fix this issue? I pushed test builds for verification and from our side it looks all fine. It would be great to also get some feedback from consumers of WebDriver.
Builds for all platforms can be found at: https://treeherder.mozilla.org/jobs?repo=try&revision=2822e80fcd2624eea0fbe203bc22a3af864dae10&searchStr=build
Just click the Ba
link of your platform and select Artifacts and Debugging Tools
in the below pane. There look out for target.tar.gz
for Linux, or target.zip
for Windows, or target.dmg
for MacOS. Just unzip/mount the file and you can directly run Firefox without installation.
Thanks!
PS: Note that the Selenium atoms have bugs around getting the element text from closed shadow root. If you make use of that it will no longer work in Firefox similar to other browsers, and I'm going to help fixing it over on https://github.com/SeleniumHQ/selenium/issues/13132.
@lacell75, @muhqu and @bwajtr would you be so kind helping us to test the fix that I have in place to fix this issue? I pushed test builds for verification and from our side it looks all fine. It would be great to also get some feedback from consumers of WebDriver.
Builds for all platforms can be found at: https://treeherder.mozilla.org/jobs?repo=try&revision=2822e80fcd2624eea0fbe203bc22a3af864dae10&searchStr=build
Just click the
Ba
link of your platform and selectArtifacts and Debugging Tools
in the below pane. There look out fortarget.tar.gz
for Linux, ortarget.zip
for Windows, ortarget.dmg
for MacOS. Just unzip/mount the file and you can directly run Firefox without installation.Thanks!
PS: Note that the Selenium atoms have bugs around getting the element text from closed shadow root. If you make use of that it will no longer work in Firefox similar to other browsers, and I'm going to help fixing it over on SeleniumHQ/selenium#13132.
Sure. I will test the fix on Monday. Thanks a lot for the job!
@whimboo well done. This version works correctly, the test is passed now.
Good to know and thanks for the verification! I just triggered the landing of the patch and a fix will be in tomorrow's Nightly build of Firefox 122.
@whimboo I can also confirm that with the provided nightly build of Firefox 122 my tests are now passing. Thanks a lot!
System
Testcase
What happened? Since firefox 109, getElementText with deep selector on shadow root returns an empty string. According to the driver logs, WebDriver:GetElementText returns "" but if we look the html , the text in the element is present but in a sub element (span) : [0-0] New task
I don't understand why this behavior is now different from version 109 of firefox. I need help.
What is your expected behavior? Return all text of shadow like on firefox 108 or chrome
Refer the webdriver ISSUE: #9876 You can reproduce with this repo : https://github.com/lacell75/cucumber-boilerplate/tree/issue9876 . Launch this feature : https://github.com/lacell75/cucumber-boilerplate/blob/issue9876/issue9876.feature
or with webdriver.IO API
Stacktrace
Trace-level log
wdio-geckodriver.log