-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: add cdp.resolveRealm
command
#1882
Conversation
e9921cf
to
1567594
Compare
I wonder if instead we should accept realm in BiDi+ and automatically replace it with an execution context id. @sadym-chromium WDYT? |
I think that's pretty clever. +1 |
1567594
to
d252f8e
Compare
Please update title/description |
DOM.resolveNode
CDP command
37bb9b7
to
0bb7241
Compare
@jrandolf can you please elaborate a bit the original issue? Why do you need |
If Puppeteer in BiDi needs to be aware of the CDP
We already have |
@sadym-chromium it’d be nice to avoid many round trips to support a11y queries over bidi+ |
In case of puppeteer + mapper, this will be an internal call, without a roundtrip to the browser. But I'm not sure what is the specific scenario this is required to |
@sadym-chromium it would be more problematic when if we start supporting chromedriver. Also, it's not always desirable to make an async call (due to potential races). I don't have a strong preference for either way.
|
When an A11y query is performed in Puppeteer, we get a backendNodeId. If the query is performed in a sandboxed realm, we need to |
7a8a02f
to
e4c32bc
Compare
DOM.resolveNode
CDP commandcdp.resolveNode
command
cdp.resolveNode
commandcdp.resolveRealm
command
e4c32bc
to
b3b1290
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, but please:
- add an e2e test
- update readme with this command
b3b1290
to
d3207fb
Compare
d3207fb
to
6fb123f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
🤖 I have created a release *beep* *boop* --- ## [0.5.11](chromium-bidi-v0.5.10...chromium-bidi-v0.5.11) (2024-02-23) ### Bug Fixes * add `cdp.resolveRealm` command ([#1882](#1882)) ([08d3e45](08d3e45)) * use better error handling ([#1877](#1877)) ([33536e0](33536e0)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
cdp.resolveRealm
resolves a realm ID to an executionContextId.This is needed for Puppeteer to adopt nodes from ARIA queries.
This is a workaround for https://crbug.com/326258571