Closed Bug 2085461 Opened 1 month ago Closed 24 days ago

[wpt-sync] Sync PR 64029 - WebKit export of https://bugs.webkit.org/show_bug.cgi?id=328198

Categories

(Core :: DOM: Core & HTML, task, P4)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 64029 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/64029
Details from upstream follow.

Anne van Kesteren <annevk@annevk.nl> wrote:

WebKit export of https://bugs.webkit.org/show_bug.cgi?id=328198

WebKit export from bug: Documents with a Document-<!---->Isolation-<!---->Policy are never restored from the back/<!---->forward cache

<pre>
Documents with a Document-Isolation-Policy are never restored from the back/forward cache

Since <a href="https://commits.webkit.org/324033@main">324033@main</a>, with site isolation, a document with a Document-Isolation-Policy is in a
cross-origin isolated process of a browsing context group that isn't. The back/forward cache kept
such a document as any other, but a back/forward navigation only went to the process of the cached
document if that process had the cross-origin mode of the navigation's group, and a process for
documents with a policy counts as cross-origin isolated. So the navigation went to another process
instead. The response's policy then moved it to the group's process for documents with a policy
from that site, which is the cached document's process, and that dropped the cached document and
loaded it again.

A back/forward navigation now goes to the process of the cached document when that process's
cross-origin isolation fits the navigation's group, which
BrowsingContextGroup::canUseProcessForCrossOriginIsolation() decides. A group that isn't
cross-origin isolated can use a process for documents with a policy, and one that is can't. The
old checks allowed the latter, though such a group never has one. The same checks without site
isolation, and the asserts about which processes a group has, now use it too.

Child frames in other processes already came back with their parent, whatever their policy. That
they come back before their parent, firing pageshow while the parent is still in the back/forward
cache, is a separate bug. So the new test asks them about themselves once their parent is back,
rather than having them report their pageshow event to their parent.

WebKit-Bug: <a href="https://bugs.webkit.org/show_bug.cgi?id=328198">https://bugs.webkit.org/show_bug.cgi?id=328198</a>
WebKit-Canonical-Link: <a href="https://commits.webkit.org/324262@main">https://commits.webkit.org/324262@main</a>
</pre>

Component: web-platform-tests → DOM: Core & HTML
Product: Testing → Core

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 44 tests and 8 subtests

Status Summary

Firefox

OK : 2[GitHub] 40[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
PASS : 6[GitHub] 155[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]
FAIL : 8[GitHub] 67[Gecko-android-em-14-x86_64-debug-geckoview, Gecko-android-em-14-x86_64-lite-opt-geckoview, Gecko-android-em-14-x86_64-opt-geckoview, Gecko-linux2404-64-debug, Gecko-linux2404-64-opt, Gecko-windows11-32-25h2-debug, Gecko-windows11-32-25h2-opt, Gecko-windows11-64-25h2-debug, Gecko-windows11-64-25h2-opt]

Chrome

OK : 2
PASS : 14

Safari

OK : 2
PASS : 4
FAIL : 8
PRECONDITION_FAILED: 2

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

Tests Disabled in Gecko Infrastructure

Status: NEW → RESOLVED
Closed: 24 days ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.