Add support for "xpath" strategy for "WebDriver:FindElementFromShadowRoot" and "WebDriver:FindElementsFromShadowRoot" commands
Categories
(Remote Protocol :: Marionette, task, P3)
Tracking
(Not tracked)
People
(Reporter: Sasha, Unassigned)
References
(Blocks 1 open bug)
Details
As soon as shadow root supports xpath search, we should be able to have the support for xpath strategy in WebDriver:FindElementFromShadowRoot and WebDriver:FindElementsFromShadowRoot commands, most likely we would need only to enable the wpt tests: https://searchfox.org/mozilla-central/source/testing/web-platform/tests/webdriver/tests/find_element_from_shadow_root/find.py#156 and https://searchfox.org/mozilla-central/source/testing/web-platform/tests/webdriver/tests/find_elements_from_shadow_root/find.py#157.
| Reporter | ||
Updated•2 years ago
|
Comment 1•2 years ago
|
||
So this is a limitation by the HTML spec, right? Is there maybe any open issue where a discussion for that topic might have happened?
| Reporter | ||
Comment 2•2 years ago
|
||
(In reply to Henrik Skupin [:whimboo][⌚️UTC+1] from comment #1)
So this is a limitation by the HTML spec, right? Is there maybe any open issue where a discussion for that topic might have happened?
I didn't find, unfortunately, anything.
Updated•2 years ago
|
Comment 3•2 years ago
|
||
XPath is deprecated and shouldn't change anymore. https://www.w3.org/TR/DOM-Level-3-XPath/ is also retired and should not be used anymore.
Based on wpt.fyi results all browsers are failing here.
James, shall we add a notice to the appropriate APIs in the WebDriver classic spec that XPath locators will not be supported within ShadowRoot searches? Then we can also close this bug as wontfix.
Comment 4•2 years ago
|
||
I think that's correct per spec at the moment. If there's pushback from WebDriver users (which would be understandable) we should revisit what's possible with the WG.
| Reporter | ||
Updated•2 years ago
|
Comment 5•2 years ago
|
||
Here is the related WebDriver classic specification issue: https://github.com/w3c/webdriver/issues/1610
Description
•