[wpt-sync] Sync PR 64357 - Serialize CSSUnparsedValue directly in toString
Categories
(Core :: DOM: CSS Object Model, task, P4)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox162 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 64357 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/64357
Details from upstream follow.
Rune Lillesveen <futhark@chromium.org> wrote:
Serialize CSSUnparsedValue directly in toString
CSSUnparsedValue previously relied on the base CSSStyleValue::toString()
implementation, which converted the object into a CSSValue via
ToCSSValue() and validated declaration-value syntax. When invoked off the
main thread, this entered CSS parser code paths that depend on
main-thread-only data structures.This change overrides CSSUnparsedValue::toString() to serialize segments
and tokens directly per specification, avoiding unnecessary CSS value
conversion and parsing during stringification. In addition, explicit
thread affinity checks are added to ToCSSValue() and
ConsumeUnparsedDeclaration() to ensure declaration parsing remains on
the main thread.Bug: 577378379
Change-Id: I8d0dea7bd85a8153c4bac5598f12c1db5d05f477
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/8668175
Reviewed-by: Kevin Babbitt \<kbabbitt@microsoft.com>
Commit-Queue: Rune Lillesveen \<futhark@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1730961}
| Assignee | ||
Updated•1 month ago
|
| Assignee | ||
Updated•24 days ago
|
| Assignee | ||
Updated•24 days ago
|
| Assignee | ||
Updated•24 days ago
|
| Assignee | ||
Updated•23 days ago
|
| Assignee | ||
Comment 1•23 days ago
|
||
Pushed to try (stability) https://treeherder.mozilla.org/jobs?repo=try&landoInstance=lando-prod-2025&landoCommitID=116102
| Assignee | ||
Comment 2•22 days ago
|
||
CI Results
Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 80 tests and 11 subtests
Status Summary
Firefox
OK : 4[GitHub] 80[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 : 8[GitHub] 953[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 : 187
Chrome
CRASH: 4
Safari
OK : 4
PASS : 8
Links
Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base
Details
New Tests That Don't Pass
- /css/css-typed-om/stylevalue-subclasses/cssColorValue.html [wpt.fyi]
- Parsing the color string "rgb(255,255,255)":
FAIL - Parsing the color string "rgba(100,255,255, 1)":
FAIL - Parsing the color string "#00bfff":
FAIL - Parsing the color string "hsl(195, 100%, 50%)":
FAIL - Parsing the color string "hsla(123, 100%, 20%, .5)":
FAIL - Parsing the color string "hwb(200 31% 38%)":
FAIL - Parsing the color string "hwb(200 31% 38% / 0.5)":
FAIL - Parsing the color string "blue":
FAIL - Parsing the color string "transparent":
FAIL - throwing invalid color string "abcdef:
FAIL - throwing invalid color string "--foo:
FAIL - throwing invalid color string "--bar:
FAIL - throwing invalid color string "abc():
FAIL - throwing invalid color string "initial:
FAIL - throwing invalid color string "inherit:
FAIL - throwing invalid color string "unset:
FAIL - throwing invalid color string "revert:
FAIL - throwing invalid color string "revert-layer:
FAIL - CSSColorValue Tests:
FAIL - CSSColorValue Tests 1:
FAIL
- Parsing the color string "rgb(255,255,255)":
- /css/css-typed-om/stylevalue-subclasses/cssHSL.html [wpt.fyi]
- Constructing a CSSHSL with a number for the hue works as intended.:
FAIL - CSSHSL.h can be updated with a a number.:
FAIL - Constructing a CSSHSL with degrees for the hue works as intended.:
FAIL - CSSHSL.h can be updated with a degrees.:
FAIL - Constructing a CSSHSL with radians for the hue works as intended.:
FAIL - CSSHSL.h can be updated with a radians.:
FAIL - Constructing a CSSHSL with gradians for the hue works as intended.:
FAIL - CSSHSL.h can be updated with a gradians.:
FAIL - Constructing a CSSHSL with undefined for the hue works as intended.:
FAIL - CSSHSL.h can be updated with a undefined.:
FAIL - Constructing a CSSHSL with css pixels for hue throws a SyntaxError.:
FAIL - Constructing a CSSHSL with css em for hue throws a SyntaxError.:
FAIL - CSSHSL can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSHSL can be constructed from four numbers.:
FAIL - Constructing a CSSHSL with CSS.number for s, l or alpha throws a TypeError:
FAIL - Updating a CSSHSL with CSS.number for s throws a SyntaxError:
FAIL - CSSHSL.s can be updated to a number.:
FAIL - CSSHSL.s can be updated with a CSS percent.:
FAIL - Updating a CSSHSL with CSS.number for l throws a SyntaxError:
FAIL - CSSHSL.l can be updated to a number.:
FAIL - CSSHSL.l can be updated with a CSS percent.:
FAIL - Updating a CSSHSL with CSS.number for alpha throws a SyntaxError:
FAIL - CSSHSL.alpha can be updated to a number.:
FAIL - CSSHSL.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSHSL with a number for the hue works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssHWB.html [wpt.fyi]
- Constructing a CSSHWB with degrees for the hue works as intended.:
FAIL - CSSHWB.h can be updated with a degrees.:
FAIL - Constructing a CSSHWB with radians for the hue works as intended.:
FAIL - CSSHWB.h can be updated with a radians.:
FAIL - Constructing a CSSHWB with gradians for the hue works as intended.:
FAIL - CSSHWB.h can be updated with a gradians.:
FAIL - Constructing a CSSHWB with css pixels for hue throws a SyntaxError.:
FAIL - CSSHWB can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSHWB can be constructed from four numbers.:
FAIL - Constructing a CSSHWB with CSS.number for s, l or alpha throws a SyntaxError:
FAIL - Updating a CSSHWB with CSS.number for w throws a SyntaxError:
FAIL - CSSHWB.w can be updated to a number.:
FAIL - CSSHWB.w can be updated with a CSS percent.:
FAIL - Updating a CSSHWB with CSS.number for b throws a SyntaxError:
FAIL - CSSHWB.b can be updated to a number.:
FAIL - CSSHWB.b can be updated with a CSS percent.:
FAIL - Updating a CSSHWB with CSS.number for alpha throws a SyntaxError:
FAIL - CSSHWB.alpha can be updated to a number.:
FAIL - CSSHWB.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSHWB with degrees for the hue works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssLCH.html [wpt.fyi]
- Constructing a CSSLCH with percent for the lightness works as intended.:
FAIL - CSSLCH.l can be updated with a percent.:
FAIL - Constructing a CSSLCH with number for the lightness works as intended.:
FAIL - CSSLCH.l can be updated with a number.:
FAIL - Constructing a CSSLCH with css pixels for lightness throws a SyntaxError.:
FAIL - Constructing a CSSLCH with degrees for lightness throws a SyntaxError.:
FAIL - CSSLCH can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSLCH can be constructed from four numbers.:
FAIL - Constructing a CSSLCH with CSS.number for l, c, h or alpha throws a SyntaxError:
FAIL - Updating a CSSLCH with CSS.number for l throws a SyntaxError:
FAIL - CSSLCH.l can be updated to a number.:
FAIL - CSSLCH.l can be updated with a CSS percent.:
FAIL - Updating a CSSLCH with CSS.number for c throws a SyntaxError:
FAIL - CSSLCH.c can be updated to a number.:
FAIL - CSSLCH.c can be updated with a CSS percent.:
FAIL - Updating a CSSLCH with CSS.number for alpha throws a SyntaxError:
FAIL - CSSLCH.alpha can be updated to a number.:
FAIL - CSSLCH.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSLCH with percent for the lightness works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssLab.html [wpt.fyi]
- Constructing a CSSLab with percent for the lightness works as intended.:
FAIL - CSSLab.l can be updated with a percent.:
FAIL - Constructing a CSSLab with number for the lightness works as intended.:
FAIL - CSSLab.l can be updated with a number.:
FAIL - Constructing a CSSLab with css pixels for lightness throws a SyntaxError.:
FAIL - Constructing a CSSLab with degrees for lightness throws a SyntaxError.:
FAIL - CSSLab can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSLab can be constructed from four numbers.:
FAIL - Constructing a CSSLab with CSS.number for l or alpha throws a SyntaxError:
FAIL - Updating a CSSLab with CSS.number for l throws a SyntaxError:
FAIL - CSSLab.l can be updated to a number.:
FAIL - CSSLab.l can be updated with a CSS percent.:
FAIL - Updating a CSSLab with CSS.number for alpha throws a SyntaxError:
FAIL - CSSLab.alpha can be updated to a number.:
FAIL - CSSLab.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSLab with percent for the lightness works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssOKLCH.html [wpt.fyi]
- Constructing a CSSOKLCH with percent for the lightness works as intended.:
FAIL - CSSOKLCH.l can be updated with a percent.:
FAIL - Constructing a CSSOKLCH with number for the lightness works as intended.:
FAIL - CSSOKLCH.l can be updated with a number.:
FAIL - Constructing a CSSOKLCH with css pixels for lightness throws a SyntaxError.:
FAIL - Constructing a CSSOKLCH with degrees for lightness throws a SyntaxError.:
FAIL - CSSOKLCH can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSOKLCH can be constructed from four numbers.:
FAIL - Constructing a CSSOKLCH with CSS.number for l, c, h or alpha throws a SyntaxError:
FAIL - Updating a CSSOKLCH with CSS.number for l throws a SyntaxError:
FAIL - CSSOKLCH.l can be updated to a number.:
FAIL - CSSOKLCH.l can be updated with a CSS percent.:
FAIL - Updating a CSSOKLCH with CSS.number for c throws a SyntaxError:
FAIL - CSSOKLCH.c can be updated to a number.:
FAIL - CSSOKLCH.c can be updated with a CSS percent.:
FAIL - Updating a CSSOKLCH with CSS.number for alpha throws a SyntaxError:
FAIL - CSSOKLCH.alpha can be updated to a number.:
FAIL - CSSOKLCH.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSOKLCH with percent for the lightness works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssOKLab.html [wpt.fyi]
- Constructing a CSSOKLab with percent for the lightness works as intended.:
FAIL - CSSOKLab.l can be updated with a percent.:
FAIL - Constructing a CSSOKLab with number for the lightness works as intended.:
FAIL - CSSOKLab.l can be updated with a number.:
FAIL - Constructing a CSSOKLab with css pixels for lightness throws a SyntaxError.:
FAIL - Constructing a CSSOKLab with degrees for lightness throws a SyntaxError.:
FAIL - CSSOKLab can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSOKLab can be constructed from four numbers.:
FAIL - Constructing a CSSOKLab with CSS.number for l or alpha throws a SyntaxError:
FAIL - Updating a CSSOKLab with CSS.number for l throws a SyntaxError:
FAIL - CSSOKLab.l can be updated to a number.:
FAIL - CSSOKLab.l can be updated with a CSS percent.:
FAIL - Updating a CSSOKLab with CSS.number for alpha throws a SyntaxError:
FAIL - CSSOKLab.alpha can be updated to a number.:
FAIL - CSSOKLab.alpha can be updated with a CSS percent.:
FAIL
- Constructing a CSSOKLab with percent for the lightness works as intended.:
- /css/css-typed-om/stylevalue-subclasses/cssRGB.html [wpt.fyi]
- Constructing a CSSRGB with an angle CSSUnitValue for the color channels throws a SyntaxError.:
FAIL - Constructing a CSSRGB with a CSSMathValue that doesn"t match <number> for the color channels throws a SyntaxError.:
FAIL - Constructing a CSSRGB with undefined for the color channels throws a SyntaxError.:
FAIL - Constructing a CSSRGB with a CSS math calculation for the color channels throws a SyntaxError.:
FAIL - Constructing a CSSRGB with a CSS number for the alpha channels throws a SyntaxError.:
FAIL - Updating CSSRGB. r to an angle CSSUnitValue throws a SyntaxError.:
FAIL - Updating CSSRGB. r to a CSSMathValue that doesn"t match <number> throws a SyntaxError.:
FAIL - Updating CSSRGB. r to undefined throws a SyntaxError.:
FAIL - Updating CSSRGB. r to a CSS math calculation throws a SyntaxError.:
FAIL - Updating CSSRGB. g to an angle CSSUnitValue throws a SyntaxError.:
FAIL - Updating CSSRGB. g to a CSSMathValue that doesn"t match <number> throws a SyntaxError.:
FAIL - Updating CSSRGB. g to undefined throws a SyntaxError.:
FAIL - Updating CSSRGB. g to a CSS math calculation throws a SyntaxError.:
FAIL - Updating CSSRGB. b to an angle CSSUnitValue throws a SyntaxError.:
FAIL - Updating CSSRGB. b to a CSSMathValue that doesn"t match <number> throws a SyntaxError.:
FAIL - Updating CSSRGB. b to undefined throws a SyntaxError.:
FAIL - Updating CSSRGB. b to a CSS math calculation throws a SyntaxError.:
FAIL - Updating CSSRGB. alpha to an angle CSSUnitValue throws a SyntaxError.:
FAIL - Updating CSSRGB. alpha to a CSSMathValue that doesn"t match <number> throws a SyntaxError.:
FAIL - Updating CSSRGB. alpha to undefined throws a SyntaxError.:
FAIL - Updating CSSRGB. alpha to a CSS math calculation throws a SyntaxError.:
FAIL - Updating the alpha channel to a CSS number throws a SyntaxError.:
FAIL - CSSRGB can be constructed from three numbers and will get an alpha of 100%.:
FAIL - CSSRGB can be constructed from four numbers.:
FAIL - CSSRGB.r can be updated with a number with the resulting value being a percentage.:
FAIL - CSSRGB.r can be updated with a CSS number.:
FAIL - CSSRGB.r can be updated with CSS percent.:
FAIL - CSSRGB.r can be updated with CSS math sum.:
FAIL - CSSRGB.r can be updated with CSS math product.:
FAIL - CSSRGB.r can be updated with CSS math max.:
FAIL - CSSRGB.r can be updated with CSS math min.:
FAIL - CSSRGB.g can be updated with a number with the resulting value being a percentage.:
FAIL - CSSRGB.g can be updated with a CSS number.:
FAIL - CSSRGB.g can be updated with CSS percent.:
FAIL - CSSRGB.g can be updated with CSS math sum.:
FAIL - CSSRGB.g can be updated with CSS math product.:
FAIL - CSSRGB.g can be updated with CSS math max.:
FAIL - CSSRGB.g can be updated with CSS math min.:
FAIL - CSSRGB.b can be updated with a number with the resulting value being a percentage.:
FAIL - CSSRGB.b can be updated with a CSS number.:
FAIL - CSSRGB.b can be updated with CSS percent.:
FAIL - CSSRGB.b can be updated with CSS math sum.:
FAIL - CSSRGB.b can be updated with CSS math product.:
FAIL - CSSRGB.b can be updated with CSS math max.:
FAIL - CSSRGB.b can be updated with CSS math min.:
FAIL - CSSRGB.alpha can be updated with a number with the resulting value being a percentage.:
FAIL - CSSRGB.alpha can be updated with CSS percent.:
FAIL - CSSRGB.alpha can be updated with CSS math sum.:
FAIL - CSSRGB.alpha can be updated with CSS math product.:
FAIL - CSSRGB.alpha can be updated with CSS math max.:
FAIL - CSSRGB.alpha can be updated with CSS math min.:
FAIL
- Constructing a CSSRGB with an angle CSSUnitValue for the color channels throws a SyntaxError.:
- /css/css-typed-om/stylevalue-subclasses/numeric-objects/cssUnitValue.html [wpt.fyi]
- CSSUnitValue can be constructed with Q:
FAIL - CSSUnitValue can be constructed with Hz:
FAIL - CSSUnitValue can be constructed with kHz:
FAIL
- CSSUnitValue can be constructed with Q:
- /css/css-typed-om/stylevalue-subclasses/numeric-objects/to.tentative.any.html [wpt.fyi]
- Converting a CSSUnitValue to its own unit returns itself:
FAIL
- Converting a CSSUnitValue to its own unit returns itself:
- /css/css-typed-om/stylevalue-subclasses/numeric-objects/to.tentative.any.sharedworker.html [wpt.fyi]
- Converting a CSSUnitValue to its own unit returns itself:
FAIL
- Converting a CSSUnitValue to its own unit returns itself:
- /css/css-typed-om/stylevalue-subclasses/numeric-objects/to.tentative.any.serviceworker.html [wpt.fyi]
- Converting a CSSUnitValue to its own unit returns itself:
FAIL
- Converting a CSSUnitValue to its own unit returns itself:
- /css/css-typed-om/stylevalue-subclasses/numeric-objects/to.tentative.any.worker.html [wpt.fyi]
- Converting a CSSUnitValue to its own unit returns itself:
FAIL
- Converting a CSSUnitValue to its own unit returns itself:
Comment 4•18 days ago
|
||
| bugherder | ||
Description
•