-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Should COOP-related browsing context switch result in nullification of a popup's WindowProxy's window
?
#10457
Comments
This should follow from https://html.spec.whatwg.org/multipage/nav-history-apis.html#window-open-steps. If the document associated with the |
Right, but I think the question is: is there any mechanism that should set |
Exactly, the value in Chromium is asynchronously being set to null, once the response is received. I'll clarify that in the OP. |
The An interesting observation made while writing tests is that it's possible for the So either WebKit as a different chain of causality (e.g. Waiting for WindowProxy update before creating the new document) or this a difference of degree (WebKit IPCs winning the race ften) |
Wait what? And once something is a Or maybe you are talking about |
Chrome implementation for the 3 self referencial attributes (window, self, frames) appears to check the WindowProxy's window still exist before returning itself. WebKit seems to do the same as Chrome fo Firefox: I did not find information. |
That goes against the specification though. And it's not immediately clear to me what the advantage of that is given that the code already has a reference anyway. |
I briefly reviewed the situation. The current WebKit behavior (which Chromium inherited) seems to be a long-standing issue. Yuki attempted to address it in late 2016, but the changes were reverted in early 2017. Adding wpt tests would likely help ensure the behavior aligns with the specification going forward. |
Given the fact that the null check in COOP noopener's WPTs is non-standard [1] and flaky [2], it's better to remove it for now. [1] whatwg/html#10457 [2] #46979 (comment) Bug: 344963946 Change-Id: I0bc0e7d153cc400938079a9d12209f57ea8310fc
Given the fact that the null check in COOP noopener's WPTs is non-standard [1] and flaky [2], it's better to remove it for now. [1] whatwg/html#10457 [2] web-platform-tests/wpt#46979 (comment) Bug: 344963946 Change-Id: I0bc0e7d153cc400938079a9d12209f57ea8310fc Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5687771 Commit-Queue: Yoav Weiss (@Shopify) <yoavweiss@chromium.org> Reviewed-by: Arthur Sonzogni <arthursonzogni@chromium.org> Cr-Commit-Position: refs/heads/main@{#1324852}
Given the fact that the null check in COOP noopener's WPTs is non-standard [1] and flaky [2], it's better to remove it for now. [1] whatwg/html#10457 [2] #46979 (comment) Bug: 344963946 Change-Id: I0bc0e7d153cc400938079a9d12209f57ea8310fc Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5687771 Commit-Queue: Yoav Weiss (@Shopify) <yoavweiss@chromium.org> Reviewed-by: Arthur Sonzogni <arthursonzogni@chromium.org> Cr-Commit-Position: refs/heads/main@{#1324852}
What is the issue with the HTML Standard?
When a document opens a popup (using something like
const popup = window.open(url)
), and that popup requires a browsing context group switch due to COOP enforcement, it's not immediately obvious (to me) what the value ofpopup.window
should be.When adding an assertion on that front to popup-test.js#89, Chromium and WebKit seem to disagree on what that value should be. The value is asynchronously being set to null in Chromium (once the response is received), while remaining a global object in WebKit. This might be a bug in one of them, but it'd be good to clarify the behavior, so that we'd know which needs to be aligned.
Update: clarified that the value is being set async.
/cc @domfarolino @ArthurSonzogni @cdumez
The text was updated successfully, but these errors were encountered: