Closed Bug 1893922 Opened 22 days ago Closed 13 days ago

browsingContext.locateNodes does not accept document as a start node for a11y locator

Categories

(Remote Protocol :: WebDriver BiDi, defect, P2)

defect
Points:
2

Tracking

(firefox127 fixed)

RESOLVED FIXED
127 Branch
Tracking Status
firefox127 --- fixed

People

(Reporter: alexrudenko, Assigned: Sasha)

References

(Blocks 1 open bug)

Details

(Whiteboard: [webdriver:m11])

Attachments

(1 file, 1 obsolete file)

When a document Node is given as a start node to locateNodes using a11y attributes the following exception happens in Firefox:

{"id":23,"method":"browsingContext.locateNodes","params":{"context":"97facb40-923b-44c3-84ff-0acad846b0e4","locator":{"type":"accessibility","value":{"role":"heading"}},"startNodes":[{"type":"node","handle":"234bf83b-7ab5-458b-8c07-24400ed8d9c7","sharedId":"88005127-e365-4624-9ae5-dcc481d661cd","value":{"nodeType":9,"childNodeCount":1}}]}}

ProtocolError: Protocol error (browsingContext.locateNodes): unknown error TypeError: can't access property "getState", documentAccessible is null waitForDocumentAccessibility@chrome://remote/content/shared/webdriver/Accessibility.sys.mjs:103:3
accessibility.getAccessible@chrome://remote/content/shared/webdriver/Accessibility.sys.mjs:139:9
accessibility.getComputedRole@chrome://remote/content/shared/webdriver/Accessibility.sys.mjs:192:42
#collectNodesUsingAccessibilityAttributes@chrome://remote/content/webdriver-bidi/modules/windowglobal/browsingContext.sys.mjs:72:47
#locateNodesUsingAccessibilityAttributes@chrome://remote/content/webdriver-bidi/modules/windowglobal/browsingContext.sys.mjs:162:58
_locateNodes@chrome://remote/content/webdriver-bidi/modules/windowglobal/browsingContext.sys.mjs:537:76
handleCommand@chrome://remote/content/shared/messagehandler/MessageHandler.sys.mjs:255:33
receiveMessage@chrome://remote/content/shared/messagehandler/transports/js-window-actors/MessageHandlerFrameChild.sys.mjs:78:37

The test in Puppeteer is "AriaQueryHandler parseAriaSelector should find button".
Example failure is https://github.com/puppeteer/puppeteer/actions/runs/8815323613/job/24197052210?pr=12315#step:10:566

Blocks: 1855020
Severity: -- → S3
Points: --- → 2
Priority: -- → P2
Whiteboard: [webdriver:m11]
Assignee: nobody → aborovova
Status: NEW → ASSIGNED
Attachment #9400486 - Attachment is obsolete: true
Pushed by aborovova@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5b089e48562f
[bidi] Align "browsingContext.locateNodes" command with the argument "type" equal "accessibility" with the spec changes. r=webdriver-reviewers,whimboo
Status: ASSIGNED → RESOLVED
Closed: 13 days ago
Resolution: --- → FIXED
Target Milestone: --- → 127 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: