Skip to content

layout: Implement the percentage height calculation quirk - #39869

Merged
Loirooriol merged 1 commit into
servo:mainfrom
Loirooriol:percentage-height-quirk
Oct 16, 2026
Merged

Loirooriol merged 1 commit into
servo:mainfrom
Loirooriol:percentage-height-quirk

Conversation

@Loirooriol

@Loirooriol Loirooriol commented Oct 14, 2025 •

Copy link
Copy Markdown
Contributor

https://quirks.spec.whatwg.org/#the-percentage-height-calculation-quirk

In quirks mode, when a percentage in the block axis would resolve against an indefinite size, instead of behaving as auto, it can sometimes iterate the containing block chain to try to find a definite basis.

This patch implements this behavior by adjusting the containing block established for the contents, so no iteration is actually needed.

Testing: various tests improve. These are the remaining failures in /quirks/percentage-height-calculation.html:

/css/css-flexbox/percentage-size-quirks-005.html is now failing because we apply the quirk to stretch. Restricting it to percentages would add too much complexity. This is being discussed in w3c/csswg-drafts#12421

Fixes: #23038
Part of #11709

@Loirooriol Loirooriol added A-layout/inline A-layout/block A-layout/2020 https://github.com/servo/servo/wiki/Layout-2020 T-linux-wpt Do a try run of the WPT labels Oct 14, 2025
@github-actions github-actions Bot removed the T-linux-wpt Do a try run of the WPT label Oct 14, 2025
@github-actions

Copy link
Copy Markdown

🔨 Triggering try run (#18499706860) for Linux (WPT)

@Loirooriol Loirooriol added the T-linux-wpt Do a try run of the WPT label Oct 14, 2025
@github-actions github-actions Bot removed the T-linux-wpt Do a try run of the WPT label Oct 14, 2025
@github-actions

Copy link
Copy Markdown

🔨 Triggering try run (#18500659741) for Linux (WPT)

@github-actions

Copy link
Copy Markdown

Test results for linux-wpt from try job (#18499706860):

Flaky unexpected result (36)
  • OK /IndexedDB/idbfactory_open.any.html
    • FAIL [expected PASS] subtest: Calling open() with version argument 1.5 should not throw.

      assert_equals: version expected 1 but got 9007199254740991
      

  • OK /IndexedDB/idbobjectstore_get.any.html (#38942)
    • FAIL [expected PASS] subtest: Attempts to retrieve a record that doesn't exist

      assert_unreached: unexpected open.success event Reached unreachable code
      

  • FAIL [expected PASS] /_mozilla/css/iframe/hide_and_show.html (#15265)
  • TIMEOUT [expected PASS] /_mozilla/shadow-dom/move-element-with-ua-shadow-tree-crash.html (#39473)
  • OK [expected TIMEOUT] /_webgl/conformance/textures/misc/tex-video-using-tex-unit-non-zero.html (#39735)
    • PASS [expected NOTRUN] subtest: Overall test
    • PASS [expected FAIL] subtest: WebGL test #0
  • OK /_webgl/conformance/textures/misc/texture-upload-size.html (#21770)
    • PASS [expected FAIL] subtest: WebGL test #45
    • PASS [expected FAIL] subtest: WebGL test #47
    • PASS [expected FAIL] subtest: WebGL test #49
    • PASS [expected FAIL] subtest: WebGL test #51
    • FAIL [expected PASS] subtest: WebGL test #53

      assert_true: Texture was smaller than the expected size 2x2 expected true got false
      

    • FAIL [expected PASS] subtest: WebGL test #55

      assert_true: getError expected: INVALID_VALUE. Was NO_ERROR : when calling texSubImage2D with the same texture upload with offset 1, 1 expected true got false
      

    • FAIL [expected PASS] subtest: WebGL test #57

      assert_true: Texture was smaller than the expected size 2x2 expected true got false
      

    • FAIL [expected PASS] subtest: WebGL test #59

      assert_true: getError expected: INVALID_VALUE. Was NO_ERROR : when calling texSubImage2D with the same texture upload with offset 1, 1 expected true got false
      

    • PASS [expected FAIL] subtest: WebGL test #61
    • PASS [expected FAIL] subtest: WebGL test #63
    • And 6 more unexpected results...
  • FAIL [expected PASS] /css/CSS2/css1/c5504-mrgn-l-001.xht (#39542)
  • FAIL [expected PASS] /css/WOFF2/header-totalsfntsize-002.xht
  • FAIL [expected PASS] /css/WOFF2/metadatadisplay-schema-credit-007.xht
  • FAIL [expected PASS] /css/WOFF2/metadatadisplay-schema-description-024.xht
  • FAIL [expected PASS] /css/WOFF2/metadatadisplay-schema-license-009.xht
  • OK /css/css-cascade/layer-font-face-override.html (#35935)
    • FAIL [expected PASS] subtest: @font-face override update with appended sheet 1

      assert_equals: expected "80px" but got "41.45px"
      

    • FAIL [expected PASS] subtest: @font-face override update with appended sheet 2

      assert_equals: expected "80px" but got "41.45px"
      

  • FAIL [expected PASS] /css/css-fonts/font-palette-25.html
  • FAIL [expected PASS] /css/css-tables/paint/table-border-paint-caption-change.html (#38036)
  • OK /css/css-text/i18n/unknown-lang/css-text-line-break-po-loose.html
    • FAIL [expected PASS] subtest: 2030 PER MILLE SIGN may NOT appear at line start if loose

      assert_approx_equals: expected 100 +/- 1 but got 109
      

  • FAIL [expected PASS] /css/css-text/letter-spacing/letter-spacing-211.html (#39600)
  • FAIL [expected PASS] /css/css-text/letter-spacing/letter-spacing-ligatures-001.html
  • FAIL [expected PASS] /css/css-text/white-space/white-space-intrinsic-size-019.html
  • TIMEOUT [expected OK] /fetch/api/redirect/redirect-keepalive.https.any.html (#32153)
    • TIMEOUT [expected PASS] subtest: [keepalive][iframe][load] mixed content redirect; setting up

      Test timed out
      

  • ERROR /fetch/metadata/generated/serviceworker.https.sub.html (#36247)
    • FAIL [expected PASS] subtest: sec-fetch-site - Same origin, no options - registration

      promise_test: Unhandled rejection with value: object "Error: Failed to query for recorded headers."
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/initial-empty-document/load-pageshow-events-window-open.html (#28691)
    • FAIL [expected PASS] subtest: load event does not fire on window.open('about:blank')

      assert_unreached: load should not be fired Reached unreachable code
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/navigation-unload-cross-origin.sub.window.html (#29056)
    • PASS [expected FAIL] subtest: Cross-origin navigation started from unload handler must be ignored
  • OK /html/browsers/browsing-the-web/navigating-across-documents/navigation-unload-same-origin-fragment.html (#20768)
    • FAIL [expected PASS] subtest: Tests that a fragment navigation in the unload handler will not block the initial navigation

      assert_equals: expected "" but got "#fragment"
      

  • OK /html/browsers/history/the-history-interface/traverse_the_history_2.html (#21383)
    • PASS [expected FAIL] subtest: Multiple history traversals, last would be aborted
  • TIMEOUT [expected OK] /html/interaction/focus/the-autofocus-attribute/document-with-fragment-nonexistent.html (#28259)
    • TIMEOUT [expected FAIL] subtest: Autofocus elements in top-level browsing context's documents with non-existent fragments should work.

      Test timed out
      

  • TIMEOUT [expected OK] /html/interaction/focus/the-autofocus-attribute/update-the-rendering.html (#24145)
    • TIMEOUT [expected FAIL] subtest: "Flush autofocus candidates" should be happen before a scroll event and animation frame callbacks

      Test timed out
      

  • OK /html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/allow-scripts-flag-changing-1.html (#39694)
    • PASS [expected FAIL] subtest: Meta refresh is blocked by the allow-scripts sandbox flag at its creation time, not when refresh comes due
  • OK /html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/allow-scripts-flag-changing-2.html (#39703)
    • FAIL [expected PASS] subtest: Meta refresh of the original iframe is not blocked if moved into a sandboxed iframe

      uncaught exception: Error: assert_unreached: The iframe into which the meta was moved must not refresh Reached unreachable code
      

  • ERROR [expected OK] /html/semantics/embedded-content/media-elements/event_timeupdate_noautoplay.html (#25046)
  • OK /html/semantics/forms/form-submission-0/urlencoded2.window.html (#28687)
    • FAIL [expected PASS] subtest: application/x-www-form-urlencoded: Basic test (normal form)

      assert_equals: expected "basic=test" but got ""
      

  • OK /html/webappapis/user-prompts/print-during-unload.html (#35944)
    • PASS [expected FAIL] subtest: print() during unload
  • OK /preload/prefetch-document.html (#37210)
    • FAIL [expected PASS] subtest: different-site document prefetch with 'as=document' should not be consumed

      assert_equals: expected 2 but got 1
      

  • FAIL [expected PASS] /shadow-dom/shadow-style-invalidation-vw-units.html (#38468)
  • OK [expected TIMEOUT] /webmessaging/with-ports/018.html (#24485)
    • PASS [expected TIMEOUT] subtest: origin of the script that invoked the method, javascript:
  • TIMEOUT [expected OK] /webstorage/localstorage-about-blank-3P-iframe-opens-3P-window.partitioned.html (#29053)
    • TIMEOUT [expected PASS] subtest: StorageKey: test 3P about:blank window opened from a 3P iframe

      Test timed out
      

  • OK [expected ERROR] /webxr/render_state_update.https.html (#27535)
Stable unexpected results that are known to be intermittent (26)
  • OK /IndexedDB/idbcursor-continuePrimaryKey-exceptions.any.worker.html (#39277)
    • FAIL [expected PASS] subtest: IDBCursor continuePrimaryKey() on object store cursor

      assert_throws_dom: continuePrimaryKey() should throw if source is not an index function "function() {
              cursor.continuePrimaryKey(2, 2);
            }" threw object "TypeError: cursor.continuePrimaryKey is not a function" that is not a DOMException InvalidAccessError: property "code" is equal to undefined, expected 15
      

  • OK /IndexedDB/idbobjectstore_getAll.any.html (#39276)
    • PASS [expected FAIL] subtest: Get all values with transaction.commit()
  • OK /IndexedDB/key-conversion-exceptions.any.html (#39305)
    • FAIL [expected PASS] subtest: IDBCursor continue() method with throwing/invalid keys

      assert_throws_exactly: key conversion with throwing getter should rethrow function "() => {
            receiver[method](key);
          }" threw object "TypeError: receiver[method] is not a function" but we expected it to throw object "getter: throwing from getter"
      

  • OK /IndexedDB/key-conversion-exceptions.any.worker.html (#39284)
    • FAIL [expected PASS] subtest: IDBCursor continue() method with throwing/invalid keys

      assert_throws_exactly: key conversion with throwing getter should rethrow function "() => {
            receiver[method](key);
          }" threw object "TypeError: receiver[method] is not a function" but we expected it to throw object "getter: throwing from getter"
      

  • FAIL [expected PASS] /_mozilla/gfx-rs-gecko/descriptor-ranges.html (#23258)
  • FAIL [expected PASS] /_mozilla/mozilla/sslfail.html (#10760)
  • TIMEOUT [expected OK] /_mozilla/mozilla/window_resize_event.html (#36741)
    • TIMEOUT [expected PASS] subtest: Popup onresize event fires after resizeTo

      Test timed out
      

  • TIMEOUT [expected FAIL] /dom/xslt/large-cdata.html (#38029)
  • OK /fetch/metadata/generated/css-font-face.https.sub.tentative.html (#32732)
    • PASS [expected FAIL] subtest: sec-fetch-user
  • OK /fetch/metadata/generated/css-font-face.sub.tentative.html (#34624)
    • PASS [expected FAIL] subtest: sec-fetch-storage-access - Not sent to non-trustworthy cross-site destination
  • CRASH [expected TIMEOUT] /html/anonymous-iframe/indexeddb.tentative.https.window.html (#39254)
  • OK /html/browsers/browsing-the-web/navigating-across-documents/005.html (#27062)
    • FAIL [expected PASS] subtest: Link with onclick navigation and href navigation

      assert_equals: expected "href" but got "click"
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/008.html (#24456)
    • FAIL [expected PASS] subtest: Link with onclick form submit to javascript url and href navigation

      assert_equals: expected "href" but got "click"
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/empty-iframe-load-event.html (#29066)
    • PASS [expected FAIL] subtest: Check execution order on load handler
    • PASS [expected FAIL] subtest: Check execution order from nested timeout
  • OK /html/browsers/windows/embedded-opener-remove-frame.html (#23867)
    • FAIL [expected PASS] subtest: opener of discarded auxiliary browsing context

      assert_object_equals: property "get" expected function "function opener() {
          [native code]
      }" got function "function opener() {
          [native code]
      }"
      

  • TIMEOUT /html/interaction/focus/the-autofocus-attribute/supported-elements.html (#24145)
    • PASS [expected NOTRUN] subtest: Non-HTMLElement should not support autofocus
    • FAIL [expected NOTRUN] subtest: Host element with delegatesFocus should support autofocus

      assert_equals: expected Element node <div autofocus=""></div> but got Element node <body><div autofocus=""></div></body>
      

    • TIMEOUT [expected NOTRUN] subtest: Host element with delegatesFocus including no focusable descendants should be skipped

      Test timed out
      

  • OK [expected TIMEOUT] /html/semantics/embedded-content/the-iframe-element/iframe_sandbox_navigate_other_frame_popup.sub.html (#39702)
    • FAIL [expected TIMEOUT] subtest: Sandboxed iframe can not navigate other frame's popup

      assert_equals: expected "cannot navigate" but got "can navigate"
      

  • OK [expected CRASH] /html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_escaping-3.html (#24057)
  • CRASH [expected OK] /html/semantics/embedded-content/the-iframe-element/iframe_sandbox_popups_nonescaping-1.html (#24066)
  • OK /html/semantics/forms/form-submission-0/multipart-formdata.window.html (#28725)
    • PASS [expected FAIL] subtest: multipart/form-data: Basic test (normal form)
  • OK /html/semantics/forms/form-submission-0/text-plain.window.html (#28687)
    • PASS [expected FAIL] subtest: text/plain: Basic test (normal form)
  • OK [expected CRASH] /html/semantics/forms/the-fieldset-element/disabled-003.html (#31730, #39631)
  • OK /preload/preload-error.sub.html (#37177)
    • FAIL [expected PASS] subtest: success (fetch): main

      assert_greater_than: http://web-platform.test:8000/preload/resources/dummy.xml?label=fetch should be loaded expected a number greater than 0 but got 0
      

    • PASS [expected FAIL] subtest: CORS (fetch): main
  • OK /trusted-types/trusted-types-navigation.html?21-25 (#38997)
    • FAIL [expected PASS] subtest: Navigate a window via form-submission with javascript:-urls in enforcing mode.

      promise_test: Unhandled rejection with value: "Unexpected message received: \"No securitypolicyviolation reported!\""
      

  • OK /trusted-types/trusted-types-navigation.html?26-30 (#38807)
    • FAIL [expected PASS] subtest: Navigate a window via form-submission with javascript:-urls in report-only mode.

      promise_test: Unhandled rejection with value: "Unexpected message received: \"No securitypolicyviolation reported!\""
      

  • TIMEOUT [expected OK] /webdriver/tests/classic/perform_actions/navigation.py (#38822)
Stable unexpected results (4)
  • PASS [expected FAIL] /css/CSS2/normal-flow/float-percentage-resolution-quirks-mode.html
  • FAIL [expected PASS] /html/rendering/widgets/the-select-element/option-add-label-quirks.html
  • OK /quirks/percentage-height-calculation.html
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, #foo { height:100px } #test { height:100% }<div id=foo><div><div id=test></div></div></div>
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, #foo { height:100px } #test { height:100%; position:relative }<div id=foo><div><div id=test></div></div></div>
    • FAIL [expected PASS] subtest: The percentage height calculation quirk, #foo { height:100px } #test { height:5px; height:calc(100% + 1px) }<div id=foo><div><div id=test></div></div></div>

      assert_equals: quirks mode expected "0px" but got "101px"
      

    • PASS [expected FAIL] subtest: The percentage height calculation quirk, body { margin:0 } #test { height:100% }<div id=test></div>
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, body { height:100%; margin:10px } #test { height:100% }<div id=test></div>
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, body { height:100%; padding:10px } #test { height:100% }<div id=test></div>
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, body { height:100%; border:10px solid } #test { height:100% }<div id=test></div>
    • FAIL [expected PASS] subtest: The percentage height calculation quirk, body { margin:110px 0 } #test { height:100% }<div id=test></div>

      assert_equals: quirks mode expected "0px" but got "200px"
      

    • PASS [expected FAIL] subtest: The percentage height calculation quirk, <html xmlns="{html}"><head><style>#test { height:100% }</style></head><body/><div id="test"/></html>
    • PASS [expected FAIL] subtest: The percentage height calculation quirk, <html xmlns="{html}"><head><style>#test { height:100% }</style></head><span><body><div id="test"/></body></span></html>
    • And 3 more unexpected results...
  • PASS [expected FAIL] /quirks/percentage-height-quirk-excludes-flex-grid-002.html

@github-actions

Copy link
Copy Markdown

⚠️ Try run (#18499706860) failed.

@mrobinson

Copy link
Copy Markdown
Member

@Loirooriol It looks like this improved things quite a bit. Would you be willing to rebase this and update expected test results?

@Loirooriol
Loirooriol force-pushed the percentage-height-quirk branch from a02e380 to a553b4e Compare October 15, 2026 22:28
@Loirooriol Loirooriol added the T-linux-wpt Do a try run of the WPT label Oct 15, 2026
@github-actions github-actions Bot removed the T-linux-wpt Do a try run of the WPT label Oct 15, 2026
@github-actions

Copy link
Copy Markdown

🔨 Triggering try run (#38817496058) for Linux (WPT)

@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

🤖 Opened new upstream WPT pull request (web-platform-tests/wpt#63742) with upstreamable changes.

@Loirooriol
Loirooriol force-pushed the percentage-height-quirk branch from a553b4e to 518a643 Compare October 15, 2026 22:40
@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#63742) title and body.

@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#63742).

@Loirooriol
Loirooriol force-pushed the percentage-height-quirk branch from 518a643 to 82be464 Compare October 15, 2026 22:54
@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#63742).

@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#63742) title and body.

@github-actions

Copy link
Copy Markdown

Test results for linux-wpt from try job (#38817496058):

Flaky unexpected result (20)
  • CRASH [expected OK] /IndexedDB/idbcursor_delete_objectstore.any.html
  • CRASH [expected OK] /content-security-policy/gen/top.http-rp/script-src-self/worker-import.http.html
  • OK /css/CSS2/linebox/inline-negative-margin-001.html (#43763)
    • FAIL [expected PASS] subtest: [data-expected-height] 3

      assert_equals: 
      <div class="w4" data-expected-height="10">123 <span style="margin-left: -4ch">1234 </span></div>
      height expected 10 but got 20
      

    • FAIL [expected PASS] subtest: [data-expected-height] 4

      assert_equals: 
      <div class="w4" data-expected-height="10">123 <span style="margin-left: -4ch">123 </span></div>
      height expected 10 but got 20
      

    • FAIL [expected PASS] subtest: [data-expected-height] 5

      assert_equals: 
      <div class="w4" data-expected-height="10"><img class="w4"><span style="margin-left: -4ch">123</span></div>
      height expected 10 but got 20
      

    • FAIL [expected PASS] subtest: [data-expected-height] 6

      assert_equals: 
      <div class="w4" data-expected-height="10"><img class="w5"><span style="margin-left: -5ch">123</span></div>
      height expected 10 but got 20
      

    • FAIL [expected PASS] subtest: [data-expected-height] 8

      assert_equals: 
      <div class="w4" data-expected-height="10"><img class="w4"><img class="w1" style="margin-left: -1ch"></div>
      height expected 10 but got 20
      

    • FAIL [expected PASS] subtest: [data-expected-height] 10

      assert_equals: 
      <div class="w4" data-expected-height="10"><img class="w5"><img class="w1" style="margin-left: -2ch"></div>
      height expected 10 but got 20
      

  • FAIL [expected PASS] /css/css-backgrounds/background-size-042.html
  • OK /css/css-text-decor/parsing/text-decoration-inset-computed.html (#47617)
    • FAIL [expected PASS] subtest: Property text-decoration-inset value '0'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '0px 0px'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '0.5em'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '-1em'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '-1ch -1ch'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '1px 2px'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '1ch -1ch'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value 'calc(1em / 4) calc(-1ch)'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value 'auto'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • FAIL [expected PASS] subtest: Property text-decoration-inset value '10%'

      assert_true: text-decoration-inset doesn't seem to be supported in the computed style expected true got false
      

    • And 5 more unexpected results...
  • OK /dom/nodes/moveBefore/iframe-document-preserve.window.html (#43152)
    • FAIL [expected PASS] subtest: moveBefore(): cross-origin iframe is preserved: remove self via innerHTML

      assert_equals: iframe does not fire a second load event expected 1 but got 0
      

  • OK /fetch/h1-parsing/h1-parsing.tentative.html?include=before-reason
    • FAIL [expected PASS] subtest: HTAB at <before-reason> should fetch without an error

      promise_test: Unhandled rejection with value: object "TypeError: Network error: HTTP failure: client error (SendRequest)"
      

  • OK /fetch/h1-parsing/h1-parsing.tentative.html?include=in-value
    • FAIL [expected PASS] subtest: SP at <in-value> should fetch without an error

      promise_test: Unhandled rejection with value: object "TypeError: Network error: HTTP failure: client error (SendRequest)"
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/replace-before-load/a-click.html (#28697)
    • PASS [expected FAIL] subtest: aElement.click() before the load event must NOT replace
  • OK /html/browsers/browsing-the-web/navigating-across-documents/replace-before-load/window-open-popup.html (#47829, #47850)
    • FAIL [expected PASS] subtest: No replace before load, triggered by window.open() on a non-_self window

      promise_test: Unhandled rejection with value: object "SecurityError: Location's relevant Document is not same origin-domain with the entry settings object's origin"
      

  • CRASH [expected OK] /html/browsers/sandboxing/sandbox-initial-empty-document-toward-same-origin.html (#35948)
  • TIMEOUT /html/semantics/embedded-content/media-elements/autoplay-disabled-by-permissions-policy.https.sub.html (#46012, #46804)
    • TIMEOUT [expected PASS] subtest: Permissions-Policy header: autoplay "none" has no effect on the top level document.

      Test timed out
      

  • OK /html/semantics/embedded-content/media-elements/media_fragment_seek.html (#24114)
    • FAIL [expected PASS] subtest: Video should seek to time specified in media fragment syntax

      assert_equals: expected 3 but got 0
      

  • OK /html/semantics/forms/form-submission-0/jsurl-form-submit.tentative.html (#36489)
    • PASS [expected FAIL] subtest: Verifies that form submissions scheduled inside javascript: urls take precedence over the javascript: url's return value.
  • TIMEOUT [expected OK] /html/user-activation/navigation-state-reset-sameorigin.html (#45151)
    • TIMEOUT [expected FAIL] subtest: Post-navigation state reset.

      Test timed out
      

  • OK /mixed-content/tentative/autoupgrades/mixed-content-cors.https.sub.html (#41123)
    • FAIL [expected PASS] subtest: Cross-Origin audio should get upgraded even if CORS is set

      assert_equals: Length of other host audio is correct expected 1 but got Infinity
      

  • TIMEOUT [expected OK] /pointerevents/compat/pointerevent_touch-action_two-finger_interaction.html
    • NOTRUN [expected PASS] subtest: touch two-finger pan on 'touch-action: pan-x pan-y'
    • NOTRUN [expected FAIL] subtest: touch two-finger pan on 'touch-action: pinch-zoom'
  • OK /resource-timing/buffer-full-add-then-clear.html (#40819)
    • PASS [expected FAIL] subtest: Test that if the buffer is cleared after entries were added to the secondary buffer, those entries make it into the primary one
  • OK /webdriver/tests/classic/element_click/navigate.py (#47582)
    • FAIL [expected PASS] subtest: test_numbers_link

      AssertionError: assert 'https://web-platform.test:8443/webdriver/tests/support/inline.py?doc=%3C%21doctype+html%3E%0A%3Cmeta+charset%3DUTF-8%3E%0A%3Ca+href%3D%2Fwebdriver%2Ftests%2Fclassic%2Felement_click%2Fsupport%2Finput.html%3E123456%3C%2Fa%3E&mime=text%2Fhtml&charset=UTF-8' == 'https://web-platform.test:8443/webdriver/tests/classic/element_click/support/input.html'
      

  • OK /webdriver/tests/classic/perform_actions/pointer_mouse.py
    • FAIL [expected PASS] subtest: test_down_closes_browsing_context[without up]

      Failed: DID NOT RAISE <class 'webdriver.error.NoSuchWindowException'>
      

Stable unexpected results that are known to be intermittent (10)
  • OK /css/css-fonts/variations/at-font-face-font-matching.html (#20684)
    • FAIL [expected PASS] subtest: Matching font-weight: '399' should prefer '450 460' over '500 501'

      assert_equals: Unexpected font on test element expected 487 but got 532
      

  • TIMEOUT /html/browsers/history/the-history-interface/001.html (#12580)
    • PASS [expected FAIL] subtest: traversing history must also traverse hash changes
  • TIMEOUT [expected OK] /html/semantics/embedded-content/media-elements/autoplay-allowed-by-permissions-policy.https.sub.html (#46803)
    • TIMEOUT [expected PASS] subtest: Permissions-Policy header: autoplay * allows same-origin iframes.

      Test timed out
      

  • TIMEOUT /html/semantics/embedded-content/media-elements/autoplay-default-permissions-policy.https.sub.html (#46805)
    • TIMEOUT [expected PASS] subtest: Default "autoplay" feature policy ["self"] allows the top-level document.

      Test timed out
      

  • OK [expected CRASH] /html/semantics/forms/form-submission-0/form-submit-iframe-then-location-navigate.html (#29634)
    • FAIL [expected PASS] subtest: Verifies that location navigations take precedence when following form submissions.

      assert_equals: expected "/html/semantics/forms/form-submission-0/resources/location.html" but got "/html/semantics/forms/form-submission-0/resources/form.html"
      

  • OK /html/webappapis/dynamic-markup-insertion/document-write/iframe_005.html (#43671)
    • PASS [expected FAIL] subtest: document.write external script into iframe write back into parent
  • OK /resource-timing/test_resource_timing.https.html (#25216)
    • PASS [expected FAIL] subtest: PerformanceEntry has correct name, initiatorType, startTime, and duration (iframe)
    • PASS [expected FAIL] subtest: PerformanceEntry has correct name, initiatorType, startTime, and duration (img)
    • PASS [expected FAIL] subtest: PerformanceEntry has correct name, initiatorType, startTime, and duration (link)
    • PASS [expected FAIL] subtest: PerformanceEntry has correct name, initiatorType, startTime, and duration (script)
    • PASS [expected FAIL] subtest: PerformanceEntry has correct name, initiatorType, startTime, and duration (xmlhttprequest)
  • OK /sanitizer-api/sanitizer-inert-document.html (#45260)
    • PASS [expected FAIL] subtest: Test whether setHTML loads the image.
    • FAIL [expected PASS] subtest: Test whether setHTMLUnsafe loads the image.

      promise_test: Unhandled rejection with value: "The server observed a request. It shouldn't have."
      

  • OK /user-timing/measure_associated_with_navigation_timing.html (#47273)
    • PASS [expected FAIL] subtest: loadTime plus loadEventEnd to a mark "a" should equal to navigationStart to "a".
  • OK [expected TIMEOUT] /webstorage/localstorage-about-blank-3P-iframe-opens-3P-window.partitioned.html (#29053)
    • FAIL [expected TIMEOUT] subtest: StorageKey: test 3P about:blank window opened from a 3P iframe

      assert_true: about:blank window opened by 3P iframe does not inherit 3P iframe's StorageKey expected true got false
      

Stable unexpected results (3)
  • TIMEOUT [expected OK] /_mozilla/mozilla/window-resize-event.html
    • TIMEOUT [expected PASS] subtest: Popup onresize event fires after resizeTo

      Test timed out
      

  • OK /css/css-flexbox/percentage-size-quirks-004.html
    • PASS [expected FAIL] subtest: Quirks: percentage height against auto parent resolves for top: 50%
  • OK /css/css-flexbox/percentage-size-quirks-005.html
    • FAIL [expected PASS] subtest: Quirks: stretch height against auto parent does not resolve top: 50%

      assert_equals: expected 0 but got 300
      

@github-actions

Copy link
Copy Markdown

⚠️ Try run (#38817496058) failed!

@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#63742) title and body.

1 similar comment
@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

✍ Updated existing upstream WPT pull request (web-platform-tests/wpt#63742) title and body.

@Loirooriol
Loirooriol force-pushed the percentage-height-quirk branch from 82be464 to 4299dae Compare October 15, 2026 23:30
@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

📝 Transplanted new upstreamable changes to existing upstream WPT pull request (web-platform-tests/wpt#63742).

@Loirooriol
Loirooriol marked this pull request as ready for review October 15, 2026 23:43
@Loirooriol
Loirooriol requested a review from mrobinson as a code owner October 15, 2026 23:43
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Oct 15, 2026
@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Oct 16, 2026
https://quirks.spec.whatwg.org/#the-percentage-height-calculation-quirk

In quirks mode, when a percentage in the block axis would resolve against
an indefinite size, instead of behaving as auto, it can sometimes iterate
the containing block chain to try to find a definite basis.

This patch implements this behavior by adjusting the containing block
established for the contents, so no iteration is actually needed.

Signed-off-by: Oriol Brufau <[email protected]>
@Loirooriol
Loirooriol force-pushed the percentage-height-quirk branch from 4299dae to c2a23bf Compare October 16, 2026 12:48
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Oct 16, 2026
@Loirooriol
Loirooriol enabled auto-merge October 16, 2026 12:50
@servo-wpt-sync

Copy link
Copy Markdown
Collaborator

🤖 This change no longer contains upstreamable changes to WPT; closed existing upstream pull request (web-platform-tests/wpt#63742).

@Loirooriol
Loirooriol added this pull request to the merge queue Oct 16, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 16, 2026
Merged via the queue into servo:main with commit 6bde716 Oct 16, 2026
39 checks passed
@Loirooriol
Loirooriol deleted the percentage-height-quirk branch October 16, 2026 13:54
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Oct 16, 2026
@servo-highfive

Copy link
Copy Markdown

Someone thinks this change could be added to the monthly blog post! To help with this, we need someone to answer the following questions: 😄

  1. Who is most impacted by this change: users, Servo developers, embedders, or some other group?
  2. What observable difference does this change make?
  3. What preferences (if any) need to be enabled to observe this difference?
  4. What (if any) specific URLs are affected?

If this change is part of a broader feature/project please make sure the PR description contains a Fixes: #12345 or Part of: #12345 issue reference.

Please add @servo-highfive monthly update answer when answering these questions so the bot notices your answer (or just quote this comment).

Thanks for helping us prepare the monthly blog post! ❤️

@Loirooriol

Copy link
Copy Markdown
Contributor Author

@servo-highfive monthly update answer

  1. Users
  2. In quirks mode, percentage sizes in the block axis are now sometimes allowed to skip some ancestors in order to find a definite basis to be resolved against.
  3. N/A
  4. N/A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-layout/block A-layout/inline A-layout/2020 https://github.com/servo/servo/wiki/Layout-2020 monthly update S-awaiting-review There is new code that needs to be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

100% height on a page with only a iframe does not fill the page

4 participants