Compare commits

...

944 Commits

Author SHA1 Message Date
Euclid Ye
626af595f2 replaceWith <document> in a cycle should not panic (linux-wpt)
{"fail_fast": false, "matrix": [{"name": "Linux (WPT)", "workflow": "linux", "wpt": true, "profile": "release", "unit_tests": false, "build_libservo": false, "bencher": false, "coverage": false, "build_args": "", "wpt_args": "", "number_of_wpt_chunks": 20}]}
2026-04-25 21:09:07 +08:00
Euclid Ye
a09c334a52 replaceWith <document> in a cycle should not panic
Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-25 21:08:13 +08:00
Euclid Ye
35671d9dde pls don't panic
Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-25 17:12:45 +08:00
Alice
8ced3d1b8e layout: Expose some non-interactive accessibility roles based on DOM node type. (#44255)
Sets the accessibility role of nodes based on their DOM node type
(ignoring ARIA roles and computed styles for now), for a small subset of
roles.

This change also re-works some details of accessibility tree building:
- Set the `root` property for the accesskit tree to the node ID for the
root DOM node, rather than creating a placeholder root node which
contains the root DOM node.
- Since we now map the `<body>` node to the `RootWebArea` role, this
required a small change to the accessibility test logic to do a tree
walk to find the `RootWebArea` node, which used to be the first child
since we artificially set the placeholder root node to be the
`RootWebArea` node.
- Have `update_node_and_children()` return a bool indicating whether any
node was updated.
- Split the code updating the node itself into its own function,
`update_node()`, which takes a DOM node and returns a tuple containing
the accessibility node ID and a bool indicating whether the node
required updating
- Add an `assert_node_by_id()` method to retrieve an accessibility node
based on its ID.

Testing: See new tests added in this PR.

---------

Signed-off-by: Alice Boxhall <alice@igalia.com>
Co-authored-by: delan azabani <dazabani@igalia.com>
2026-04-25 06:25:20 +00:00
Gae24
1464ffd68a script: pass &mut JSContext to WritableStreamDefaultController::setup (#44490)
Also port `TextDecoderStream`, `TextEncoderStream`, `CompressionStream`
and `DecompressionStream` to `reflect_dom_object_with_proto_and_cx`.

Testing: It compiles
Part of #40600

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-25 03:52:36 +00:00
dependabot[bot]
6e4a9e85a2 build: bump grid from 1.0.0 to 1.0.1 (#44487)
Bumps [grid](https://github.com/becheran/grid) from 1.0.0 to 1.0.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/becheran/grid/releases">grid's
releases</a>.</em></p>
<blockquote>
<h2>v1.0.1</h2>
<h2>What's Changed</h2>
<ul>
<li>Add non-allocating delete_row and delete_col methods by <a
href="https://github.com/Copilot"><code>@​Copilot</code></a> in <a
href="https://redirect.github.com/becheran/grid/pull/70">becheran/grid#70</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/Copilot"><code>@​Copilot</code></a> made
their first contribution in <a
href="https://redirect.github.com/becheran/grid/pull/70">becheran/grid#70</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/becheran/grid/compare/v1.0.0...v1.0.1">https://github.com/becheran/grid/compare/v1.0.0...v1.0.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="8caa81908f"><code>8caa819</code></a>
chore: Release grid version 1.0.1</li>
<li><a
href="e879d4100b"><code>e879d41</code></a>
Add safety checks for empty input in insert_row and insert_col
methods</li>
<li><a
href="be213bd352"><code>be213bd</code></a>
Add safety checks for grid dimension overflow in expand and prepend
methods</li>
<li><a
href="e77e0c0241"><code>e77e0c0</code></a>
style: format test assertions for better readability</li>
<li><a
href="781d36c5d8"><code>781d36c</code></a>
Add comprehensive tests for delete methods including equivalence
tests</li>
<li><a
href="9bf8d0b96f"><code>9bf8d0b</code></a>
Add delete_row and delete_col methods to avoid allocation</li>
<li><a
href="da542e1ca6"><code>da542e1</code></a>
chore: fix pipeline formatting</li>
<li><a
href="875f418b55"><code>875f418</code></a>
chore: auto generate release notes</li>
<li>See full diff in <a
href="https://github.com/becheran/grid/compare/v1.0.0...v1.0.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=grid&package-manager=cargo&previous-version=1.0.0&new-version=1.0.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-24 17:44:35 +00:00
rovertrack
71a5dfabdd Devtools: Enable Stylesheets Resource and Add Basic Fields to StyleSheetsActor (#44462)
Added basic fields required by firefox remote debugging protocol for
stylesheets- `StyleSheetData`
Enabled stylesheets in devtools watcher, made stylesheet request return
an empty array for now.

Testing: No change in behaviour and tests 

Fixes: part of #44315

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-24 15:14:48 +00:00
Kingsley Yung
430105468f script: Add or remove elements in sanitizer (#44481)
Implement the `allowElement`, `removeElement` and
`replaceElementWithChildren` methods of the `Sanitizer` interface, which
add or remove elements in a sanitizer.

Specification:
- https://wicg.github.io/sanitizer-api/#dom-sanitizer-allowelement
- https://wicg.github.io/sanitizer-api/#dom-sanitizer-removeelement
-
https://wicg.github.io/sanitizer-api/#dom-sanitizer-replaceelementwithchildren

Testing: Covered by WPT tests in `sanitizer-api/` subdirectory.
Additionally, some tests in `sanitizer-basic-filtering.tentative.html`
are changed from ERROR to FAIL because of this implementation.
Fixes: Part of #43948

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-24 15:07:01 +00:00
elomscansio
93ae710c07 script: propagate &mut JSContext in DebuggerGlobalScope::fire_eval (#44477)
Propagate `&mut JSContext` in `DebuggerGlobalScope::fire_eval`

Testing: Successful build is enough
Fixes: Part of #42638 

Opened to reduces the complexity of #44254

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
Signed-off-by: elomscansio <163124154+elomscansio@users.noreply.github.com>
Co-authored-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-24 14:53:28 +00:00
elomscansio
8590dd74c9 script: propagate &mut JSContext in DebuggerGlobalScope::fire_add_debugee (#44476)
Propagate `&mut JSContext` in `DebuggerGlobalScope::fire_add_debugee`

Testing: Successful build is enough
Fixes: Part of #42638 

Opened to reduces the complexity of #44254

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-24 14:53:08 +00:00
rovertrack
8470478270 pass &mut JSContext to remove_script_and_layout_blocker (#44484)
This PR makes the `remove_script_and_layout_blocker` in
ee72fca571/components/script/dom/document/document.rs (L3727)
take `&mut JSContext` as argument, removing the dependency of the
previous `temp_cx` being created!

Testing:  No behaviour changes , all tests passes.
Fixes: #44479

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-24 14:27:55 +00:00
Jonathan Schwender
ee72fca571 devtools: Respect SOURCE_DATE_EPOCH for build_id (#44459)
We are probably not anywhere close to reproducible builds, but we should
try to follow best practices where trivially possible.
See also: https://reproducible-builds.org/docs/source-date-epoch/

Firefox devtools expects the build_id to be provided in a datetime
specific format.
This PR also switches the time to UTC instead of `Local`, since there
seems to be no clear reason to use Local, and SOURCE_DATE_EPOCH is UTC.

Testing: No functional changes, the devtools build_id is not covered by
any tests.
Fixes: #44458

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-24 12:09:44 +00:00
elomscansio
551100c8bb script: propagate &mut JSContext in DebuggerGlobalScope::fire_get_possible_breakpoints (#44478)
Propagate `&mut JSContext` in
`DebuggerGlobalScope::fire_get_possible_breakpoints` and related call
sites.

Testing: Successful build is enough
Fixes: Part of #42638 

Opened to reduces the complexity of #44254

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-24 11:34:00 +00:00
Furkan Erdem
22da16139d script: Use frozen array in gamepad axes for spec complience (#44411)
To comply with the Gamepad spec, this commit changes the type of Gamepad
axes from Float64Array to CachedFrozenArray as per [Gamepad
Interface](https://w3c.github.io/gamepad/#gamepad-interface).

Fixes: #44336
Testing: automated tests are not possible because the axes values can
only be accessed with a real gamepad attached.

Signed-off-by: log101 <ffrknerdm@gmail.com>
2026-04-24 11:11:44 +00:00
elomscansio
b3d2bc5624 script: propagate &mut JSContext in XMLHttpRequest::change_ready_state (#44475)
Propagate `&mut JSContext` in `XMLHttpRequest::change_ready_state`

Testing: Successful build is enough
Fixes: Part of #42638 

Opened to reduces the complexity of #44254

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-24 10:09:19 +00:00
Alice
61203e68b9 script: Don't panic when trying to de-activate accessibility (#44473)
When reloading, the pipeline is closed before we get the chance to set
accessibility inactive, which we do for pipelines which stick around in
the bfcache. We don't need to panic if we're trying to de-activate
accessibility and the pipeline is already closed.

Trying to activate accessibility on a closed pipeline is an error we
should investigate, but probably also not a panic-worthy condition.

Testing: Not sure how to test this beyond manual testing. Manual
testing: run servoshell with `--pref accessibility_enabled` and reload
any page.

Signed-off-by: Alice Boxhall <alice@igalia.com>
2026-04-24 08:19:00 +00:00
rovertrack
d812d2f1a7 Gamepad: Implement gamepad buttons to be array, removing GamepadList (#44357)
Replaced `GamepadButtonList` interface with a frozen array of gamepad
buttons to match the gamepad webidl specification.

Testing: No idlharness tests possible since the values can't be accessed
without a real gamepad.
Fixes: #44333

---------

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-24 08:15:53 +00:00
dependabot[bot]
174b9237a8 build: bump bitflags from 2.11.0 to 2.11.1 (#44466)
Bumps [bitflags](https://github.com/bitflags/bitflags) from 2.11.0 to
2.11.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/bitflags/bitflags/releases">bitflags's
releases</a>.</em></p>
<blockquote>
<h2>2.11.1</h2>
<h2>What's Changed</h2>
<ul>
<li>Bless compile-fail tests for current beta by <a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
in <a
href="https://redirect.github.com/bitflags/bitflags/pull/478">bitflags/bitflags#478</a></li>
<li>example_generated.rs: add missing third slash for doc comment by <a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
in <a
href="https://redirect.github.com/bitflags/bitflags/pull/477">bitflags/bitflags#477</a></li>
<li>Clarify self and other in method docs by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/bitflags/bitflags/pull/481">bitflags/bitflags#481</a></li>
<li>Prepare for 2.11.1 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/bitflags/bitflags/pull/482">bitflags/bitflags#482</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
made their first contribution in <a
href="https://redirect.github.com/bitflags/bitflags/pull/478">bitflags/bitflags#478</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/bitflags/bitflags/compare/2.11.0...2.11.1">https://github.com/bitflags/bitflags/compare/2.11.0...2.11.1</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/bitflags/bitflags/blob/main/CHANGELOG.md">bitflags's
changelog</a>.</em></p>
<blockquote>
<h1>2.11.1</h1>
<h2>What's Changed</h2>
<ul>
<li>Bless compile-fail tests for current beta by <a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
in <a
href="https://redirect.github.com/bitflags/bitflags/pull/478">bitflags/bitflags#478</a></li>
<li>example_generated.rs: add missing third slash for doc comment by <a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
in <a
href="https://redirect.github.com/bitflags/bitflags/pull/477">bitflags/bitflags#477</a></li>
<li>Clarify self and other in method docs by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/bitflags/bitflags/pull/481">bitflags/bitflags#481</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/DanielEScherzer"><code>@​DanielEScherzer</code></a>
made their first contribution in <a
href="https://redirect.github.com/bitflags/bitflags/pull/478">bitflags/bitflags#478</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/bitflags/bitflags/compare/2.11.0...2.11.1">https://github.com/bitflags/bitflags/compare/2.11.0...2.11.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="4ed9ffa949"><code>4ed9ffa</code></a>
Merge pull request <a
href="https://redirect.github.com/bitflags/bitflags/issues/482">#482</a>
from KodrAus/cargo/2.11.1</li>
<li><a
href="c53cd57ace"><code>c53cd57</code></a>
prepare for 2.11.1 release</li>
<li><a
href="a44410aa84"><code>a44410a</code></a>
Merge pull request <a
href="https://redirect.github.com/bitflags/bitflags/issues/481">#481</a>
from KodrAus/docs/clarifications</li>
<li><a
href="3d671b9b0e"><code>3d671b9</code></a>
update more compile error messages</li>
<li><a
href="5f3adade43"><code>5f3adad</code></a>
fix up compile error messages</li>
<li><a
href="780765d17c"><code>780765d</code></a>
fix up contains and intersection docs</li>
<li><a
href="97b7607c22"><code>97b7607</code></a>
clarify self and other in method docs</li>
<li><a
href="88a7a18a2e"><code>88a7a18</code></a>
Merge pull request <a
href="https://redirect.github.com/bitflags/bitflags/issues/477">#477</a>
from DanielEScherzer/patch-1</li>
<li><a
href="f0e46461a8"><code>f0e4646</code></a>
example_generated.rs: add missing third slash for doc comment</li>
<li><a
href="a31c96f5cb"><code>a31c96f</code></a>
Merge pull request <a
href="https://redirect.github.com/bitflags/bitflags/issues/478">#478</a>
from DanielEScherzer/beta-bless</li>
<li>Additional commits viewable in <a
href="https://github.com/bitflags/bitflags/compare/2.11.0...2.11.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=bitflags&package-manager=cargo&previous-version=2.11.0&new-version=2.11.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-24 06:29:34 +00:00
dependabot[bot]
c1e5ea362d build: bump jiff from 0.2.23 to 0.2.24 (#44467)
Bumps [jiff](https://github.com/BurntSushi/jiff) from 0.2.23 to 0.2.24.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/BurntSushi/jiff/blob/master/CHANGELOG.md">jiff's
changelog</a>.</em></p>
<blockquote>
<h1>0.2.24 (2026-04-23)</h1>
<p>This release primarily adds a new <code>memory_usage</code> routine
for reporting
heap allocation sizes for the <code>TimeZone</code> and
<code>Zoned</code> types. This
release also acknowledges and updates the timeline expectations for a
Jiff 1.0 release in <code>README.md</code>.</p>
<p>Enhancements:</p>
<ul>
<li><a
href="https://redirect.github.com/BurntSushi/jiff/issues/520">#520</a>:
Add <code>memory_usage</code> to the <code>TimeZone</code> and
<code>Zoned</code> types.</li>
<li><a
href="https://redirect.github.com/BurntSushi/jiff/pull/535">#535</a>:
Improve comment in <code>Span::checked_add</code> example.</li>
</ul>
<p>Bug fixes:</p>
<ul>
<li><a
href="https://redirect.github.com/BurntSushi/jiff/pull/541">#541</a>:
Update Jiff 1.0 timeline.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="2cc55b285d"><code>2cc55b2</code></a>
0.2.24</li>
<li><a
href="c6542f109e"><code>c6542f1</code></a>
changelog: 0.2.24</li>
<li><a
href="ec3c2ec962"><code>ec3c2ec</code></a>
api: add <code>TimeZone::memory_usage</code> and
<code>Zoned::memory_usage</code></li>
<li><a
href="bc752b63ed"><code>bc752b6</code></a>
docs: improve comment in <code>Span::checked_add</code> example</li>
<li><a
href="f6c8a55ef4"><code>f6c8a55</code></a>
readme: update 1.0 timeline</li>
<li><a
href="97314c11d4"><code>97314c1</code></a>
docs: fix typo</li>
<li><a
href="bad71d8d5d"><code>bad71d8</code></a>
docs: typo</li>
<li>See full diff in <a
href="https://github.com/BurntSushi/jiff/compare/jiff-static-0.2.23...jiff-static-0.2.24">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=jiff&package-manager=cargo&previous-version=0.2.23&new-version=0.2.24)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-24 06:29:32 +00:00
dependabot[bot]
ffa2a72a55 build: bump libc from 0.2.185 to 0.2.186 (#44468)
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.185 to 0.2.186.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/releases">libc's
releases</a>.</em></p>
<blockquote>
<h2>0.2.186</h2>
<h3>Added</h3>
<ul>
<li>Apple: Add <code>KEVENT_FLAG_*</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5070">#5070</a>)</li>
<li>Linux: Add <code>PR_SET_MEMORY_MERGE</code> and
<code>PR_GET_MEMORY_MERGE</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5060">#5060</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li>CI: Migrate FreeBSD CI from Cirrus CI to GitHub Actions (<a
href="https://redirect.github.com/rust-lang/libc/pull/5058">#5058</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/blob/0.2.186/CHANGELOG.md">libc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/libc/compare/0.2.185...0.2.186">0.2.186</a>
- 2026-04-24</h2>
<h3>Added</h3>
<ul>
<li>Apple: Add <code>KEVENT_FLAG_*</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5070">#5070</a>)</li>
<li>Linux: Add <code>PR_SET_MEMORY_MERGE</code> and
<code>PR_GET_MEMORY_MERGE</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5060">#5060</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li>CI: Migrate FreeBSD CI from Cirrus CI to GitHub Actions (<a
href="https://redirect.github.com/rust-lang/libc/pull/5058">#5058</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="42620ffc41"><code>42620ff</code></a>
[0.2] libc: Release 0.2.186</li>
<li><a
href="9db2eaaaae"><code>9db2eaa</code></a>
apple: add KEVENT_FLAG_* constants</li>
<li><a
href="38409392ff"><code>3840939</code></a>
Add PR_SET_MEMORY_MERGE and PR_GET_MEMORY_MERGE for linux</li>
<li><a
href="f697deb944"><code>f697deb</code></a>
chore: migrate from Cirrus CI to GHA</li>
<li>See full diff in <a
href="https://github.com/rust-lang/libc/compare/0.2.185...0.2.186">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libc&package-manager=cargo&previous-version=0.2.185&new-version=0.2.186)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-24 06:28:47 +00:00
Alice
6a84134a34 layout: Store AccessibilityTree's nodes in ArcRefCells. (#44438)
This will allow us not to need to repeatedly borrow `self` when
reading/updating individual `AccessibilityNode`s.

Testing: No behaviour change, covered by existing `accessibility` test.

---------

Signed-off-by: Alice Boxhall <alice@igalia.com>
Co-authored-by: delan azabani <dazabani@igalia.com>
2026-04-24 05:42:17 +00:00
Martin Robinson
25ef3121a7 layout: Split hard line breaks into their own TextRunItem (#44436)
This change makes it so that hard line breaks are not shaped during
inline formatting context creation. Instead they are a separate variant
of a new `TextRunItem` enum. This will make it easier to start
linebreaking later in the flow of inline layout.

Testing: This fixes three WPT tests, likely because we are now properly
using the BiDi level of BiDi control characters. One test starts
failing, but
it depends on tab rendering, which we do not currently support properly.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-23 19:29:20 +00:00
Euclid Ye
464ae8204f layout: Use an accurately-sized clipping rectangle for box-shadow display list item properties instead of MaxRect (#44457)
Mobile phone runs OpenGL Embedded System. The precision is limited
comparing to Desktop which runs full OpenGL. This caused a bug where
box-shadow is not displayed on Android/OHOS. Instead of using an
infinite clip rect, we compute a bounded one. This should save some GPU
work as well.

Reference: [How to gracefully handle highp/mediump switch for mobile
Android
browsers?](https://discourse.threejs.org/t/how-to-gracefully-handle-highp-mediump-switch-for-mobile-android-browsers/77335)


Testing: Desktop WPT
[unchanged](https://github.com/servo/servo/actions/runs/24825758325).
Manually tested on Android/Ohos. Now look same as Firefox/Chrome.

| Before | After |
| -------- | -------- |
|
![Screenshot_20260423_154114.jpg](https://github.com/user-attachments/assets/b1c970c8-a30c-4fb8-acbc-c97fa9cc03f9)
|
![screenshot_20260423_154059_1776930134.jpg](https://github.com/user-attachments/assets/432a29c4-0c5c-4ff2-83eb-81db55e76f64)
|


Fixes: #44431
Closes: https://github.com/servo/webrender/pull/4879

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-23 18:03:51 +00:00
Tim van der Lippe
9189fe06a5 script: Add initial implementation of italic command (#44432)
While working on this, I realised that the `current_state`
computation was wrong. Instead, the spec actually clearly
defines what to do, but I hadn't found it yet. The code
now correctly implements state computation and voila, it
also fixes the previous underline issue that I didn't
understand why it would fail.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-23 15:54:57 +00:00
elomscansio
aa7eca43b7 script: propagate VirtualMethods::unbind_from_tree with &mut JSContext (#44422)
Propagate `&mut JSContext` in `VirtualMethods::unbind_from_tree`

Testing: Successful build is enough
Fixes: #42837

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-23 14:09:11 +00:00
Alice
ff0e9655a8 layout: Allow repeatedly adding the same node to AccessibilityUpdate (#44437)
This means keeping nodes in a temporary map until the accesskit
TreeUpdate is accessed via `finalize()`. After `finalize()` is called,
any further attempts to use the object will panic.

Testing: Added a unit test.

---------

Signed-off-by: Alice Boxhall <alice@igalia.com>
Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: delan azabani <dazabani@igalia.com>
2026-04-23 13:54:46 +00:00
dependabot[bot]
b0d512c435 build: bump hyper-rustls from 0.27.8 to 0.27.9 (#44449)
Bumps [hyper-rustls](https://github.com/rustls/hyper-rustls) from 0.27.8
to 0.27.9.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/hyper-rustls/releases">hyper-rustls's
releases</a>.</em></p>
<blockquote>
<h2>0.27.9</h2>
<p>This release fixes the accidental omission of the ISC license in the
published crate.</p>
<h2>What's Changed</h2>
<ul>
<li>Bump rustls from 0.23.37 to 0.23.38 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/339">rustls/hyper-rustls#339</a></li>
<li>Fix ISC license include, prepare 0.27.9 by <a
href="https://github.com/cpu"><code>@​cpu</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/340">rustls/hyper-rustls#340</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rustls/hyper-rustls/compare/v/0.27.8...v/0.27.9">https://github.com/rustls/hyper-rustls/compare/v/0.27.8...v/0.27.9</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="9741534153"><code>9741534</code></a>
Cargo: version 0.27.8 -&gt; 0.27.9</li>
<li><a
href="d391ce2611"><code>d391ce2</code></a>
Cargo: update semver compat deps</li>
<li><a
href="a163901fbf"><code>a163901</code></a>
Cargo: fix include license typo for ISC license</li>
<li><a
href="b3eb41ec15"><code>b3eb41e</code></a>
Bump rustls from 0.23.37 to 0.23.38</li>
<li>See full diff in <a
href="https://github.com/rustls/hyper-rustls/compare/v/0.27.8...v/0.27.9">compare
view</a></li>
</ul>
</details>
<br />

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 13:36:23 +00:00
Gae24
e2f17e0d28 deps: Bump jni-rs to 0.22 (#44322)
Update jni-rs to 0.22, the main changes involve the introduction of
`with_env` within native methods, and updating uses of
`attach_current_thread`, which now requires a closure passed to it.
Callback object is now stored inside a `OnceLock`, since it would crash
when it was deleted, probably once a `WakeupCallback` was dropped:
```
JNI DETECTED ERROR IN APPLICATION: JNI ERROR (app bug): jobject is an invalid global reference: 0x2fc6 (deleted reference at index 382)
```
Also update android-activity and rustls-platform-verifier.

Testing: We don't have android tests in CI, manual testing is required
Fixes: Part of #40979

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-23 11:55:29 +00:00
Jonathan Schwender
0ea42bc774 profile: Add instrumentation to startup related functions (#44456)
Follow-up to #44443.
This helps investigating the cold-start timeline, and could be used
by tooling to A/B compare branches affecting the cold-start time.

Additionally also change the `handle_request::select` span, so that we
can see the blocked time (which was probably what was intended), since
the actual time spent on recv after select is insignificant.

Testing: Tracing output is not covered by automatic tests.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-23 11:47:27 +00:00
Jonathan Schwender
ab5deb4030 profile: Add initial trace event (#44443)
Adds a profiling event at the startup of servoshell, right after
initializing the tracing subsystem. To support this, add macro
abstractions for tracing events.
The existing span (macros) have a start and an end, but for one-off
events, we don't need a span and hence it make sense to also add the
event macros.

The new event at startup is useful when measuring / optimizing general
startup time. Adding a timestamp as field, allows us to ground the
measurement and compare it against time measured outside of servo,
regardless of how the profiling backend (tracing-perfetto,
tracing-hitrace, future backends) save timestamps.

Testing: Build-testing: the HarmonyOS build enables the tracing feature.
On other platforms this is not the case in CI.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-23 09:18:28 +00:00
Kingsley Yung
daed36d4bf script: Implement Sanitizer.get() method (#44452)
Implement the `Sanitizer.get()` method.

Same as the previous patches on Sanitizer API, the steps related to
processing instructions are marked as TODO. Support for process
instructions was recently added to the specification, and we will
implement it later when tests are ready.

Testing: Covered by WPT tests in
`sanitizer-api/sanitizer-get.tentative.html`
Fixes: Part of #43948

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-23 06:01:36 +00:00
Gae24
20e94989eb script: pass &mut JSContext inside worklet code (#44441)
Testing: It compiles 
Part of #40600

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-23 05:58:09 +00:00
Taym Haddadi
353e5248f1 SharedWorker : script unblock shared worker common plumbing for SharedWorker (#44440)
part of https://github.com/servo/servo/issues/7458

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-23 05:54:21 +00:00
Jonathan Schwender
d0b2337118 mozjs: Fix make 4.4 broken parallel compilation (#44346)
Companion PR to https://github.com/servo/mozjs/pull/735.
This bumps mozjs to the latest version 0.15.9. The changes were reviewed
in the linked PR.


Testing: This changes behavior when using `make` 4.4 and compiling mozjs
from source in CI. This path is not exercised in CI, since Ubuntu 24.04
still ships make 4.3.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-23 05:26:59 +00:00
dependabot[bot]
e611a186be build: bump typenum from 1.19.0 to 1.20.0 (#44451)
Bumps [typenum](https://github.com/paholg/typenum) from 1.19.0 to
1.20.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/paholg/typenum/releases">typenum's
releases</a>.</em></p>
<blockquote>
<h2>v1.20.0</h2>
<h2>Commits</h2>
<ul>
<li>77b877d: remove deprecated features, replace build script with
pre-generated tests (<a
href="https://redirect.github.com/paholg/typenum/issues/237">#237</a>)
(Cathal) <a
href="https://redirect.github.com/paholg/typenum/pull/237">#237</a></li>
<li>4d5f26b: Add tuple operations (<a
href="https://redirect.github.com/paholg/typenum/issues/242">#242</a>)
(grenewode) <a
href="https://redirect.github.com/paholg/typenum/pull/242">#242</a></li>
<li>c755e2f: Version 1.20.0 (Paho Lurie-Gregg)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/paholg/typenum/blob/main/CHANGELOG.md">typenum's
changelog</a>.</em></p>
<blockquote>
<h3>1.20.0 (2026-04-18)</h3>
<ul>
<li>[removed] Removed <code>no_std</code> feature flag (deprecated since
1.3.0)</li>
<li>[removed] Removed <code>force_unix_path_separator</code> feature
flag (deprecated since 1.17.0)</li>
<li>[changed] Replaced <code>build.rs</code> script with pre-generated
test files</li>
<li>[added] Indexing into tuples</li>
<li>[changed] MSRV now 1.41.0</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="c755e2fd5d"><code>c755e2f</code></a>
Version 1.20.0</li>
<li><a
href="4d5f26b629"><code>4d5f26b</code></a>
Add tuple operations (<a
href="https://redirect.github.com/paholg/typenum/issues/242">#242</a>)</li>
<li><a
href="77b877d567"><code>77b877d</code></a>
remove deprecated features, replace build script with pre-generated
tests (<a
href="https://redirect.github.com/paholg/typenum/issues/237">#237</a>)</li>
<li>See full diff in <a
href="https://github.com/paholg/typenum/compare/v1.19.0...v1.20.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=typenum&package-manager=cargo&previous-version=1.19.0&new-version=1.20.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 00:58:55 +00:00
dependabot[bot]
82370a7cab build: bump clap from 4.6.0 to 4.6.1 (#44450)
Bumps [clap](https://github.com/clap-rs/clap) from 4.6.0 to 4.6.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/releases">clap's
releases</a>.</em></p>
<blockquote>
<h2>v4.6.1</h2>
<h2>[4.6.1] - 2026-04-15</h2>
<h3>Fixes</h3>
<ul>
<li><em>(derive)</em> Ensure rebuilds happen when an read env variable
is changed</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap's
changelog</a>.</em></p>
<blockquote>
<h2>[4.6.1] - 2026-04-15</h2>
<h3>Fixes</h3>
<ul>
<li><em>(derive)</em> Ensure rebuilds happen when an read env variable
is changed</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="14202755e5"><code>1420275</code></a>
chore: Release</li>
<li><a
href="d2c817d151"><code>d2c817d</code></a>
docs: Update changelog</li>
<li><a
href="f88c94e53d"><code>f88c94e</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6341">#6341</a>
from epage/sep</li>
<li><a
href="acbb822505"><code>acbb822</code></a>
fix(complete): Reduce risk of conflict with actual subcommands</li>
<li><a
href="a49fadbf4a"><code>a49fadb</code></a>
refactor(complete): Pull out subcommand separator</li>
<li><a
href="ddc008bbbc"><code>ddc008b</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6332">#6332</a>
from epage/update</li>
<li><a
href="497dc50aeb"><code>497dc50</code></a>
chore: Update compatible dependencies</li>
<li><a
href="dca2326243"><code>dca2326</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6331">#6331</a>
from clap-rs/renovate/j178-prek-action-2.x</li>
<li><a
href="54bdaa340e"><code>54bdaa3</code></a>
chore(deps): Update j178/prek-action action to v2</li>
<li><a
href="f0d30d961d"><code>f0d30d9</code></a>
chore: Release</li>
<li>Additional commits viewable in <a
href="https://github.com/clap-rs/clap/compare/clap_complete-v4.6.0...clap_complete-v4.6.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=clap&package-manager=cargo&previous-version=4.6.0&new-version=4.6.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 00:54:28 +00:00
dependabot[bot]
1c4b0b57b8 build: bump rustls from 0.23.38 to 0.23.39 (#44448)
Bumps [rustls](https://github.com/rustls/rustls) from 0.23.38 to
0.23.39.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="05416057db"><code>0541605</code></a>
Cargo: version 0.23.38 -&gt; 0.23.39</li>
<li><a
href="860798e729"><code>860798e</code></a>
Cargo: update semver compat deps</li>
<li><a
href="7b374684a2"><code>7b37468</code></a>
Take semver-compatible dependency updates</li>
<li><a
href="6134204146"><code>6134204</code></a>
Adapt to updated nightly features</li>
<li><a
href="d4b3ec5af3"><code>d4b3ec5</code></a>
Apply suggestions from clippy 1.95</li>
<li>See full diff in <a
href="https://github.com/rustls/rustls/compare/v/0.23.38...v/0.23.39">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rustls&package-manager=cargo&previous-version=0.23.38&new-version=0.23.39)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 00:44:38 +00:00
dependabot[bot]
609f50d680 build: bump pastey from 0.2.1 to 0.2.2 (#44447)
Bumps [pastey](https://github.com/as1100k/pastey) from 0.2.1 to 0.2.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/as1100k/pastey/releases">pastey's
releases</a>.</em></p>
<blockquote>
<h2>v0.2.2</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix Rust 1.56 compatibility: Handle None-delimited groups in replace
modifier in <a
href="https://redirect.github.com/AS1100K/pastey/pull/25">AS1100K/pastey#25</a></li>
<li>increase the code coverage by <a
href="https://github.com/bharatGoswami8"><code>@​bharatGoswami8</code></a>
in <a
href="https://redirect.github.com/AS1100K/pastey/pull/28">AS1100K/pastey#28</a></li>
<li>add coverage on CI by <a
href="https://github.com/bharatGoswami8"><code>@​bharatGoswami8</code></a>
in <a
href="https://redirect.github.com/AS1100K/pastey/pull/30">AS1100K/pastey#30</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/bharatGoswami8"><code>@​bharatGoswami8</code></a>
made their first contribution in <a
href="https://redirect.github.com/AS1100K/pastey/pull/28">AS1100K/pastey#28</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/AS1100K/pastey/blob/master/CHANGELOG.md#022---2026-04-23"><code>CHANGELOG.md</code></a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/AS1100K/pastey/blob/master/CHANGELOG.md">pastey's
changelog</a>.</em></p>
<blockquote>
<h2>[0.2.2] - 2026-04-23</h2>
<h3>Improved</h3>
<ul>
<li>Improved Code Coverage <a
href="https://redirect.github.com/AS1100K/pastey/pull/28">#28</a>, <a
href="https://redirect.github.com/AS1100K/pastey/pull/30">#30</a></li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Rust 1.56 compatibility: Handling None-delimited groups in replace
modifier <a
href="https://redirect.github.com/AS1100K/pastey/pull/25">#25</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f91b0f4b31"><code>f91b0f4</code></a>
RELEASE v0.2.2</li>
<li><a
href="93387eb677"><code>93387eb</code></a>
add coverage on CI (<a
href="https://redirect.github.com/as1100k/pastey/issues/30">#30</a>)</li>
<li><a
href="113fbc1811"><code>113fbc1</code></a>
increase the code coverage (<a
href="https://redirect.github.com/as1100k/pastey/issues/28">#28</a>)</li>
<li><a
href="436923754b"><code>4369237</code></a>
Fix CI Rust 1.56 failure: pin dissimilar to 1.0.10</li>
<li><a
href="6e3ef4a67c"><code>6e3ef4a</code></a>
Fix Rust 1.56 compatibility: Handle None-delimited groups in replace
modifier...</li>
<li>See full diff in <a
href="https://github.com/as1100k/pastey/compare/v0.2.1...v0.2.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pastey&package-manager=cargo&previous-version=0.2.1&new-version=0.2.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 00:38:10 +00:00
dependabot[bot]
412f98b9bb build: bump dbus from 0.9.10 to 0.9.11 (#44446)
Bumps [dbus](https://github.com/diwic/dbus-rs) from 0.9.10 to 0.9.11.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="eb330f7e41"><code>eb330f7</code></a>
dbus: Release 0.9.11</li>
<li><a
href="610ada219e"><code>610ada2</code></a>
dbus-native: Fix compiler warning</li>
<li><a
href="00a70d0c40"><code>00a70d0</code></a>
Dbus: Fix compiler warnings</li>
<li><a
href="f24617ab50"><code>f24617a</code></a>
Merge pull request <a
href="https://redirect.github.com/diwic/dbus-rs/issues/515">#515</a>
from abyssdigger/patch-1</li>
<li><a
href="0d4ac9aa0a"><code>0d4ac9a</code></a>
Fix compiler warnings</li>
<li><a
href="686b50df7a"><code>686b50d</code></a>
dbus: Add documentation to Variant and match_signal</li>
<li><a
href="993045f6ef"><code>993045f</code></a>
Release dbus 0.9.10, libdbus-sys 0.2.7</li>
<li><a
href="debcde3363"><code>debcde3</code></a>
dbus/blocking.rs: add new connection by address</li>
<li><a
href="eee6bf5b2d"><code>eee6bf5</code></a>
Merge pull request <a
href="https://redirect.github.com/diwic/dbus-rs/issues/512">#512</a>
from mrdomino/bump-windows-sys</li>
<li><a
href="5061c6018e"><code>5061c60</code></a>
Bump windows-sys from 0.59.0 to 0.61.0</li>
<li>See full diff in <a
href="https://github.com/diwic/dbus-rs/compare/dbus-v0.9.10...dbus-v0.9.11">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=dbus&package-manager=cargo&previous-version=0.9.10&new-version=0.9.11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-23 00:30:30 +00:00
Simon Sapin
4535a7d7b5 script: Rewrite NodeList::ChildrenList with a cached Vec of nodes (#44435)
In DOM APIs, `Node.childNodes` is a `NodeList` that has an
`.item(index)` method that allows random access, but DOM nodes only
store pointers to their first/last child and next/previous sibling. The
previous implementation involved keeping a "last accessed" pointer, and
a significant amount of logic to find the requested index by walking
next/previous sibling pointers from whichever of last accessed, first
child, or last child is nearest. This logic sometimes incorrectly
assumed the (nullable) last accessed pointer to be present, causing a
panic in `Option::unwrap`.
    
Rather than try to fix that logic, this replaces entirely with the
approach suggested in #25206 and used [by
Firefox](https://searchfox.org/firefox-main/source/dom/base/nsChildContentList.h):
keep a cached `Vec` of pointers to all child nodes, created lazily when
needed, and invalidated whenever any part of it changes.
    
Testing: the first commit adds a failing WPT crashtest, the second
commit fixes it
Fixes: https://github.com/servo/servo/issues/25206
Fixes: https://github.com/servo/servo/issues/36764

---------

Signed-off-by: Simon Sapin <simon@igalia.com>
2026-04-22 16:12:16 +00:00
Martin Robinson
1528f31269 script: Add an initial implementation of the "focus update steps" (#44360)
This moves Servo closer to the focus parts of the HTML specification.
The behavior should be the same as before, but now the code in `script`
matches the structure of the specification.

The main goal is to set us up for:
 - Firing focus events in the right order on nested documents
 - A proper implementation of the unfocusing steps.

Testing: This should not change behavior so is covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-22 15:55:36 +00:00
Narfinger
c2b88ff7f5 media: Switch to workspace dependencies and minor cleanup (#44428)
This PR makes minor cleanup in the media crates:
- Switch dependencies to workspace dependencies if they are already
included in the main Cargo.toml
- Switch from crate serde_derive to serde with feature flag derive.
- Switch from the separate crate for OnceCell to the std provided
LazyLock.
- Update num_complex

Testing: The only functional changes are either slight version bumps,
the replacement to LazyLock which is conservative and the num_complex
update which also shouldn't have any behavior changes.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-22 14:56:59 +00:00
Kingsley Yung
6934a65e5c script: Validate sanitizer configuration (#44421)
Implement sanitizer configuration validation algorithm, and complete the
"set a configuration" algorithm.

The steps related to processing instructions are marked as TODO. Support
for process instructions was recently added to the specification, and we
will implement it later when tests are ready.

Specification:
- https://wicg.github.io/sanitizer-api/#sanitizerconfig-valid
- https://wicg.github.io/sanitizer-api/#sanitizer-set-a-configuration

Testing: Covered by WPT tests in
`sanitizer-api/sanitizer-config.tentative.html`
Fixes: Part of #43948

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-22 12:28:57 +00:00
Euclid Ye
d46b0a9826 dependabot: Add rustls-webpki related group (#44429)
This should make #44415, #44418, #44419 
work in one PR without conflict in the future.

Testing: Will be tested in CI in future rounds of update.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-22 11:15:02 +00:00
Tim van der Lippe
6de7311014 script: Add initial implementation of strikethrough command (#44410)
Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-22 09:23:05 +00:00
dependabot[bot]
7007dc4346 build: bump rustls-webpki from 0.103.12 to 0.103.13 (#44419)
Bumps [rustls-webpki](https://github.com/rustls/webpki) from 0.103.12 to
0.103.13.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/webpki/releases">rustls-webpki's
releases</a>.</em></p>
<blockquote>
<h2>0.103.13</h2>
<ul>
<li><strong>Fix reachable panic in parsing a CRL</strong>. This was
reported to us as <a
href="https://github.com/rustls/webpki/security/advisories/GHSA-82j2-j2ch-gfr8">GHSA-82j2-j2ch-gfr8</a>.
Users who don't use CRLs are not affected.</li>
<li>For name constraints on URI names, we incorrectly processed excluded
subtrees in a way which inverted the desired meaning. See <a
href="https://redirect.github.com/rustls/webpki/pull/471">rustls/webpki#471</a>.
This was a case missing in the fix for <a
href="https://github.com/advisories/GHSA-965h-392x-2mh5">https://github.com/advisories/GHSA-965h-392x-2mh5</a>.</li>
</ul>
<h2>What's Changed</h2>
<ul>
<li>Actually fail closed for URI matching against excluded subtrees by
<a href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki/pull/473">rustls/webpki#473</a></li>
<li>Prepare 0.103.13 by <a
href="https://github.com/ctz"><code>@​ctz</code></a> in <a
href="https://redirect.github.com/rustls/webpki/pull/474">rustls/webpki#474</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rustls/webpki/compare/v/0.103.12...v/0.103.13">https://github.com/rustls/webpki/compare/v/0.103.12...v/0.103.13</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="2879b2ce7a"><code>2879b2c</code></a>
Prepare 0.103.13</li>
<li><a
href="2c49773d82"><code>2c49773</code></a>
Improve tests for padding of <code>BitStringFlags</code></li>
<li><a
href="4e3c0b393a"><code>4e3c0b3</code></a>
Correct validation of BIT STRING constraints</li>
<li><a
href="39c91d2525"><code>39c91d2</code></a>
Actually fail closed for URI matching against excluded subtrees</li>
<li>See full diff in <a
href="https://github.com/rustls/webpki/compare/v/0.103.12...v/0.103.13">compare
view</a></li>
</ul>
</details>
<br />

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 09:01:47 +00:00
Euclid Ye
6592e8512b layout: Replace SVG base fragment rect conditionally to support viewBox (#44420)
As titled.

Testing: Manually tested with multiple real websites with viewbox in
svg.
It looked terrible before, but now looking good!
New passing in WPT.

Partially addresses: #38985

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-22 07:53:59 +00:00
Jonathan Schwender
97c08a6f95 net: Optimize initial TLS connection (#44242)
By touching the crypto provider, we can force it to gather entropy.
On my linux VM, that moved ~60ms off the critical path (using aws-lc-rs,
but probably any other crypto provider would show similar behavior).
On my Linux workstation it was around ~30ms.

On Linux caching the rustls platform verifier cache optimizes another
50ms. On other platforms this will be cheaper, since
only on some systems all certificates are read. It might make sense to
explore
caching the whole tlsconfig (for websockets), since it looks like we are
just cloning
the same components and then constructing a new tlsconfig, which would
lead to
the same effective component. But that needs more investigation.


Testing: Doesn't change any visible behavior, covered by existing tests.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-22 07:39:59 +00:00
Martin Robinson
09ef444d63 layout: Add placeholders for text carets after finishing a line (#44370)
Instead of readily adding a strut for text carets when processing a line
break, wait until a line is finished. This allows placing a strut on the
final line. In addition to fixing #41338 this will also make it possible
to handle line breaks as a separate kind of text run item so that we can
preserve shaping results between layouts.

In addition, some changes are made in script to ensure that these
placeholders
are never placed for non-textual input elements.

Testing: This change adds a Servo-specific WPT test. Caret rendering
isn't specified.
Fixes: #41338

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-22 06:51:54 +00:00
Taym Haddadi
bdbbe641eb SharedWorker: Add SharedWorker and SharedWorkerGlobalScope WebIDL interfaces (#44375)
Testing: covered by WPT test.
part of https://github.com/servo/servo/issues/7458

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-22 03:28:21 +00:00
dependabot[bot]
d995e90976 build: bump webpki-roots from 1.0.6 to 1.0.7 (#44418)
Bumps [webpki-roots](https://github.com/rustls/webpki-roots) from 1.0.6
to 1.0.7.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/webpki-roots/releases">webpki-roots's
releases</a>.</em></p>
<blockquote>
<h2>1.0.7</h2>
<p>For their April 2026 root store changes, Mozilla has made more
changes than usual:</p>
<blockquote>
<p>These changes are part of Mozilla’s ongoing root store maintenance
under the Mozilla Root Store Policy (MRSP), including <a
href="https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/policy/#74-root-ca-lifecycles">§7.4</a>
(Root CA Lifecycles) and <a
href="https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/policy/#753-transition-plan-for-existing-roots">§7.5.3</a>
(Transition Plans). They reflect a combination of lifecycle-based
transitions, CA operator requests, and alignment with intended
certificate usage, including retiring older or less suitable root
certificates, enforcing clear separation of trust purposes (e.g., TLS
vs. S/MIME), and reducing unnecessary trust surface in the Web PKI
ecosystem. Collectively, these actions help to ensure that root
certificates are relied upon only for their intended and actively
maintained use cases, or are retired in accordance with established
distrust timelines.</p>
</blockquote>
<p>This removes:</p>
<ul>
<li>CN=Certigna O=Dhimyotis</li>
<li>CN=COMODO Certification Authority O=COMODO CA Limited</li>
<li>CN=DigiCert Assured ID Root CA O=DigiCert Inc
OU=www.digicert.com</li>
<li>CN=DigiCert Global Root CA O=DigiCert Inc OU=www.digicert.com</li>
<li>CN=DigiCert High Assurance EV Root CA O=DigiCert Inc
OU=www.digicert.com</li>
<li>CN=FIRMAPROFESIONAL CA ROOT-A WEB O=Firmaprofesional SA</li>
<li>CN=GTS Root R2 O=Google Trust Services LLC</li>
<li>CN=QuoVadis Root CA 2 O=QuoVadis Limited</li>
<li>CN=QuoVadis Root CA 3 O=QuoVadis Limited</li>
<li>CN=Secure Global CA O=SecureTrust Corporation</li>
<li>CN=SecureTrust CA O=SecureTrust Corporation</li>
<li>CN=SwissSign Gold CA - G2 O=SwissSign AG</li>
<li>CN=TeliaSonera Root CA v1 O=TeliaSonera</li>
<li>CN=Trustwave Global Certification Authority O=Trustwave Holdings,
Inc.</li>
<li>CN=Trustwave Global ECC P256 Certification Authority O=Trustwave
Holdings, Inc.</li>
<li>CN=Trustwave Global ECC P384 Certification Authority O=Trustwave
Holdings, Inc.</li>
<li>O=certSIGN OU=certSIGN ROOT CA</li>
</ul>
<p>See <a
href="https://groups.google.com/a/mozilla.org/g/dev-security-policy/c/o1VliD70ctg/m/pY0JBzTlAQAJ?pli=1">their
announcement</a> for more details.</p>
<h2>What's Changed</h2>
<ul>
<li>Take semver-compatible dependency updates by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/116">rustls/webpki-roots#116</a></li>
<li>Take semver-compatible dependency updates by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/117">rustls/webpki-roots#117</a></li>
<li>Take semver-compatible updates by <a
href="https://github.com/ctz"><code>@​ctz</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/118">rustls/webpki-roots#118</a></li>
<li>Prepare 1.0.7 by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/120">rustls/webpki-roots#120</a></li>
<li>Update dependencies by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/119">rustls/webpki-roots#119</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7">https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="be948464fd"><code>be94846</code></a>
Update dependencies (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/119">#119</a>)</li>
<li><a
href="76476f91c9"><code>76476f9</code></a>
Prepare 1.0.7 (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/120">#120</a>)</li>
<li><a
href="ed392f437c"><code>ed392f4</code></a>
Take semver-compatible updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/118">#118</a>)</li>
<li><a
href="ec8b744a63"><code>ec8b744</code></a>
Take semver-compatible dependency updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/117">#117</a>)</li>
<li><a
href="84a0c23ef2"><code>84a0c23</code></a>
Take semver-compatible dependency updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/116">#116</a>)</li>
<li>See full diff in <a
href="https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=webpki-roots&package-manager=cargo&previous-version=1.0.6&new-version=1.0.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 01:06:43 +00:00
dependabot[bot]
4d56440d4e build: bump bpaf from 0.9.24 to 0.9.25 (#44416)
Bumps [bpaf](https://github.com/pacak/bpaf) from 0.9.24 to 0.9.25.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pacak/bpaf/blob/master/Changelog.md">bpaf's
changelog</a>.</em></p>
<blockquote>
<h2>bpaf [0.9.25] - 2026-04-15</h2>
<ul>
<li>Change rendering of an adjacent block in Markdown - this is no
longer a <code>###</code>
but a regular line item instead. Header messes up with generated
navigation on
some pages</li>
<li><code>app_name</code> - parser that extracts the executable
name</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/pacak/bpaf/commits/v0.9.25">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=bpaf&package-manager=cargo&previous-version=0.9.24&new-version=0.9.25)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 01:01:38 +00:00
dependabot[bot]
c75eea95c3 build: bump webpki-root-certs from 1.0.6 to 1.0.7 (#44415)
Bumps [webpki-root-certs](https://github.com/rustls/webpki-roots) from
1.0.6 to 1.0.7.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/webpki-roots/releases">webpki-root-certs's
releases</a>.</em></p>
<blockquote>
<h2>1.0.7</h2>
<p>For their April 2026 root store changes, Mozilla has made more
changes than usual:</p>
<blockquote>
<p>These changes are part of Mozilla’s ongoing root store maintenance
under the Mozilla Root Store Policy (MRSP), including <a
href="https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/policy/#74-root-ca-lifecycles">§7.4</a>
(Root CA Lifecycles) and <a
href="https://www.mozilla.org/en-US/about/governance/policies/security-group/certs/policy/#753-transition-plan-for-existing-roots">§7.5.3</a>
(Transition Plans). They reflect a combination of lifecycle-based
transitions, CA operator requests, and alignment with intended
certificate usage, including retiring older or less suitable root
certificates, enforcing clear separation of trust purposes (e.g., TLS
vs. S/MIME), and reducing unnecessary trust surface in the Web PKI
ecosystem. Collectively, these actions help to ensure that root
certificates are relied upon only for their intended and actively
maintained use cases, or are retired in accordance with established
distrust timelines.</p>
</blockquote>
<p>This removes:</p>
<ul>
<li>CN=Certigna O=Dhimyotis</li>
<li>CN=COMODO Certification Authority O=COMODO CA Limited</li>
<li>CN=DigiCert Assured ID Root CA O=DigiCert Inc
OU=www.digicert.com</li>
<li>CN=DigiCert Global Root CA O=DigiCert Inc OU=www.digicert.com</li>
<li>CN=DigiCert High Assurance EV Root CA O=DigiCert Inc
OU=www.digicert.com</li>
<li>CN=FIRMAPROFESIONAL CA ROOT-A WEB O=Firmaprofesional SA</li>
<li>CN=GTS Root R2 O=Google Trust Services LLC</li>
<li>CN=QuoVadis Root CA 2 O=QuoVadis Limited</li>
<li>CN=QuoVadis Root CA 3 O=QuoVadis Limited</li>
<li>CN=Secure Global CA O=SecureTrust Corporation</li>
<li>CN=SecureTrust CA O=SecureTrust Corporation</li>
<li>CN=SwissSign Gold CA - G2 O=SwissSign AG</li>
<li>CN=TeliaSonera Root CA v1 O=TeliaSonera</li>
<li>CN=Trustwave Global Certification Authority O=Trustwave Holdings,
Inc.</li>
<li>CN=Trustwave Global ECC P256 Certification Authority O=Trustwave
Holdings, Inc.</li>
<li>CN=Trustwave Global ECC P384 Certification Authority O=Trustwave
Holdings, Inc.</li>
<li>O=certSIGN OU=certSIGN ROOT CA</li>
</ul>
<p>See <a
href="https://groups.google.com/a/mozilla.org/g/dev-security-policy/c/o1VliD70ctg/m/pY0JBzTlAQAJ?pli=1">their
announcement</a> for more details.</p>
<h2>What's Changed</h2>
<ul>
<li>Take semver-compatible dependency updates by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/116">rustls/webpki-roots#116</a></li>
<li>Take semver-compatible dependency updates by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/117">rustls/webpki-roots#117</a></li>
<li>Take semver-compatible updates by <a
href="https://github.com/ctz"><code>@​ctz</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/118">rustls/webpki-roots#118</a></li>
<li>Prepare 1.0.7 by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/120">rustls/webpki-roots#120</a></li>
<li>Update dependencies by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki-roots/pull/119">rustls/webpki-roots#119</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7">https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="be948464fd"><code>be94846</code></a>
Update dependencies (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/119">#119</a>)</li>
<li><a
href="76476f91c9"><code>76476f9</code></a>
Prepare 1.0.7 (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/120">#120</a>)</li>
<li><a
href="ed392f437c"><code>ed392f4</code></a>
Take semver-compatible updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/118">#118</a>)</li>
<li><a
href="ec8b744a63"><code>ec8b744</code></a>
Take semver-compatible dependency updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/117">#117</a>)</li>
<li><a
href="84a0c23ef2"><code>84a0c23</code></a>
Take semver-compatible dependency updates (<a
href="https://redirect.github.com/rustls/webpki-roots/issues/116">#116</a>)</li>
<li>See full diff in <a
href="https://github.com/rustls/webpki-roots/compare/v/1.0.6...v/1.0.7">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=webpki-root-certs&package-manager=cargo&previous-version=1.0.6&new-version=1.0.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 00:52:56 +00:00
dependabot[bot]
4322792c84 build: bump h2 from 0.4.12 to 0.4.13 (#44414)
Bumps [h2](https://github.com/hyperium/h2) from 0.4.12 to 0.4.13.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/hyperium/h2/releases">h2's
releases</a>.</em></p>
<blockquote>
<h2>v0.4.13</h2>
<h2>What's Changed</h2>
<ul>
<li>Implement HTTP/2 informational responses (1xx) support by <a
href="https://github.com/apu031"><code>@​apu031</code></a> in <a
href="https://redirect.github.com/hyperium/h2/pull/865">hyperium/h2#865</a></li>
<li>fix: Unparent connection span by <a
href="https://github.com/Jesse-Bakker"><code>@​Jesse-Bakker</code></a>
in <a
href="https://redirect.github.com/hyperium/h2/pull/868">hyperium/h2#868</a></li>
<li>fix: auto-release padding from DATA frames by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/h2/pull/869">hyperium/h2#869</a></li>
<li>fix: do not assign capacity for pending streams by <a
href="https://github.com/benjaminp"><code>@​benjaminp</code></a> in <a
href="https://redirect.github.com/hyperium/h2/pull/860">hyperium/h2#860</a></li>
<li>perf: reduce huffman decode table size by <a
href="https://github.com/ariaandika"><code>@​ariaandika</code></a> in <a
href="https://redirect.github.com/hyperium/h2/pull/871">hyperium/h2#871</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/Jesse-Bakker"><code>@​Jesse-Bakker</code></a>
made their first contribution in <a
href="https://redirect.github.com/hyperium/h2/pull/868">hyperium/h2#868</a></li>
<li><a
href="https://github.com/ariaandika"><code>@​ariaandika</code></a> made
their first contribution in <a
href="https://redirect.github.com/hyperium/h2/pull/871">hyperium/h2#871</a></li>
<li><a href="https://github.com/apu031"><code>@​apu031</code></a> made
their first contribution in <a
href="https://redirect.github.com/hyperium/h2/pull/865">hyperium/h2#865</a></li>
<li><a href="https://github.com/benjaminp"><code>@​benjaminp</code></a>
made their first contribution in <a
href="https://redirect.github.com/hyperium/h2/pull/860">hyperium/h2#860</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/hyperium/h2/compare/v0.4.12...v0.4.13">https://github.com/hyperium/h2/compare/v0.4.12...v0.4.13</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/hyperium/h2/blob/master/CHANGELOG.md">h2's
changelog</a>.</em></p>
<blockquote>
<h1>0.4.13 (January 5, 2026)</h1>
<ul>
<li>Add support for 1xx informational responses on client and server
side.</li>
<li>Fix auto-releasing of padding bytes of DATA frames for flow control
windows.</li>
<li>Fix to stop assigning capacity to pending streams which can't use it
yet.</li>
<li>Fix tracing to not grab the parent for the connection span.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="2aeb81fdb5"><code>2aeb81f</code></a>
v0.4.13</li>
<li><a
href="5f40d38f5b"><code>5f40d38</code></a>
fix: do not assign capacity for pending streams (<a
href="https://redirect.github.com/hyperium/h2/issues/860">#860</a>)</li>
<li><a
href="803d8cd1c6"><code>803d8cd</code></a>
ci: adjust pinned dependencies in msrv job (<a
href="https://redirect.github.com/hyperium/h2/issues/873">#873</a>)</li>
<li><a
href="e38678b1e2"><code>e38678b</code></a>
feat: implement HTTP/2 informational responses support (<a
href="https://redirect.github.com/hyperium/h2/issues/865">#865</a>)</li>
<li><a
href="0fe6457f7e"><code>0fe6457</code></a>
perf: Reduce huffman decode table size (<a
href="https://redirect.github.com/hyperium/h2/issues/871">#871</a>)</li>
<li><a
href="e793b24b15"><code>e793b24</code></a>
fix: auto-release padding from DATA frames (<a
href="https://redirect.github.com/hyperium/h2/issues/869">#869</a>)</li>
<li><a
href="7c9a87487d"><code>7c9a874</code></a>
fix: Unparent connection span (<a
href="https://redirect.github.com/hyperium/h2/issues/868">#868</a>)</li>
<li><a
href="c342e3f18f"><code>c342e3f</code></a>
ci: pin indexmap and tracing for msrv job (<a
href="https://redirect.github.com/hyperium/h2/issues/866">#866</a>)</li>
<li><a
href="b9d5397bd7"><code>b9d5397</code></a>
test: window update stream errors count towards local max (<a
href="https://redirect.github.com/hyperium/h2/issues/859">#859</a>)</li>
<li>See full diff in <a
href="https://github.com/hyperium/h2/compare/v0.4.12...v0.4.13">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=h2&package-manager=cargo&previous-version=0.4.12&new-version=0.4.13)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 00:47:19 +00:00
dependabot[bot]
a65769ae98 build: bump glslopt from 0.1.12 to 0.1.13 (#44413)
Bumps [glslopt](https://github.com/jamienicol/glslopt-rs) from 0.1.12 to
0.1.13.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/jamienicol/glslopt-rs/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=glslopt&package-manager=cargo&previous-version=0.1.12&new-version=0.1.13)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-22 00:32:50 +00:00
Martin Robinson
bec5a6ce37 layout: Simplify the way characters are iterated when segmeting text (#44400)
This is a minor adjustment from #44276 that makes the way characters are
iterated easier to read.

Testing: This should not change behavior so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-21 21:11:48 +00:00
Tim van der Lippe
138e7be47e script: Achieve failure parity with other browsers for underline command (#44390)
With these changes, we now fail the minimum set of tests. That is to
say: we don't fail any test that no other browser fails. All test
failures therefore match at least 1 other browser.

The one exception is the updated test expectation. That's because all
browsers fail this test in the exact same way, hence updating the
expectation. We fail it, since I don't know how browsers reach to that
point. I think it's related to traversal of the contained children and
the order that they are traversed in. Unfortunately my attempts at
fixing that have not been fruitful, so leaving that one for now.

Part of #25005

Testing: WPT

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
Co-authored-by: Martin Robinson <martin@abandonedwig.info>
2026-04-21 17:00:40 +00:00
Narfinger
617c9c0162 script: JSContextify dom/css partially (#44406)
This JSContextifies parts of dom/css directory.

Testing: Compilation is the test.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-21 16:46:06 +00:00
Narfinger
99899612cb net: Split ResourceTimings into separate file and create batch attribute setting (#44395)
ResourceFetchTimings are set throughout the methods in http_loader.rs.
These methods are already very complicated, so having multiple times
`context.timings.lock().set_attribute()` can be quite distracting to
understanding.

This introduces ResourceFetchTimingsContainer structure which has the
lock inside and allows setting multiple attributes to clean up the code
in http_loader.

Testing: This is a refactor and does not change functionality.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-21 16:28:00 +00:00
atbrakhi
f8c97cd609 devtools: Always pass ownPropertiesLength to devtools (#44369)
Always pass `ownPropertiesLength` to devtools

Testing: All tests are passing
Fixes: part of #39858

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-21 16:26:20 +00:00
Manuel Rego
2cdbada97b Template for roadmap issues (#44398)
As discussed on
[Zulip](https://servo.zulipchat.com/#narrow/channel/263398-general/topic/Roadmap/with/580266351),
this is a new template for tracking roadmap issues.

Testing: No needed, just a GitHub issue template.

Signed-off-by: Manuel Rego Casasnovas <rego@igalia.com>
2026-04-21 14:41:34 +00:00
Taym Haddadi
5ac8bf4db3 Implement StorageManager API (#43976)
Add the Storage Standard WebIDL for NavigatorStorage and StorageManager,
wire navigator.storage on Window and Worker, and implement persisted(),
persist(), and estimate().


Testing: covered by WP test.
part of #39100

fixes #39101

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-21 13:41:58 +00:00
Shubham Gupta
d1e3e8080c script: Correctly apply resource timing buffer limit (#44228)
Strictly follow the
[specs](https://w3c.github.io/resource-timing/#performance-can-add-resource-timing-entry)

Also fires the performance resource timing earlier to
match WPT expectations.

Testing: More WPT tests Passed.

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-21 11:17:11 +00:00
Kingsley Yung
4a5fe14788 script: Canonicalization of sanitizer configuration (#44335)
Implement the canonicalization of sanitizer configuration, along with
the canonicalization of element with attributes, element, attribute and
name. They are implemented for the `SanitizerConfig`,
`SanitizerElementWithAttributes`, `SanitizerElement` and
`SanitizerAttribute`, through the `SantiizerConfigAlgorithm`,
`Canonicalization` and `NameCanonicalization` trait.

Note that, in the canonicalization of sanitizer configuration, the steps
related to processing instructions are marked as TODO. The feature of
supporting process instructions has just been added to the specification
recently, and the WPT tests are not yet in place. We will add this
support once the tests are ready.

`SanitizerElementWithAttributes`, `SanitizerElement` and
`SanitizerAttribute` are unions of string and dictionary. This makes
accessing its member fields cumbersome. So, the `NameMember` and
`AttributeMember` trait are added to provide helper function for them to
reduce boilerplate code.

Specification:
-
https://wicg.github.io/sanitizer-api/#sanitizer-canonicalize-the-configuration
-
https://wicg.github.io/sanitizer-api/#canonicalize-a-sanitizer-element-with-attributes
- https://wicg.github.io/sanitizer-api/#canonicalize-a-sanitizer-element
-
https://wicg.github.io/sanitizer-api/#canonicalize-a-sanitizer-attribute
- https://wicg.github.io/sanitizer-api/#canonicalize-a-sanitizer-name

Testing: Covered by WPT tests in `sanitizer-api/` subdirectory.
Fixes: Part of #43948

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-21 10:45:39 +00:00
dependabot[bot]
9ba9916bad build: bump aws-lc-rs from 1.16.2 to 1.16.3 (#44379)
Bumps [aws-lc-rs](https://github.com/aws/aws-lc-rs) from 1.16.2 to
1.16.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/aws/aws-lc-rs/releases">aws-lc-rs's
releases</a>.</em></p>
<blockquote>
<h2>aws-lc-rs v1.16.3</h2>
<h2>What's Changed</h2>
<ul>
<li>Key length validation in <code>UnboundCipherKey::new()</code> now
enforced at runtime by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1092">aws/aws-lc-rs#1092</a>
<ul>
<li>The documented error on key length mismatch was never actually
checked. Streaming cipher constructors also relied on
<code>debug_assert_eq!</code> which gets stripped in release builds —
these are now runtime checks.</li>
</ul>
</li>
<li>Support MSAN and TSAN sanitizer builds via
<code>AWS_LC_SYS_SANITIZER</code> environment variable by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1100">aws/aws-lc-rs#1100</a>
<ul>
<li>Accepts <code>asan</code>, <code>msan</code>, or <code>tsan</code>.
The existing <code>asan</code> feature flag continues to work.</li>
</ul>
</li>
</ul>
<h3>Build Improvements</h3>
<ul>
<li>Follow symlinks when classifying include directory entries by <a
href="https://github.com/cmtm"><code>@​cmtm</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1071">aws/aws-lc-rs#1071</a>
<ul>
<li>Fixes builds under Bazel (and other build systems) where source
files in <code>CARGO_MANIFEST_DIR</code> are symlinks into a
content-addressable store.</li>
</ul>
</li>
<li>Improve clang-cl discovery for Windows ARM64 builds by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1060">aws/aws-lc-rs#1060</a>
<ul>
<li>The build script now discovers <code>clang-cl</code> inside Visual
Studio installations rather than requiring it on <code>PATH</code>.</li>
</ul>
</li>
<li>Fix Windows ARM64 FIPS build: pass correct architecture to
<code>vcvarsall.bat</code> by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1075">aws/aws-lc-rs#1075</a></li>
<li>Strip LTO flags from CFLAGS for FIPS builds by <a
href="https://github.com/skmcgrail"><code>@​skmcgrail</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1087">aws/aws-lc-rs#1087</a>
<ul>
<li>Build environments like RPM mock chroots (e.g. AL2023) that export
<code>-flto=auto</code> in CFLAGS would break the FIPS delocator
pipeline.</li>
</ul>
</li>
<li>MSVC: Fix builtin swap intrinsic check to avoid link-time failures
by <a
href="https://github.com/walter-zeromatter"><code>@​walter-zeromatter</code></a>
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1086">aws/aws-lc-rs#1086</a></li>
<li>MSVC: Add jitterentropy <code>src</code> subdirectory to include
search path by <a
href="https://github.com/walter-zeromatter"><code>@​walter-zeromatter</code></a>
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1085">aws/aws-lc-rs#1085</a></li>
<li>MSVC: Use 8.3 short paths on Windows to avoid MAX_PATH limits by <a
href="https://github.com/walter-zeromatter"><code>@​walter-zeromatter</code></a>
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1081">aws/aws-lc-rs#1081</a></li>
</ul>
<h3>Issues Being Closed</h3>
<ul>
<li>Clarify that build needs to run from VS Developer shell for Windows
builds -- <a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1056">aws/aws-lc-rs#1056</a></li>
<li>Add MSAN (MemorySanitizer) support, matching existing ASAN support
-- <a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1077">aws/aws-lc-rs#1077</a></li>
<li>aws-lc-sys fails to compile on iOS arm64 with Clang 15.0.7:
undeclared ioctl in urandom.c -- <a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1068">aws/aws-lc-rs#1068</a></li>
</ul>
<h2>Other Merged PRs</h2>
<ul>
<li>Prepare aws-lc-sys v0.39.1 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1080">aws/aws-lc-rs#1080</a></li>
<li>Bump aws-lc-fips-sys to v0.13.14 by <a
href="https://github.com/skmcgrail"><code>@​skmcgrail</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1088">aws/aws-lc-rs#1088</a></li>
<li>CI: Harden artifact workflows and update action versions by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1091">aws/aws-lc-rs#1091</a></li>
<li>Bump actions/checkout from 4 to 6 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1096">aws/aws-lc-rs#1096</a></li>
<li>Bump actions/setup-go from 4 to 6 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1095">aws/aws-lc-rs#1095</a></li>
<li>Bump codecov/codecov-action from 4 to 6 by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1094">aws/aws-lc-rs#1094</a></li>
<li>Prepare aws-lc-rs v1.16.3 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1098">aws/aws-lc-rs#1098</a></li>
<li>Prepare aws-lc-sys v0.40.0 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1099">aws/aws-lc-rs#1099</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/cmtm"><code>@​cmtm</code></a> made their
first contribution in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1071">aws/aws-lc-rs#1071</a></li>
<li><a
href="https://github.com/walter-zeromatter"><code>@​walter-zeromatter</code></a>
made their first contribution in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1086">aws/aws-lc-rs#1086</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.2...v1.16.3">https://github.com/aws/aws-lc-rs/compare/v1.16.2...v1.16.3</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f75bae5248"><code>f75bae5</code></a>
Support MSAN and TSAN sanitizer builds via environment variable (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1100">#1100</a>)</li>
<li><a
href="64677e8fb3"><code>64677e8</code></a>
Improve clang-cl discovery for Windows ARM64 builds (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1060">#1060</a>)</li>
<li><a
href="e2e3e15bbd"><code>e2e3e15</code></a>
Prepare aws-lc-sys v0.40.0 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1099">#1099</a>)</li>
<li><a
href="e0ec10024d"><code>e0ec100</code></a>
Prepare aws-lc-rs v1.16.3 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1098">#1098</a>)</li>
<li><a
href="46ed951c9c"><code>46ed951</code></a>
MSVC Fix: use 8.3 short paths on Windows to avoid MAX_PATH limits in
building...</li>
<li><a
href="27c4cca361"><code>27c4cca</code></a>
Add jitterentropy src subdirectory to include search path (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1085">#1085</a>)</li>
<li><a
href="6b30158f0b"><code>6b30158</code></a>
MSVC Fix: Improve bad intrinsic check on msvc (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1086">#1086</a>)</li>
<li><a
href="5a3f9ca4ba"><code>5a3f9ca</code></a>
Bump codecov/codecov-action from 4 to 6 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1094">#1094</a>)</li>
<li><a
href="6a7b379faa"><code>6a7b379</code></a>
Bump actions/setup-go from 4 to 6 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1095">#1095</a>)</li>
<li><a
href="f7cb890331"><code>f7cb890</code></a>
Bump actions/checkout from 4 to 6 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1096">#1096</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.2...v1.16.3">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=aws-lc-rs&package-manager=cargo&previous-version=1.16.2&new-version=1.16.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-21 02:37:32 +00:00
dependabot[bot]
93e413093f build: bump tokio from 1.52.0 to 1.52.1 in the tokio-rs-related group (#44377)
Bumps the tokio-rs-related group with 1 update:
[tokio](https://github.com/tokio-rs/tokio).

Updates `tokio` from 1.52.0 to 1.52.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tokio/releases">tokio's
releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.52.1</h2>
<h1>1.52.1 (April 16th, 2026)</h1>
<h2>Fixed</h2>
<ul>
<li>runtime: revert <a
href="https://redirect.github.com/tokio-rs/tokio/issues/7757">#7757</a>
to fix [a regression]<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8056">#8056</a>
that causes <code>spawn_blocking</code> to hang (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8057">#8057</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/tokio-rs/tokio/issues/7757">#7757</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7757">tokio-rs/tokio#7757</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8056">#8056</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8056">tokio-rs/tokio#8056</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8057">#8057</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8057">tokio-rs/tokio#8057</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="905c146aed"><code>905c146</code></a>
chore: prepare to release v1.52.1 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8059">#8059</a>)</li>
<li><a
href="56aaa43e91"><code>56aaa43</code></a>
rt: revert <a
href="https://redirect.github.com/tokio-rs/tokio/issues/7757">#7757</a>
to fix regression in <code>spawn_blocking</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8057">#8057</a>)</li>
<li><a
href="57ff47ab58"><code>57ff47a</code></a>
ci: update <code>trybuild</code> to expect output from rustc 1.95.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8058">#8058</a>)</li>
<li><a
href="812de3e134"><code>812de3e</code></a>
ci: bump taiki-e/cache-cargo-install-action from 1 to 3 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8053">#8053</a>)</li>
<li><a
href="ba82e73c7b"><code>ba82e73</code></a>
ci: use Dependabot to keep github actions up to date (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8052">#8052</a>)</li>
<li><a
href="2e85f9ddf8"><code>2e85f9d</code></a>
ci: replace cirrus-ci with freebsd-vm (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8041">#8041</a>)</li>
<li><a
href="a7e1cd8ff8"><code>a7e1cd8</code></a>
ci: update GitHub Actions workflows to use latest tool versions (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8047">#8047</a>)</li>
<li>See full diff in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-1.52.0...tokio-1.52.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio&package-manager=cargo&previous-version=1.52.0&new-version=1.52.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-21 02:23:35 +00:00
dependabot[bot]
c04dc7e77b build: bump uuid from 1.23.0 to 1.23.1 (#44380)
Bumps [uuid](https://github.com/uuid-rs/uuid) from 1.23.0 to 1.23.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/uuid-rs/uuid/releases">uuid's
releases</a>.</em></p>
<blockquote>
<h2>v1.23.1</h2>
<h2>What's Changed</h2>
<ul>
<li>Remove deprecated <code>msrv</code> feature from wasm-bindgen
dependency by <a
href="https://github.com/guybedford"><code>@​guybedford</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/877">uuid-rs/uuid#877</a></li>
<li>fix: Timestamp::from_gregorian deprecation note by <a
href="https://github.com/aznashwan"><code>@​aznashwan</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/878">uuid-rs/uuid#878</a></li>
<li>Prepare for 1.23.1 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/879">uuid-rs/uuid#879</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/guybedford"><code>@​guybedford</code></a> made
their first contribution in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/877">uuid-rs/uuid#877</a></li>
<li><a href="https://github.com/aznashwan"><code>@​aznashwan</code></a>
made their first contribution in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/878">uuid-rs/uuid#878</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/uuid-rs/uuid/compare/v1.23.0...v1.23.1">https://github.com/uuid-rs/uuid/compare/v1.23.0...v1.23.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="ca0c85fe21"><code>ca0c85f</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/879">#879</a> from
uuid-rs/cargo/v1.23.1</li>
<li><a
href="b4db015d34"><code>b4db015</code></a>
prepare for 1.23.1 release</li>
<li><a
href="771069da63"><code>771069d</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/878">#878</a> from
aznashwan/fix-from-gregorian-deprecation-note</li>
<li><a
href="80994a2015"><code>80994a2</code></a>
fix: Timestamp::from_gregorian deprecation note</li>
<li><a
href="90c5be8f17"><code>90c5be8</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/877">#877</a> from
guybedford/remove-wasm-bindgen-msrv</li>
<li><a
href="8b8c4f4f85"><code>8b8c4f4</code></a>
Remove deprecated feature from wasm-bindgen dependency</li>
<li>See full diff in <a
href="https://github.com/uuid-rs/uuid/compare/v1.23.0...v1.23.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=uuid&package-manager=cargo&previous-version=1.23.0&new-version=1.23.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-21 01:54:12 +00:00
dependabot[bot]
e33b20e445 build: bump orbclient from 0.3.51 to 0.3.53 (#44382)
Bumps orbclient from 0.3.51 to 0.3.53.


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=orbclient&package-manager=cargo&previous-version=0.3.51&new-version=0.3.53)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-21 01:38:18 +00:00
dependabot[bot]
f41e1513d9 build: bump atomic_refcell from 0.1.13 to 0.1.14 (#44381)
Bumps [atomic_refcell](https://github.com/mozilla/atomic_refcell) from
0.1.13 to 0.1.14.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/mozilla/atomic_refcell/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=atomic_refcell&package-manager=cargo&previous-version=0.1.13&new-version=0.1.14)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-21 01:28:00 +00:00
Simon Martin
d4a63f87ed webgl: Validate dimensions in TexImage3D properly with level (#44367)
The tex-3d-size-limit.html test verifies that TexImage3D errors out with
gl.INVALID_VALUE if the width / height / depth parameters are greater
than gl.MAX_3D_TEXTURE_SIZE / 2 ** level, in accordance with the mipmap
levels definition.

This patch adds this checks, and fixes a s/depth/level/ typo, and should
stabilize tex-3d-size-limit.html: all its sub-tests will succeed until
the first call to (not implemented) TexSubImage3D, that will end the
test.

It's still possible for the test to fail on environments where
gl.MAX_3D_TEXTURE_SIZE is not 8192 (because the numbering of tests will
be different), and this will have to be until we make all sub-tests
pass, i.e. TexSubImage3D is implemented.

Testing: A bunch of expected failures are removed.
Fixes: https://github.com/servo/servo/issues/44280

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-04-20 14:19:41 +00:00
Gae24
85eda69130 script: Complete script_module &mut JSContext migration (#44368)
Switch the remaining `SafeJSContext` usages to `&mut JSContext` inside
script_module.rs

Testing: It compiles.
Part of #40600

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-20 09:12:28 +00:00
Tim van der Lippe
4184b11362 script: Iterate over correct collections when moving (#44347)
Several times, we first need to capture the relevant nodes, perform a
step and then iterate over the nodes. Previously, we would iterate over
it, but the iterator could have moved, hence we would jump over some
nodes.

Instead, capture these beforehand and then iterate over them.

Also fixes the issue where text-decoration wasn't properly checked,
since its a shorthand for 3 longhands. And a PropertyDeclarationBlock
only has longhands.

The two regressions are for tests that now generate the correct HTML,
but their ranges are incorrectly moved from the `a` to the `b`. I went
through the relevant algorithms and didn't spot the mistake. To keep on
making babysteps towards a full implementation, I will tackle these in a
follow-up. These algorithms are already difficult enough to reason
about.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-19 21:51:14 +00:00
Freya Arbjerg
c14b7d66d0 devtools: Replace dead links in debugger.js (#44358)
This replaces dead firefox-source-docs.mozilla.org links in debugger.js 

Testing: Not relevant for comments
Fixes: No issue

Signed-off-by: Freya Arbjerg <git@arbjerg.dev>
2026-04-19 19:25:32 +00:00
Nico Burns
2c91740059 Use our own http server for the webdriver server (#44338)
Helps with: https://github.com/servo/servo/issues/38776. Reduces total
Servo crate count by 7 (977 -> 970).

This PR simply:
- Disables the `server` feature in the `webdriver` crate
- Vendors the implementation of the server from the `webdriver` crate
- Updates dependencies + fixes code to work with new versions

Unfortunately `webdriver` depends on `http` even with the `server`
feature disabled, so we still end up with duplicate versions of `http`.
But at least the duplicate `hyper` is eliminated. Future work could
change the implementation to e.g. move away from `warp` or similar.

Testing: WPT tests use webdriver, so this should be exercised heavily by
those tests.

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
2026-04-19 15:42:45 +00:00
Simon Wülker
18d3ad5252 script: Support shadowrootslotassignment on template elements (#44246)
This brings up to date with the specification for declarative shadow
roots: https://github.com/whatwg/html/pull/12267.

The `shadowrootslotassignment` attribute on `<template>` elements
specifies the slot assignment mode used by the declarative shadow root
created by the template.

Testing: New tests start to pass

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-19 14:22:06 +00:00
Euclid Ye
eea0c586c0 ci: Set LLVM_OBJDUMP env-var when compiling libservo with MSRV in linux (#44352)
[Sometimes](https://github.com/servo/servo/actions/runs/24611835766/job/71967504931#step:10:1076),
CI fails to link pre-built archive, and have to build from source.
Previously this always fail as llvm-objdump is not found.

Testing: Successful [try
run](https://github.com/yezhizhen/servo/actions/runs/24626909297) when
building from source.
Fixes: #44351

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-19 13:44:49 +00:00
Simon Martin
d5dab9e353 webgl: Update stable test expectations to close intermittent issue (#44344)
Since 5634eab8cc, tex-3d-size-limit.html is not crashing anymore, and
even though I updated the test expectations and the test is consistently
passing locally at that commit, it's now failing some tests that should
have failed since the beginning (since there's no associated check in
the code).

I'm not sure why things seem to work with the previous test expectations
update and will follow-up, but in the meanwhile let's update them.

With this, things seem to be pretty good:
```
$ ./mach test-wpt --dev tests/wpt/webgl/tests/conformance2/textures/misc/tex-3d-size-limit.html --repeat 1000 [...]
web-platform-test
~~~~~~~~~~~~~~~~~
Ran 92000 checks (91000 subtests, 1000 tests)
Expected results: 92000
Unexpected results: 0
OK
```

Testing: Test seems to pass consistently with the updated expectations.
Fixes: https://github.com/servo/servo/issues/44280

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-04-19 08:33:09 +00:00
Josh Matthews
4e267b2f09 net: Update expected Accept-Language header in tests to use current locale. (#44340)
Our choice is to either override the user's locale or updated the
expected result to depend on the locale. Updating the expectation seemed
easier.

Testing: Unit tests pass locally, but CI runs with the en-US locale so
there's no observable difference.
Fixes: #43069

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-19 08:08:01 +00:00
Servo WPT Sync
345fd4573f Sync WPT with upstream (19-04-2026) (#44339)
Automated downstream sync of changes from upstream as of 19-04-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-19 06:08:06 +00:00
Josh Matthews
19354a5b37 net: Update test cookie expiration dates to one century in the future. (#44341)
These dates were chosen 10 years ago, which I'm sure felt like a
reasonably far-future date for a very young web engine. Surprise! We're
still here, so we can be more bold this time.

Testing: Unit tests stop failing.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-19 04:55:05 +00:00
Asish Kumar
678f9d7a47 net: Keep IP cookie buckets separate (#44152)
Use the full IP address as the cookie storage bucket key instead of
passing IP hosts through the public suffix registrable-domain helper.
This prevents unrelated IP hosts that share suffix-like address segments
from sharing a per-host eviction bucket.

Testing: Added `test_ip_cookie_bucket_collision_eviction`; ran `cargo
test -p servo-net --test main test_ip_cookie_bucket_collision_eviction
--locked`.
Fixes: #44097

---------

Signed-off-by: Asish Kumar <officialasishkumar@gmail.com>
2026-04-18 19:55:19 +00:00
Tim van der Lippe
39a3aa991f script: Generate more correct HTML for underline command (#44331)
This makes further steps to generate the correct HTML. Some tests now
have more appropriate HTML, but are not fully passing yet as they
require more fixes. I also missed the fact that there is actually an
algorithm to set the tag name, which I thought didn't exist. Therefore,
also correctly implement that.

Part of #25005

Testing: WPT

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-04-18 18:37:26 +00:00
rovertrack
8dfb6be75b layout: Produce an empty display list when the Document element is removed (#44133)
Previously, when the `Document` element was removed, no further display
list updates would be sent to paint. This change makes it so that when
the `Document` element is removed a single new empty display list is
sent.

Testing: This change adds a new WPT test .
Fixes: #44101

---------

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-18 16:48:29 +00:00
Gae24
2b21c528ea script: Clean up prepare the script element related code and remove ModuleOwner (#44179)
Drop the `ModuleOwner` logic in favour of closures passed down by the
script fetching initiator.
When processing inline module scripts a task in now queued on the
networking task source. Since `Rc<ModuleTree>` is not `Send`, a `result`
field is now introduced to `HTMLScriptElement`, which is initialized
before queueing the task.

This slightly improves `inline-async-inserted-execorder.html`, which now
fails at the fourth assertion instead of stopping at the second one (the
inline module script with no dependencies still resolves after the one
that has a parse error).

Testing: Covered by existing tests.

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-18 15:58:33 +00:00
Nico Burns
87819c5f00 layout: Fix x/y offset not being set for direct abspos grid children (#44324)
Previously absolutely positioned direct children of a CSS Grid had their
position (relative to their parent) hardcoded to (0, 0). This PR changes
that to correctly propagate the position computed by Taffy.

Testing: WPT tests.

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
2026-04-18 14:31:09 +00:00
Euclid Ye
d3932a2118 Android: Fix black screen when exiting menu or resuming activity in lifecycle (#44327)
We should request repaint for the platform window when `resume_painting`
or entering
[Resumed](https://developer.android.com/guide/components/activities/activity-lifecycle#onresume)
state in Android activity lifecycle.

Fixes: #44300
Fixes: #40632
Fixes: #39737
Testing: Manually tested with following video proof


https://github.com/user-attachments/assets/046c045d-12d1-43fa-9387-fc504cc4bfe5

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-18 06:20:30 +00:00
webbeef
d16c9984f6 script: registration mechanism for selective broadcast from constellation (#43124)
This introduces a mechanism that let script threads register and
unregister themselves from receiving messages from the constellation.
This is useful when only globals with event listeners or callbacks will
process some message types.
The first migrated API is the webstorage 'storage' event. This patch
ensures that we only send IPC to same origin globals that have an event
handler set.
While we use it for an event here, this is also usable for DOM callbacks
such as the ones used in the Geolocation API.

Testing: optimization with no tests regression:
https://github.com/webbeef/servo/actions/runs/22880845745

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-04-18 02:17:10 +00:00
Euclid Ye
5d91793d1c net: Fix link, reduce visibility, add TODO for Response::url (#44274)
I wanted to follow up to #43987, but don't know how to proceed
meaningfully :(

- Reduce visibility
- Add TODO for `Response::url`. This should be removed and determined by
`url_list` instead.
- Fix some spec link

Testing: Nothing should change as no code change.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-18 01:02:48 +00:00
Martin Robinson
b39d9833a4 script: Cancel animations for non-rendered nodes in script (#44299)
Instead of walking the entire fragment tree to find nodes for which
animations and image animations need to be cancelled, this change moves
that logic to `script`. Now, for each animating node the animation
managers will explicitly ask `layout` if the node is being rendered (or
delegating rendering in the case of CSS animations and transitions).

The main goal here is a performance improvement, elimating roughly 1% of
layout time from the profiler when running the
`flexbox-deeply-nested-column-flow.html` test case. This will almost
certainly be an even better improvement on more complex pages as we are
no longer doing things once per fragment tree entry, but once per
animating node.

There is also a subtle behavior improvement here. Before nodes with
`display: contents` had their animations canceled, but now they are not.
For instance, this test case now works properly:

```html
<!DOCTYPE html>
<style>
@keyframes anim {
  from { color: cyan }
  to { color: magenta }
}
div {
  display: contents;
  animation: anim 1s infinite alternate linear;
}
</style>
```

The new layout query will additionally be useful for other parts of
script that need to answer the same "being rendered" or "delegates
rendering to children" question.

Testing: This change adds a new test and gets one more subtest passing.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-17 21:59:20 +00:00
Narfinger
a908081352 chore: Remove some clippy complains for 1.95 (#44276)
This removes some complains that clippy will have in 1.95.
As this is mostly just match guards, it doesn't update MSRV.

Testing: This is equivalent exchanges, so current WPT would find
anything.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-17 19:55:17 +00:00
Josh Matthews
62f9971a87 script: Log failed script fetch URL. (#44319)
Testing: Can't test for debug logs.
Should assist with diagnosing #26272.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-17 17:35:05 +00:00
batu_hoang
2d445b649d Implement SiteDataManager::cookies_for_url_async (#43794)
Support applications to get cookies asynchronously from embedder.

Testing:
`servo/components/servo/tests/site_data_manager.rs::test_get_cookie_async`

---------

Signed-off-by: batu_hoang <longvatrong111@gmail.com>
2026-04-17 16:38:50 +00:00
Euclid Ye
211a24f181 Revert "storage: use client storage in indexeddb" (#44318)
Reverts servo/servo#43900
cc @gterzian 

There are way too many intermittents.

Fixes: #44317
Fixes: #44316
Fixes: #44310
Fixes: #44306

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-17 16:34:17 +00:00
Narfinger
68ca2808ee net: Refactor obtain_response and split devtools (#44271)
This PR refactors parts of the net crate with one minor functional
change.
Most of the main functions in the net crate are quite long and rather
unwieldly. This PR tries to help make them more understandable.

- Split parts of obtain_response to have the Router callback setup in
another function.
- Move functions related to devtools into another file.
- Add some servo_tracing.
- http_network_or_cache_fetch has another function for append_cache_data
to headers.
- One functional change: previously in obtain_response, we used the
encoded_url via copies and multiple replace calls. We now use the
percent_encode crate which is already included in
content_security_policy to do this a bit more efficiently. In practice
the compiler probably fixed the multiple copies but this is more
straightforward. The output should be identical.

Testing: As this is mostly a refactor compilation is the test. The
percent_encode change is tested in multiple unit tests.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-17 16:29:19 +00:00
Tim van der Lippe
9259a7ed69 script: Set shorthand text-decoration instead of longhand (#44312)
The generated HTML was setting `text-decoration-line` whereas it instead
should set `text-decoration`.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-17 15:38:20 +00:00
Euclid Ye
467fdb1dc0 git: Fix CI by removing wrongly commited FETCH_HEAD (#44309)
This is somehow introduced in #43617. This is causing CI failure.
For whatever reason, this thing should only be in `.git` folder. But
somehow it is at the root?

Also changed `.yml` to avoid ambiguity: we are using revision instead of
path.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-17 15:23:39 +00:00
Martin Robinson
789974975f layout: Remove dependency on xi-unicode (#44303)
This functionality already provided by `icu_properties` which is already
in our dependency graph, so this change allows us to remove one
dependency.

Testing: This should not change behavior, so is covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-17 13:09:44 +00:00
Shubham Gupta
53d7a0e08a script: Generate custom fields also, for interfaces inheriting from PerformanceEntry, from impl_performance_entry_struct! (#44289)
Add definition for generation of custom fields for interfaces inheriting
from PerformanceEntry.

Testing: More WPT Tests Passed

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-17 12:16:52 +00:00
Simon Wülker
fdf1e09a2a style: When animating a property, ignore keyframes that don't declare that property (#43461)
Companion PR for https://github.com/servo/stylo/pull/338 (Refer to that
PR for a proper description)

Testing: This change adds a test
Fixes: https://github.com/servo/servo/issues/41302

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-17 11:32:58 +00:00
Simon Sapin
56345cdab0 layout: Fix which axis to consider for baseline propagation of flex items (#44281)
* When a flex item line participates in baseline alignment, the relevant
baseline must be parallel to the **main axis** (affected by
`flex-direction`) of the flex container.
* When a flex item propagates a baseline to a parent layout (such as for
`display: inline-flex`) the relevant baseline must be parallel to the
**inline axis** (not affected by `flex-direction`) of the flex
container.

See:

* https://drafts.csswg.org/css-flexbox-1/#box-model
* https://drafts.csswg.org/css-flexbox-1/#flex-direction-property
* https://drafts.csswg.org/css-flexbox-1/#baseline-participation
* https://drafts.csswg.org/css-align-3/#baseline-export

Testing: covered by existing WPT tests
Fixes: https://github.com/servo/servo/issues/43687

Signed-off-by: Simon Sapin <simon@igalia.com>
2026-04-17 10:08:26 +00:00
Gregory Terzian
9f81a8f54d storage: use client storage in indexeddb (#43900)
Integrate client storage into indexeddb for the creation and deletion of
databases.

Testing: Existing WPT tests.
Fixes: None

---------

Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com>
2026-04-17 09:53:28 +00:00
Tim van der Lippe
e7c29c3330 script: Check correct element if text-decoration is effective (#44293)
Rather than node, we should check `new_parent` for this. Unfortunately
some regressions, which have been flip-flopping in recent PRs. That's
because underline itself uses its own state to determine what to do.
However, this is a net positive PR that also adheres to the spec, so
it's another step in the right direction.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-17 08:32:08 +00:00
Euclid Ye
aefcd94ee5 build: Upgrade mako to 1.3.11 in uv.lock to fix security alert (#44291)
Fixes: https://github.com/servo/servo/security/dependabot/285

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-17 07:35:09 +00:00
Kingsley Yung
617c28f631 script: Default configuration of sanitizer (#44290)
This patch implements the built-in safe default configuration for
`Sanitizer` constructor.

Specification:
https://wicg.github.io/sanitizer-api/#sanitization-defaults

Testing: Covered by WPT test in
`sanitizer-api/sanitizer-default-config.tentative.html`.
Fixes: Part of #43948

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-17 07:34:38 +00:00
dependabot[bot]
5d5a38048d build: bump mako from 1.2.2 to 1.3.11 (#44286)
Bumps [mako](https://github.com/sqlalchemy/mako) from 1.2.2 to 1.3.11.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/sqlalchemy/mako/releases">mako's
releases</a>.</em></p>
<blockquote>
<h1>1.3.11</h1>
<p>Released: Tue Apr 14 2026</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [template]</strong> Fixed issue in
<code>TemplateLookup</code> where a URI with a double-slash
prefix (e.g. <code>//../../</code>) could bypass the directory traversal
check in
<code>Template</code>, allowing reads of arbitrary files outside of the
template directory. The issue was caused by an inconsistency in how
leading
slashes were stripped between <code>TemplateLookup.get_template()</code>
and
<code>Template</code> initialization.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/434">#434</a></p>
</li>
</ul>
<h1>1.3.10</h1>
<p>Released: Thu Apr 10 2025</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [lexer]</strong> Fix undefined variable errors when
<code>strict_undefined=True</code> when using a
nested list comprehension. Pull request courtesy Sébastien Granjoux.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/418">#418</a></p>
</li>
</ul>
<h1>1.3.9</h1>
<p>Released: Tue Feb 4 2025</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [tests]</strong> Fixed test suite to not rely upon
ancient &quot;future division&quot; statement to
test the <code>Template.future_imports</code> feature.   The test is
replaced with one that tests only the rendering, not the ultimate
effect.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/408">#408</a></p>
</li>
</ul>
<h1>1.3.8</h1>
<p>Released: Sat Dec 7 2024</p>
<h2>bug</h2>
<ul>
<li><strong>[bug] [lexer]</strong> Reverted the fix for <a
href="https://redirect.github.com/sqlalchemy/mako/issues/140">#140</a>
released in Mako 1.3.7 as it produced
regressions in existing user code.</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/sqlalchemy/mako/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=mako&package-manager=uv&previous-version=1.2.2&new-version=1.3.11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-16 22:02:02 +00:00
dependabot[bot]
4dc82fe2c0 build: bump mako from 1.2.2 to 1.3.11 in /python (#44287)
Bumps [mako](https://github.com/sqlalchemy/mako) from 1.2.2 to 1.3.11.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/sqlalchemy/mako/releases">mako's
releases</a>.</em></p>
<blockquote>
<h1>1.3.11</h1>
<p>Released: Tue Apr 14 2026</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [template]</strong> Fixed issue in
<code>TemplateLookup</code> where a URI with a double-slash
prefix (e.g. <code>//../../</code>) could bypass the directory traversal
check in
<code>Template</code>, allowing reads of arbitrary files outside of the
template directory. The issue was caused by an inconsistency in how
leading
slashes were stripped between <code>TemplateLookup.get_template()</code>
and
<code>Template</code> initialization.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/434">#434</a></p>
</li>
</ul>
<h1>1.3.10</h1>
<p>Released: Thu Apr 10 2025</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [lexer]</strong> Fix undefined variable errors when
<code>strict_undefined=True</code> when using a
nested list comprehension. Pull request courtesy Sébastien Granjoux.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/418">#418</a></p>
</li>
</ul>
<h1>1.3.9</h1>
<p>Released: Tue Feb 4 2025</p>
<h2>bug</h2>
<ul>
<li>
<p><strong>[bug] [tests]</strong> Fixed test suite to not rely upon
ancient &quot;future division&quot; statement to
test the <code>Template.future_imports</code> feature.   The test is
replaced with one that tests only the rendering, not the ultimate
effect.</p>
<p>References: <a
href="https://redirect.github.com/sqlalchemy/mako/issues/408">#408</a></p>
</li>
</ul>
<h1>1.3.8</h1>
<p>Released: Sat Dec 7 2024</p>
<h2>bug</h2>
<ul>
<li><strong>[bug] [lexer]</strong> Reverted the fix for <a
href="https://redirect.github.com/sqlalchemy/mako/issues/140">#140</a>
released in Mako 1.3.7 as it produced
regressions in existing user code.</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/sqlalchemy/mako/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=mako&package-manager=pip&previous-version=1.2.2&new-version=1.3.11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-16 21:59:55 +00:00
Tim van der Lippe
d096560b51 script: Correctly handle modifiable elements in contenteditable (#44250)
First of all, the effective command value was wrong, since there is no
relevant CSS property for the underline command. Instead, we should
directly use the text-decoration property. This then allows us to
implement reordering of modifiable elements.

We also need to "change the element to a span", which is quite annoying
to do. Instead, it mimics what would have happened by moving children
and copying attributes.

There are some regressions, but overall this is another big step towards
the right track. The regressions look related to tricky edge cases that
I am not even sure other browsers handle.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-16 20:50:06 +00:00
Martin Robinson
3ffecfb60c wpt: Correct the name of a __dir__.ini metadata file after #44232 (#44260)
This file was renamed incorrectly due to automated renaming of directory
contents.

Testing: This does not seem to change test results, but whether or not
the
option in this `__dir__.ini` file is another issue.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-16 20:36:52 +00:00
Nico Burns
df3f915465 layout: depend on web_atoms rather than html5ever (#44277)
`servo-layout` only depends on `html5ever` for it's atom types which are
now split out into the `web_atoms` crate. This switches the dependency
to `web_atoms` to remove the unncessary dependency

Testing: This just imports the same types from a different crate. So if
it builds, it should work.

Signed-off-by: Nico Burns <nico@nicoburns.com>
2026-04-16 20:36:04 +00:00
Abbas Olanrewaju Sarafa
77e75aaf9e script: Make adjacent errors and console.log messages log in correct order (#44243)
Made adjacent errors and console.log messages log in correct order

Testing: ```./mach test-unit -p servo --
test_console_log_and_error_ordering``` passed.
Fixes: #44204

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-16 20:33:50 +00:00
Ashwin Naren
83eacc517a script: Add messages to all errors in components/script/dom/location.rs (#44282)
Mostly reuses the original error message from #39051, but on the rest of
the methods that require it. Also adds a new error message for
`document_if_same_origin`.

Testing: None
Fixes: Partially #40756

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
2026-04-16 19:00:23 +00:00
Ashwin Naren
b4a569536c servoshell: Remove IndexedDB preference from servo:preferences (#44283)
Since indexeddb is now part of the experimental features list, we can
remove it from the "more experimental" features list.

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
2026-04-16 18:59:28 +00:00
Jonathan Schwender
f77fe5eadd release: Build android in production mode (#44278)
Since https://github.com/servo/servo/pull/44182 production builds for
android are now possible in CI.
Let's unify this, since all other platforms already use production. The
production build is also ~45MB small, which is a huge reduction compared
to the ~159MB our nightly builds have. I didn't investigate further why
the difference is that large, but I installed the production version on
my phone and didn't spot any obvious issues (on servo.org).

[Mach try
android-production](https://github.com/jschwe/servo/actions/runs/24525178123)

Testing: We don't test CI workflows themselves.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-16 18:03:34 +00:00
Oriol Brufau
9ef8fe5e42 layout: Avoid unnecessary borrow in TextRun::segment_text_by_font() (#44279)
No need to borrow `self.inline_styles.style` when the result is already
available as a parameter of the function.

Also, avoid calling `parent_style.get_font()` multiple times.

Testing: Not needed, no behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-04-16 17:17:37 +00:00
Jonathan Schwender
2cb556a87a android: Support custom build profiles (#44182)
Pass the build directory to gradle via an environment variable, to
support custom profiles.
Building the custom profiles already works, but follow-up commands
expect the artifact at the location of the profile.
This allows switching the android release build to production (in a
follow-up PR).

Testing: We don't run any runtime tests for android in CI

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-16 16:22:41 +00:00
eri
7b6f2e5a39 devtools: Use serde structs for ObjectActorMsg (#44262)
Replace previous `serde_json::Value` manual encoding.

Testing: Existing tests pass.
Part of: #39858

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-16 14:01:46 +00:00
Simon Martin
5634eab8cc webgl: check TexImage3D's input data length (#44270)
tex-3d-size-limit.html currently crashes because we don't check that the
input data is large enough, and happily access memory that's not ours if
it's not.

The referenced ticket comes from the fact that we don't systematically
detect a crash (which makes sense if we're (un)lucky), and this patch
eradicates the crash altogether by checking the input buffer size. The
size computation is a (partial) port of WPT's computeImageSizes3D JS
function.

Fixes: https://github.com/servo/servo/issues/42881
Testing: Some expected failures in wpt/webgl can be removed, including a
crash.

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-04-16 13:47:55 +00:00
Martin Robinson
b3fdbf9821 script: Clear style data from detached subtrees when attaching a shadow DOM (#44259)
Instead of just clearing layout data, also clear style data from
descendants that are now no longer part of the flat tree when attaching
shadow DOM. This ensures that Stylo does not try to process them during
restyling. This matches what Gecko does.

Testing: This change adds a crash test and also causes a few subtests
to start passing.
Fixes: #40731.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-16 13:37:21 +00:00
eri
496c5c0e80 devtools: Separate actors into their own files (#44265)
Switch the actors to the register pattern.

Testing: Just a refactor, existing tests pass.
Part of: #43800

Signed-off-by: eri <eri@igalia.com>
2026-04-16 12:34:14 +00:00
Martin Robinson
8da073a80c layout: Cache SameFormattingContextBlock layout results (#42904)
Add a cache for `SameFormattingContextBlock`s: A new kind of cache
is added which allows reusing fragments for
`SameFormattingContextBlock` (the majority of block level elements).
This can reduce the amount of fragment tree construction during
incremental layout (although with a 40 byte overhead per
`SameFormattingContextBlock`).

Testing: This change adds a new Servo-specific WPT test that verifies
that
the minimal number of `Fragment`s are rebuilt after an incremental
layout.
Previously, when running `flexbox-deeply-nested-column-flow.html` from
`tests/blink_perf_tests/perf_tests/layout/`, performance would degrade
with successive test runs. This is due to how slow inline layout is.
This change
removes that progressive degradation, though we may be able to remove
this cache with improvements to inline layout.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-04-16 12:04:39 +00:00
张喜昌
562609f876 mach: Support Visual Studio 2026 and VC145 redistributables (#44264)
Testing: Visual Studio 2026 builds are not run in CI. 
Fixes: #44261.

Signed-off-by: 张喜昌 <zhang.xichang@outlook.com>
2026-04-16 11:19:02 +00:00
Kingsley Yung
b23ee51d00 script: Initialize Sanitizer API implementation (#44198)
Initialize Sanitizer API implementation with partially implemented
constructor and `get()` methods of the `Sanitizer` interface, which
allows the sub-sequential implementation to be tested by WPT.

The `Sanitizer` interface is hidden behind the feature flag
`dom_sanitizer_enabled`, which is disabled by default.

Specification: https://wicg.github.io/sanitizer-api/

Testing: Enable WPT tests for Sanitizer API.
Fixes: Part of #43948

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-16 10:31:53 +00:00
Steven Novaryo
02ba2eaa62 script: Partially implement IntersectionObserver compute the intersection algo (#42204)
Depends on #42251 for the overflow query.

Use containing block queries to implement the iteration of step [3.2.7.
Compute the Intersection of a Target Element and the
Root](https://w3c.github.io/IntersectionObserver/#compute-the-intersection)
within `IntersectionObserver` algorithm.

Contrary to the algorithm in the spec that maps the coordinate space of
the element for each iteration, we uses bounding client rect queries to
get the appropriate clip rect. And, to handle the mapping between
different coordinate spaces of iframes, we use a simple translation.

Due to the platform limitation, currently it would only handle the same
`ScriptThread` browsing context. Therefore innaccuracy any usage with
cross origin iframes is expected.

Testing: Existing and new WPTs.
Part of: https://github.com/servo/servo/issues/35767

Co-authored-by: Josh Matthews
[josh@joshmatthews.net](josh@joshmatthews.net)

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-04-16 09:04:53 +00:00
Kingsley Yung
6c14aed993 script: Encapsulate logic of underlying compression algorithms (#44195)
In CompressionStream API, the compression algorithms are provided by
`flate2::write::{DeflateEncoder, GzEncoder, ZlibEncoder}` and
`brotli::CompressorWriter`, and the decompression algorithms are
provided by `flate2::write::{DeflateDecoder, GzDecoder, ZlibDecoder}`
and `brotli::DecompressorWriter`.

Although all of them `std::io::Write`, they have subtle difference in
their workflow. For example, `DeflateEncoder`, `GzEncoder` and
`ZlibEncoder` are closed by `fn try_finish(&mut self)` or `fn
finish(self)`, while `brotli::CompressorWriter` must be closed by `fn
into_inner(self)`.

We currently directly call those methods from specification steps. This
patch move those method calls into new structs `CompressionContext` and
`DecompressorContext`, to provide an abstraction layer between
specification steps and underlying logics of compression algorithms from
external libraries. This helps to separate the subtle difference in
compression algorithms away from specification steps.

Testing: Refactoring. Covered by tests in `tests/wpt/tests/compression/`

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-16 03:40:03 +00:00
Euclid Ye
2dedd4087e ci: Install cargo nextest conditionally; Give the step consistent name for linux & mac (#44226)
There is no point to install it if we don't run UT. 
This step takes 1 min to install for self-hosted runner:
[try](https://github.com/servo/servo/actions/runs/24436253745/job/71391055444#step:15:11).
Given the rising energy price nowadays, let's save it.

Also take the chance to give the consistent name. Somehow only Windows
had the name "Install cargo nextest"

Testing: Previously, the step is called "Run taiki-e/install-action@v2"
in the linux/mac CI.
Now it has the proper name and skipped if UT will not be run:
[try](https://github.com/servo/servo/actions/runs/24440166415/job/71403276390).

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-16 01:47:46 +00:00
Florian König
4a3ee306db api: WebView::animating should only take a reference to self (#44253)
Fixed that `WebView::animating` takes `self` instead of `&self` as
argument.

Testing: Unsure how this could be tested for, beyond creating a unit
test for each individual function as a sanity check that all parameters
are correct. This seems excessive.
Fixes: #44251

Signed-off-by: Java <javaderg@pm.me>
2026-04-15 22:27:43 +00:00
Simon Wülker
7873d8a6c3 tests: Remove src from audio element in move-element-with-ua-shadow-tree-crash.html (#44252)
The original bug was triggered by the shadow tree for audio controls,
and that tree exists without the `src` element too.

Let's see if this fixes https://github.com/servo/servo/issues/39473

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-15 21:55:29 +00:00
rovertrack
2578b5b78a script: Use OffscreenRenderingContextId instead of DOMString in OffscreenCanvas (#44227)
replaced use of `DOMString` with `OffscreenRenderingContextId` made the
enum be initialized in bindings
([OffscreenCanvas.webidl](https://github.com/servo/servo/compare/main...rovertrack:servo:issue-44211?expand=1#diff-3a74afa4763f3f36099b9717328f9516edc3eecd5131d216a8cd024fa4fd96d9))
and use them in `getcontext()`
Testing: `./mach test-wpt tests/wpt/tests/html/canvas/offscreen` there
are no failing tests regarding the use of `OffscreenRenderingContextId`
but there were some regarding other things such as `TextMetrics`.
Fixes:  #44211

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-15 21:29:34 +00:00
Martin Robinson
57cc4931bd wpt: Make /_mozilla/css/offset-properties-inline.html wait for fonts to load (#44247)
This is a speculative fix for #40543. Although I could not get this test
to flake locally, it is obviously wrong to assumee that web fonts (Ahem
in this case) is loaded at the time of `window.onload`. This change
makes all the tests Promise tests and has them await
`document.fonts.ready` before running. This should fix the
intermittency.

Testing: This should fix itnermittency as seen on the CI.
Fixes: #40543.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-15 21:26:09 +00:00
Martin Robinson
730fa9d47d wpt: Make /_mozilla/mozilla/getBoundingClientRect.html wait for fonts to load (#44248)
This is a speculative fix for #39668. Although I could not get this test
to flake locally, it is obviously wrong to assumee that web fonts (Ahem
in this case) is loaded at the time of `window.onload`. This change
makes all the tests Promise tests and has them await
`document.fonts.ready` before running. This should fix the
intermittency.

Testing: This should fix intermittency as seen on the CI.
Fixes: #39668

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-15 19:25:28 +00:00
Ashwin Naren
c368a53fba storage: Enable indexeddb as an experimental feature (#44245)
Enables indexeddb as experimental; allows indexeddb to be tested on
wpt.fyi.

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
2026-04-15 19:05:45 +00:00
Taym Haddadi
93a57147ce script: generalize worker common code for non-dedicated worker globals (#44244)
Testing: No new tests needed this is a refactor and no behavior changes
for any existing workers.
part of https://github.com/servo/servo/issues/7458

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-15 17:13:22 +00:00
Oriol Brufau
3cd71cf05a layout: Reuse abspos fragments when they didn't change (#44231)
When laying out an absolutely positioned box, if the layout results are
taken from the cache, and the resulting fragment would have the same
size and position, then use the fragment from the previous layout
instead.

Testing: Not needed, there shouldn't be any observable behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-04-15 16:40:15 +00:00
Martin Robinson
d22435c6f6 wpt: Rename Servo-specific WPT-style tests to match WPT conventions (#44232)
This is a very minor, but annoying bit of technical debt that we have
carried for over a decade. Many of the Servo-specific WPT-style tests
had names that didn't match the naming convention used in WPT. In some
cases tests and references were named `test_a.html` for the test and
`test_b.html` for the reference. To make things more confusing,
sometimes two tests in a series were named `test_a.html`, `test_b.html`
and `test_ref.html` for the reference.

This change makes it so that tests are named consistenty and with
hyphens which are more common in WPT:

 - `test-001.html`
 - `test-002.html`
 - `test-ref.html`

Testing: This shouldn't change results, as this just renames the test
files.
Fixes #2463.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-15 16:15:28 +00:00
eri
d37e6f1bb5 devtools: Implement function preview in console (#44233)
Testing: Added new tests for console array and function previews
Part of: https://github.com/servo/servo/issues/39858
Depends on: #44196

<img width="934" height="388" alt="image"
src="https://github.com/user-attachments/assets/8589ef9c-7a58-47dd-83dd-4f66607125fe"
/>

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-15 15:11:16 +00:00
Narfinger
4fafdd1c23 script: JSContextify parts of DocumentEventHandler (#44241)
This "JSContextify"s part of DocumentEventHandler, namely the actions
from `handle_pending_input_events`.
Additionally, we also switch the MouseEvent and KeyboardEvent. This does
not change yet PointerEvent and some other events used to keep the diff
reasonable.

Testing: This is part of the JSContextify work that is fundamental and
tested by WPT.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-15 13:59:07 +00:00
Martin Robinson
d4729c05b2 wpt: Remove the /_mozilla/mozilla/sslfail.html (#44238)
This tests a feature (`about:sslfail`) that was removed in #14360 and
has been flaky for years. At this point, the test has been flaking for a
decade longer after the original feature existed! We can just go ahead
and remove it I think.

Testing: This change just removes a test, so doesn't need new tests.
Fixes: #10760

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-15 13:57:51 +00:00
Tim van der Lippe
a8e8f2ae89 script: Fix command state for underline command (#44234)
For any generic command, the spec doesn't specify how to determine
whether its state is set. In the case of underline, it at least means
that it has an effective command value that is set (to underline in this
case).

Also implements "simple modifiable" elements, since the relevant tests
depend on that for correctness.

Lastly, also rewrite `JSContext` to use imports.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-15 13:56:50 +00:00
Martin Robinson
12bac57c3e wpt: Remove empty test ini for /_mozilla/mozilla/localeCompare.html (#44240)
Judging by the expected result in the test, the situation described in
the bug is no longer the case.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>

Testing: This updates test results.
Closes: #25802.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-15 13:37:40 +00:00
Martin Robinson
0353e0fd2e wpt: Convert several old Servo-specific crash tests into WPT crashtests (#44237)
This change converts a collection of old Servo-specific crash tests into
WPT style crash tests, which are supported directly by the WPT test
harness. The main change here is the addition of `-crash.html` to the
end
of the test name (this is how the harness detects crash tests) and the
removal of `testharness.js` from the tests. This is a preparation for
#44232.

Testing: This change just changes the tests, so should be tested by the
test run.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-15 12:42:29 +00:00
atbrakhi
77458b2312 devtools: implement ArrayPreview in console (#44196)
Show preview of `ArrayItems` in console

Testing: Current tests are passing
Fixes: Part of #39858 
<img width="941" height="795" alt="image"
src="https://github.com/user-attachments/assets/e121265c-3987-4e37-a97d-b7cef0e05f4b"
/>

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-15 10:06:10 +00:00
rovertrack
134beac3f0 Match on NonNull::new instead of using is_null() and expect() (#44221)
The code was doing repetitive work by checking if `compiled_script` is
null and then assigning and expecting the same, combined and replaced
with condition based working
Testing: The flow remains the same no new tests needed
Fixes: #44210

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-15 09:32:33 +00:00
Alice
31be152bfa layout: Send accessibility updates directly to embedder from layout. (#44208)
This introduces a `ScriptToEmbedderChan` property on `LayoutThread`,
which is used to send accessibility updates directly to the embedder.

Follow-up to https://github.com/servo/servo/pull/42338.

Testing: Covered by existing tests.

Signed-off-by: Alice Boxhall <alice@igalia.com>
2026-04-15 09:14:40 +00:00
Euclid Ye
0f935df0c8 embedding: Use non-advertised (standard) shortcut (#44223)
Right now we are using [advertised
shortcut](https://learn.microsoft.com/en-au/windows/win32/msi/advertisement).
This is drastically different from standard Windows shortcut. For
example, when you right click,
then click "open file position", nothing happens. 

Advertisement is mostly for "install-on-demand", but that is not the
case for our installer, as files already
installed in the path even if you do not launch. This change makes it so
that servoshell works as other apps.

Reference: [Advanced
installer](https://www.advancedinstaller.com/versus/wix-toolset/how-to-create-non-advertised-shortcuts-using-wix.html).
(Yes, they make great business by making it easier to build MSI
installer)


Testing: [Windows
Try](https://github.com/servo/servo/actions/runs/24436253745).

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-15 08:27:18 +00:00
Euclid Ye
1099aceb39 deps: Unblock CI by upgrading rustls-webpki to 0.103.12 (#44229)
[rustls-webpki](https://rustsec.org/packages/rustls-webpki.html) has
[vulnerability
report](https://rustsec.org/advisories/RUSTSEC-2026-0098.html). This is
fixed in newer 0.103.12.

Testing: Cargo deny will now pass causing the CI to pass.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-15 08:25:55 +00:00
Taym Haddadi
90c8bc3163 Indexeddb: fix upgrade transaction completion ordering (#44215)
Fixes: #44200

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-15 05:29:16 +00:00
Abbas Olanrewaju Sarafa
316e6215a4 API: document which Preferences are experimental or enabled by default (#44171)
Referred users to
```https://book.servo.org/design-documentation/experimental-features.html```
documentation for ```Preferences``` and ```EXPERIMENTAL_PREFS```

Testing: No testing required, build was successful.
Fixes: #43706

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
Signed-off-by: Abbas Olanrewaju Sarafa <109840351+sabbCodes@users.noreply.github.com>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-04-15 04:25:25 +00:00
niya
0260fe8869 webgl: replace WebGLCommandSender with WebGLChan (#44214)
Remove the `WebGLCommandSender` wrapper and return `Option<WebGLChan>`
directly from the `webgl_chan` method.

Testing: no tests required as runtime behavior is not affected 
Fixes: #44193

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-15 03:41:06 +00:00
Kelechi Ebiri
a2213091c4 script: Implement wake lock api (#43617)
Implement the WakeLock API

Fixes: #41493

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-15 03:39:07 +00:00
dependabot[bot]
54f466fdcb build: bump indexmap from 2.11.4 to 2.14.0 (#44220)
Bumps [indexmap](https://github.com/indexmap-rs/indexmap) from 2.11.4 to
2.14.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/indexmap-rs/indexmap/blob/main/RELEASES.md">indexmap's
changelog</a>.</em></p>
<blockquote>
<h2>2.14.0 (2026-04-09)</h2>
<ul>
<li><strong>MSRV</strong>: Rust 1.85.0 or later is now required.</li>
<li>Updated the <code>hashbrown</code> dependency to 0.17.</li>
<li>Made more <code>map::Slice</code> methods <code>const</code>:
<code>new_mut</code>, <code>first_mut</code>, <code>last_mut</code>,
<code>split_at_mut</code>, <code>split_at_mut_checked</code>,
<code>split_first_mut</code>, <code>split_last_mut</code></li>
</ul>
<h2>2.13.1 (2026-04-02)</h2>
<ul>
<li>Made some <code>Slice</code> methods <code>const</code>:
<ul>

<li><code>map::Slice::{first,last,split_at,split_at_checked,split_first,split_last}</code></li>

<li><code>set::Slice::{first,last,split_at,split_at_checked,split_first,split_last}</code></li>
</ul>
</li>
</ul>
<h2>2.13.0 (2026-01-07)</h2>
<ul>
<li>Implemented <code>Clone</code> for <code>IntoKeys</code> and
<code>IntoValues</code>.</li>
<li>Added <code>map::Slice::split_at_checked</code> and
<code>split_at_mut_checked</code>.</li>
<li>Added <code>set::Slice::split_at_checked</code>.</li>
</ul>
<h2>2.12.1 (2025-11-20)</h2>
<ul>
<li>Simplified a lot of internals using <code>hashbrown</code>'s new
bucket API.</li>
</ul>
<h2>2.12.0 (2025-10-17)</h2>
<ul>
<li><strong>MSRV</strong>: Rust 1.82.0 or later is now required.</li>
<li>Updated the <code>hashbrown</code> dependency to 0.16 alone.</li>
<li>Error types now implement <code>core::error::Error</code>.</li>
<li>Added <code>pop_if</code> methods to <code>IndexMap</code> and
<code>IndexSet</code>, similar to the
method for <code>Vec</code> added in Rust 1.86.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="bcd165baeb"><code>bcd165b</code></a>
Merge pull request <a
href="https://redirect.github.com/indexmap-rs/indexmap/issues/439">#439</a>
from cuviper/release-2.14.0</li>
<li><a
href="4ef06a729e"><code>4ef06a7</code></a>
Release 2.14.0</li>
<li><a
href="d21826ca93"><code>d21826c</code></a>
Merge pull request <a
href="https://redirect.github.com/indexmap-rs/indexmap/issues/438">#438</a>
from cuviper/hashbrown-0.17</li>
<li><a
href="2566bec20d"><code>2566bec</code></a>
Upgrade to <code>hashbrown v0.17</code></li>
<li><a
href="4b62776c3f"><code>4b62776</code></a>
Merge pull request <a
href="https://redirect.github.com/indexmap-rs/indexmap/issues/437">#437</a>
from cuviper/disjoint-panic</li>
<li><a
href="478fba2eb0"><code>478fba2</code></a>
Normalize the panic doc of <code>get_disjoint_mut</code></li>
<li><a
href="fb6dafda4e"><code>fb6dafd</code></a>
Merge pull request <a
href="https://redirect.github.com/indexmap-rs/indexmap/issues/436">#436</a>
from cuviper/const-slice-mut</li>
<li><a
href="5c237a2ab7"><code>5c237a2</code></a>
Make <code>Slice::{first,last,split_*}_mut</code> methods
<code>const</code></li>
<li><a
href="48ff9ce2e3"><code>48ff9ce</code></a>
Merge pull request <a
href="https://redirect.github.com/indexmap-rs/indexmap/issues/435">#435</a>
from cuviper/edition-2024</li>
<li><a
href="648be98a31"><code>648be98</code></a>
<code>cargo fmt</code> with edition 2024</li>
<li>Additional commits viewable in <a
href="https://github.com/indexmap-rs/indexmap/compare/2.11.4...2.14.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=indexmap&package-manager=cargo&previous-version=2.11.4&new-version=2.14.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-15 00:56:19 +00:00
dependabot[bot]
da6aaf7eb9 build: bump thin-vec from 0.2.15 to 0.2.16 (#44219)
Bumps [thin-vec](https://github.com/mozilla/thin-vec) from 0.2.15 to
0.2.16.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/mozilla/thin-vec/blob/main/RELEASES.md">thin-vec's
changelog</a>.</em></p>
<blockquote>
<h1>Version 0.2.16 (2026-04-14)</h1>
<ul>
<li>Fix reserve() on auto arrays in gecko-ffi mode.</li>
<li>Fix two double-drop issues with ThinVec::clear() and
ThinVec::into_iter()
when the Drop implementation of the item panics.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="3c96f1e335"><code>3c96f1e</code></a>
chore: Bump version to v0.2.16</li>
<li><a
href="df64748355"><code>df64748</code></a>
Fix two panic=unwind issues.</li>
<li><a
href="4e3a217b7f"><code>4e3a217</code></a>
ci: Ignore msrv job for now since it just hangs trying to pull
deps.</li>
<li><a
href="63c2f5fcf2"><code>63c2f5f</code></a>
gecko-ffi: Fix auto-t-array push.</li>
<li><a
href="6797813209"><code>6797813</code></a>
tests: Appease clippy.</li>
<li><a
href="af81b17ad5"><code>af81b17</code></a>
ci: Don't use actions-rs/{cargo,clippy-check} as it's not allowed in
mozilla/...</li>
<li><a
href="360f9ef0c9"><code>360f9ef</code></a>
Update repository URL and various cleanups</li>
<li>See full diff in <a
href="https://github.com/mozilla/thin-vec/compare/v0.2.15...v0.2.16">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=thin-vec&package-manager=cargo&previous-version=0.2.15&new-version=0.2.16)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-15 00:30:35 +00:00
dependabot[bot]
0fc59f67ed build: bump rayon from 1.11.0 to 1.12.0 (#44218)
Bumps [rayon](https://github.com/rayon-rs/rayon) from 1.11.0 to 1.12.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rayon-rs/rayon/blob/main/RELEASES.md">rayon's
changelog</a>.</em></p>
<blockquote>
<h1>Release rayon 1.12.0 (2026-04-13)</h1>
<ul>
<li>Fixed a bug in parallel <code>Range&lt;char&gt;</code> when the end
is 0xE000, just past the
surrogate boundary, which was unsafely producing invalid
<code>char</code> values.</li>
<li>The new method <code>ParallelSlice::par_array_windows</code> works
like <code>par_windows</code>
but with a constant length, producing <code>&amp;[T; N]</code>
items.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7449d7dfed"><code>7449d7d</code></a>
Merge <a
href="https://redirect.github.com/rayon-rs/rayon/issues/1093">#1093</a></li>
<li><a
href="b3d9e3f473"><code>b3d9e3f</code></a>
Release rayon 1.8.0 and rayon-core 1.12.0</li>
<li><a
href="3fe51e5cbd"><code>3fe51e5</code></a>
Fix clippy::let_and_return</li>
<li><a
href="082f2152d2"><code>082f215</code></a>
Merge <a
href="https://redirect.github.com/rayon-rs/rayon/issues/1087">#1087</a></li>
<li><a
href="ea0c06df26"><code>ea0c06d</code></a>
core: registry: Factor out &quot;wait till out of work&quot; part of the
main loop.</li>
<li><a
href="75524e2957"><code>75524e2</code></a>
Merge <a
href="https://redirect.github.com/rayon-rs/rayon/issues/1063">#1063</a></li>
<li><a
href="01d2800376"><code>01d2800</code></a>
Ignore the multi-threaded test on emscripten/wasm</li>
<li><a
href="40b59c0e44"><code>40b59c0</code></a>
core: Make use_current_thread error rather than panic when already in
the pool.</li>
<li><a
href="f4db4d711e"><code>f4db4d7</code></a>
core: tests: Add some basic tests for
ThreadPoolBuilder::use_current_thread.</li>
<li><a
href="87274ad093"><code>87274ad</code></a>
core: registry: Add some more documentation for
ThreadPoolBuilder::use_curren...</li>
<li>Additional commits viewable in <a
href="https://github.com/rayon-rs/rayon/compare/rayon-core-v1.11.0...rayon-core-v1.12.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rayon&package-manager=cargo&previous-version=1.11.0&new-version=1.12.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-15 00:28:27 +00:00
dependabot[bot]
a2fa5a8ab8 build: bump tokio from 1.51.1 to 1.52.0 in the tokio-rs-related group (#44217)
Bumps the tokio-rs-related group with 1 update:
[tokio](https://github.com/tokio-rs/tokio).

Updates `tokio` from 1.51.1 to 1.52.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tokio/releases">tokio's
releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.52.0</h2>
<h1>1.52.0 (April 14th, 2026)</h1>
<h2>Added</h2>
<ul>
<li>io: <code>AioSource::register_borrowed</code> for I/O safety support
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7992">#7992</a>)</li>
<li>net: add <code>try_io</code> function to <code>unix::pipe</code>
sender and receiver types (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8030">#8030</a>)</li>
</ul>
<h2>Added (unstable)</h2>
<ul>
<li>runtime: <code>Builder::enable_eager_driver_handoff</code> setting
enable eager hand off of the I/O and time drivers before polling tasks
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8010">#8010</a>)</li>
<li>taskdump: add <code>trace_with()</code> for customized task dumps
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8025">#8025</a>)</li>
<li>taskdump: allow <code>impl FnMut()</code> in <code>trace_with</code>
instead of just <code>fn()</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8040">#8040</a>)</li>
<li>fs: support <code>io_uring</code> in <code>AsyncRead</code> for
<code>File</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7907">#7907</a>)</li>
</ul>
<h2>Changed</h2>
<ul>
<li>runtime: improve <code>spawn_blocking</code> scalability with
sharded queue (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7757">#7757</a>)</li>
<li>runtime: use <code>compare_exchange_weak()</code> in worker queue
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8028">#8028</a>)</li>
</ul>
<h2>Fixed</h2>
<ul>
<li>runtime: overflow second half of tasks when local queue is filled
instead of first half (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8029">#8029</a>)</li>
</ul>
<h2>Documented</h2>
<ul>
<li>docs: fix typo in <code>oneshot::Sender::send</code> docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8026">#8026</a>)</li>
<li>docs: hide #[tokio::main] attribute in the docs of
<code>sync::watch</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8035">#8035</a>)</li>
<li>net: add docs on <code>ConnectionRefused</code> errors with UDP
sockets (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7870">#7870</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/tokio-rs/tokio/issues/7757">#7757</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7757">tokio-rs/tokio#7757</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7870">#7870</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7870">tokio-rs/tokio#7870</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7907">#7907</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7907">tokio-rs/tokio#7907</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7992">#7992</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7992">tokio-rs/tokio#7992</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8010">#8010</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8010">tokio-rs/tokio#8010</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8025">#8025</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8025">tokio-rs/tokio#8025</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8026">#8026</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8026">tokio-rs/tokio#8026</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8028">#8028</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8028">tokio-rs/tokio#8028</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8029">#8029</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8029">tokio-rs/tokio#8029</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8030">#8030</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8030">tokio-rs/tokio#8030</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8035">#8035</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8035">tokio-rs/tokio#8035</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8040">#8040</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8040">tokio-rs/tokio#8040</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="5f7be0ac42"><code>5f7be0a</code></a>
chore: perpare 1.52.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8045">#8045</a>)</li>
<li><a
href="36d12d2686"><code>36d12d2</code></a>
taskdump: allow impl FnMut() in taskdumps instead of just fn() (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8040">#8040</a>)</li>
<li><a
href="f943312865"><code>f943312</code></a>
fs: support io-uring in <code>AsyncRead</code> for <code>File</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7907">#7907</a>)</li>
<li><a
href="5db10f538b"><code>5db10f5</code></a>
net: add 'try_io' function to 'unix::pipe' sender and receiver types (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8030">#8030</a>)</li>
<li><a
href="bbdba7101d"><code>bbdba71</code></a>
taskdump: add <code>trace_with</code> for customized task dumps (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8025">#8025</a>)</li>
<li><a
href="7cfce54386"><code>7cfce54</code></a>
ci: update FreeBSD image to 14.4 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8038">#8038</a>)</li>
<li><a
href="81370e6202"><code>81370e6</code></a>
net: add docs on <code>ConnectionRefused</code> errors with udp sockets
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7870">#7870</a>)</li>
<li><a
href="203af02126"><code>203af02</code></a>
runtime: overflow second half of tasks when local queue is filled
instead of ...</li>
<li><a
href="de230926dc"><code>de23092</code></a>
net: temporarily disable <code>tcp_stream</code>
<code>try_read_buf</code> test on WASI (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8036">#8036</a>)</li>
<li><a
href="432ec3f2b2"><code>432ec3f</code></a>
sync: hide <code>#[tokio::main]</code> attribute in the docs of
<code>sync::watch</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8035">#8035</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-1.51.1...tokio-1.52.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio&package-manager=cargo&previous-version=1.51.1&new-version=1.52.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-15 00:21:52 +00:00
niya
8bdfb998b0 canvas: fix unrecognized offscreen webgl context (#44159)
fix unrecognized type error on `OffscreenCanvas`

Testing: existing WPT:
- `tests/wpt/webgl/tests/conformance/offscreencanvas`
- `tests/wpt/webgl/tests/conformance2/offscreencanvas`

Fixes: #43540

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-14 23:58:39 +00:00
Alice
d11fc3a1c6 layout: Add a basic accessibility tree implementation for web contents (#42338)
This change introduces the `accessibility_tree` module, containing code
to build an in-memory representation of a very basic accessibility tree
for web contents. Currently, the tree for a given document contains:
- a `RootWebArea` which has the document root node as its sole child,
- an `Unknown` node for the root DOM node,
- a `GenericContainer` node for each DOM element, and
- a `TextRun` node for each text node.

This allows us to make basic assertions about the tree contents in the
`accessibility` test by doing a tree walk to find text nodes and
checking their contents.

Right now, the tree is rebuilt from scratch when accessibility is
enabled and when a navigation occurs (via
`Constellation::set_frame_tree_for_webview()` sending
`ScriptThreadMessage::SetAccessibilityActive`); it's not responsive to
changes in the page.

This change also changes the way we handle updating the graft node
between the webview's accessibility tree and its top level pipeline's
accessibility tree.

Previously, `Constellation::set_frame_tree_for_webview()` would send a
`ConstellationToEmbedderMsg::DocumentAccessibilityTreeIdChange` method
informing the webview of the accesskit TreeId of the top-level pipeline.
However, this resulted in flaky timing as we couldn't depend on that
message being handled before the message containing the TreeUpdate from
the WebContents, which would lead to a panic as the new TreeId wasn't
grafted into the combined tree yet.

This change introduces an epoch value which flows from the
ConstellationWebview, where it's updated every time the
`active_top_level_pipeline_id` changes, to the layout accessibility
tree, and finally to the webview with each TreeUpdate. Whenever a
TreeUpdate arrives at the webview which has a newer epoch than the last
known epoch, the webview-to-contents graft node is updated before the
TreeUpdate is forwarded. If a TreeUpdate arrives at the webview with an
epoch _older_ than the last known epoch, it's dropped, as it must be for
a no-longer-active pipeline.

Fixes: Part of #4344

---------

Signed-off-by: delan azabani <dazabani@igalia.com>
Signed-off-by: Alice Boxhall <alice@igalia.com>
Co-authored-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
2026-04-14 13:36:57 +00:00
Simon Wülker
2930beb4d1 script: Don't traverse O(the whole DOM tree) nodes when inserting elements into Vec in tree order (#44120)
Previously the code was computing a prefix sum over the number of
preceding elements in tree order to get the index that the node should
be inserted in.

That's not great if the DOM tree is big. Instead, we can compare two
nodes individually by looking at their ancestor chain and then find the
correct position with binary search.

On https://262.ecma-international.org/16.0/index.html, this reduces the
time it takes for content to appear from around 33s to 16s.

Part of https://github.com/servo/servo/issues/44113

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-14 13:16:55 +00:00
Mukilan Thiyagarajan
38e3397237 servoshell: Fix incorrect calculation of WebView dimension. (#44205)
The upgrade to egui 0.34.0 in #44053 replaced the usage of the
deprecated `Ui::available_rect` method with `Ui::content_rect` as
suggested in the deprecation notice in egui. However, `content_rect` is
not equivalent to `available_rect` and doesn't seem to account for the
area occupied by the egui panels.

Since `content_rect` returns the window's inner dimensions, we don't ask
the webview to resize itself to the correct dimension that excludes the
toolbar (tabs and url). We also pass the correct dimension to egui's
paint callback, which meant that the WebView appeared vertically
squashed.

Fix this by using `available_rect_before_wrap` method instead of
`content_rect`. This seems to return the correct area that we need for
the WebView's dimenstion. The code in egui also seems closer to what we
want as it relies on a cursor that is advanced after each widget is
added. However, I'm not sure in which scenario the wrapping matters as
there is no documentation for this method.

Testing: Tested manually as we don't have automated tests for the shell.
Fixes: #44136

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-04-14 12:49:48 +00:00
Nico Burns
b89cbf1201 deps: Upgrade Taffy to v0.10.1 (#44203)
Fixes CSS Grid auto-repeat track count resolution in CSS Grid. This
caused an integer underflow in some cases and in others simply computed
the incorrect number of tracks.

Hopefully fixes: #44201

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
2026-04-14 11:49:32 +00:00
Martin Robinson
5d28862c7b script: Expose a LayoutNode::is_root_of_user_agent_widget method (#44197)
The main goal here is to have layout not depend on `ServoLayoutElement`
directly and instead use the layout DOM interface exposed by
`layout-api`. 

This change allows layout to determine if replaced content
is the root of a user agent widget without having to access
`ServoDangerousStyleShadowRoot` which isn't really safe to use in layout
code. `LayoutElement::shadow_root()` is now no longer exposed to layout.

Testing: This should not change behavior, so should be covered by
existing test.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-14 10:35:00 +00:00
Shubham Gupta
4ff29fecc8 script : Return PerformanceMark object from the Performance.mark() (#44199)
This returns the `PerformanceMark` object from Performance.mark()

Testing: More WPT tests passed

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-14 09:47:05 +00:00
Martin Robinson
e0fd559105 script: Simplify the way that layout flushes shadow root stylesheets (#44165)
This change is a minor cleanup of the way that layout flushes the
stylesheets of shadow roots. This avoids exposing so many public methods
in our and gradually to stop using Stylo's `TShadowRoot` in layout
entirely.

Testing: This should not change behavior, so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-14 09:15:05 +00:00
Martin Garton
d0c2e0fa48 Expand fmt and tidy TOML_GLOBS range (#44180)
Add a check for formatting of the `Cargo.toml` files to CI, and run
`taplo format` to fix existing formatting issues.

---------

Signed-off-by: Martin Garton <garton@gmail.com>
2026-04-14 09:14:29 +00:00
Tim van der Lippe
143d7fe25e script: Add initial implementation of underline command (#44194)
This puts in most of the required machinery for underline. There are
still remaining test failures, but tackling these in separate PR's to
keep things manageable.

Part of #25005

Testing: WPT

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-04-14 08:03:18 +00:00
batu_hoang
4ecf8be867 net: Remove duplicate CoreResourceMsg::GetCookiesDataForUrl (#44167)
In https://github.com/servo/servo/pull/43600, we introduce the new
`CoreResourceMsg::GetCookiesForUrl`.
However after some updates, it is exactly the same with an existing one
`CoreResourceMsg::GetCookiesDataForUrl` which is used by `webdriver`.
This PR removes the duplication.

Signed-off-by: batu_hoang <longvatrong111@gmail.com>
2026-04-14 06:14:46 +00:00
dependabot[bot]
2a1290a591 build: bump rustls from 0.23.37 to 0.23.38 (#44187)
Bumps [rustls](https://github.com/rustls/rustls) from 0.23.37 to
0.23.38.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="6b116bc5e8"><code>6b116bc</code></a>
Bump version of rustls</li>
<li><a
href="a1da268c89"><code>a1da268</code></a>
client: allow skipping selected ALPN validation</li>
<li><a
href="5b3ef11c60"><code>5b3ef11</code></a>
Fix ambiguous panic! warning</li>
<li><a
href="0f0fbf5a59"><code>0f0fbf5</code></a>
Fix <code>clippy::result_large_err</code></li>
<li><a
href="7e99b52071"><code>7e99b52</code></a>
Update semver-compatible dependencies</li>
<li>See full diff in <a
href="https://github.com/rustls/rustls/compare/v/0.23.37...v/0.23.38">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rustls&package-manager=cargo&previous-version=0.23.37&new-version=0.23.38)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-14 03:29:19 +00:00
dependabot[bot]
460c14bbbe build: bump lru from 0.16.3 to 0.16.4 (#44191)
Bumps [lru](https://github.com/jeromefroe/lru-rs) from 0.16.3 to 0.16.4.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/jeromefroe/lru-rs/blob/master/CHANGELOG.md">lru's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/jeromefroe/lru-rs/tree/0.16.4">v0.16.4</a> -
2026-04-13</h2>
<ul>
<li>Add <code>get_or_insert_with_key</code> and variants.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d8c7f5ca51"><code>d8c7f5c</code></a>
Merge pull request <a
href="https://redirect.github.com/jeromefroe/lru-rs/issues/230">#230</a>
from jeromefroe/jerome/prepare-0-16-4-release</li>
<li><a
href="bd5261b499"><code>bd5261b</code></a>
Prepare 0.16.4 release</li>
<li><a
href="16e161d5ed"><code>16e161d</code></a>
Merge pull request <a
href="https://redirect.github.com/jeromefroe/lru-rs/issues/229">#229</a>
from pikatos/get_or_insert_with_key</li>
<li><a
href="5135e8eb26"><code>5135e8e</code></a>
Apply suggestions from code review</li>
<li><a
href="81c2ef05fd"><code>81c2ef0</code></a>
Add get_or_insert_with_key variants</li>
<li>See full diff in <a
href="https://github.com/jeromefroe/lru-rs/compare/0.16.3...0.16.4">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=lru&package-manager=cargo&previous-version=0.16.3&new-version=0.16.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-14 00:56:18 +00:00
dependabot[bot]
6c2bc8fd1e build: bump libc from 0.2.184 to 0.2.185 (#44189)
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.184 to 0.2.185.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/releases">libc's
releases</a>.</em></p>
<blockquote>
<h2>0.2.185</h2>
<h3>Added</h3>
<ul>
<li>EspIDF: Add <code>espidf_picolibc</code> cfg for picolibc
<code>O_*</code> flag values (<a
href="https://redirect.github.com/rust-lang/libc/pull/5035">#5035</a>)</li>
<li>Hexagon: add missing constants and fix types for linux-musl (<a
href="https://redirect.github.com/rust-lang/libc/pull/5042">#5042</a>)</li>
<li>Redox: Add semaphore functions (<a
href="https://redirect.github.com/rust-lang/libc/pull/5051">#5051</a>)</li>
<li>Windows: Add <code>sprintf</code>, <code>snprintf</code>, and the
<code>scanf</code> family (<a
href="https://redirect.github.com/rust-lang/libc/pull/5024">#5024</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Hexagon: Decouple <code>time64</code> types from musl symbol
redirects (<a
href="https://redirect.github.com/rust-lang/libc/pull/5040">#5040</a>)</li>
<li>Horizon: Change <code>POLL</code> constants from
<code>c_short</code> to <code>c_int</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5045">#5045</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/blob/0.2.185/CHANGELOG.md">libc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/libc/compare/0.2.184...0.2.185">0.2.185</a>
- 2026-04-13</h2>
<h3>Added</h3>
<ul>
<li>EspIDF: Add <code>espidf_picolibc</code> cfg for picolibc
<code>O_*</code> flag values (<a
href="https://redirect.github.com/rust-lang/libc/pull/5035">#5035</a>)</li>
<li>Hexagon: add missing constants and fix types for linux-musl (<a
href="https://redirect.github.com/rust-lang/libc/pull/5042">#5042</a>)</li>
<li>Redox: Add semaphore functions (<a
href="https://redirect.github.com/rust-lang/libc/pull/5051">#5051</a>)</li>
<li>Windows: Add <code>sprintf</code>, <code>snprintf</code>, and the
<code>scanf</code> family (<a
href="https://redirect.github.com/rust-lang/libc/pull/5024">#5024</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Hexagon: Decouple <code>time64</code> types from musl symbol
redirects (<a
href="https://redirect.github.com/rust-lang/libc/pull/5040">#5040</a>)</li>
<li>Horizon: Change <code>POLL</code> constants from
<code>c_short</code> to <code>c_int</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5045">#5045</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="71d5bfcc1b"><code>71d5bfc</code></a>
libc: Release 0.2.185</li>
<li><a
href="1027d1c23b"><code>1027d1c</code></a>
Revert &quot;ci: Pin nightly to 2026-04-01&quot;</li>
<li><a
href="0e9c6e53cc"><code>0e9c6e5</code></a>
redox: Add semaphore functions</li>
<li><a
href="24ef457ddd"><code>24ef457</code></a>
feat: add back support for gnu windows x86 in ci</li>
<li><a
href="aa75caf30c"><code>aa75caf</code></a>
horizon: Change POLL constants from c_short to c_int</li>
<li><a
href="b7eda5a40c"><code>b7eda5a</code></a>
hexagon: add missing constants and fix types for linux-musl</li>
<li><a
href="d4613f96a5"><code>d4613f9</code></a>
newlib/espidf: Add espidf_picolibc cfg for picolibc O_* flag values</li>
<li><a
href="c89fd76cc7"><code>c89fd76</code></a>
Fix typo in Padding comments</li>
<li><a
href="b3264b292a"><code>b3264b2</code></a>
hexagon: decouple time64 types from musl symbol redirects</li>
<li><a
href="db1ebee456"><code>db1ebee</code></a>
ci: Pin nightly to 2026-04-01</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/libc/compare/0.2.184...0.2.185">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libc&package-manager=cargo&previous-version=0.2.184&new-version=0.2.185)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-14 00:54:18 +00:00
dependabot[bot]
b4a7caea01 build: bump cc from 1.2.59 to 1.2.60 (#44188)
Bumps [cc](https://github.com/rust-lang/cc-rs) from 1.2.59 to 1.2.60.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/releases">cc's
releases</a>.</em></p>
<blockquote>
<h2>cc-v1.2.60</h2>
<h3>Fixed</h3>
<ul>
<li><em>(ar)</em> suppress warnings from <code>D</code> modifier probe
(<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1700">#1700</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md">cc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.59...cc-v1.2.60">1.2.60</a>
- 2026-04-10</h2>
<h3>Fixed</h3>
<ul>
<li><em>(ar)</em> suppress warnings from <code>D</code> modifier probe
(<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1700">#1700</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7cad9f5b10"><code>7cad9f5</code></a>
chore(cc): release v1.2.60 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1701">#1701</a>)</li>
<li><a
href="c15c3eb9f1"><code>c15c3eb</code></a>
fix(ar): suppress warnings from <code>D</code> modifier probe (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1700">#1700</a>)</li>
<li>See full diff in <a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.59...cc-v1.2.60">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cc&package-manager=cargo&previous-version=1.2.59&new-version=1.2.60)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-14 00:40:35 +00:00
dependabot[bot]
c041d57989 build: bump pillow from 12.1.1 to 12.2.0 in /etc/ci/scenario (#44186)
Bumps [pillow](https://github.com/python-pillow/Pillow) from 12.1.1 to
12.2.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/python-pillow/Pillow/releases">pillow's
releases</a>.</em></p>
<blockquote>
<h2>12.2.0</h2>
<p><a
href="https://pillow.readthedocs.io/en/stable/releasenotes/12.2.0.html">https://pillow.readthedocs.io/en/stable/releasenotes/12.2.0.html</a></p>
<h2>Documentation</h2>
<ul>
<li>Update 12.2.0 release notes <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9522">#9522</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Add loader plugins: AMOS abk, Atari Degas, 40+ more obscure formats
via Netpbm <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9482">#9482</a>
[<a href="https://github.com/bitplane"><code>@​bitplane</code></a>]</li>
<li>Update Python versions <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9515">#9515</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Jeffrey A. Clark -&gt; Jeffrey 'Alex' Clark <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9513">#9513</a>
[<a
href="https://github.com/aclark4life"><code>@​aclark4life</code></a>]</li>
<li>Add release notes for <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9394">#9394</a>,
<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9419">#9419</a>
and <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9456">#9456</a>
<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9467">#9467</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Add Amiga Workbench .info loader to 3rd party plugins list <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9459">#9459</a>
[<a href="https://github.com/bitplane"><code>@​bitplane</code></a>]</li>
<li>Merge PFM documentation into PPM <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9434">#9434</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update macOS tested Pillow versions <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9431">#9431</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Fix CVE number <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9430">#9430</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
</ul>
<h2>Dependencies</h2>
<ul>
<li>Update xz to 5.8.3 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9523">#9523</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update libjpeg-turbo to 3.1.4.1 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9507">#9507</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update libpng to 1.6.56 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9499">#9499</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update freetype to 2.14.3 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9485">#9485</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Updated libavif to 1.4.1 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9479">#9479</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Updated harfbuzz to 13.2.1 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9461">#9461</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update Ghostscript to 10.7.0 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9469">#9469</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update harfbuzz to 13.0.1 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9453">#9453</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update libavif to 1.4.0 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9460">#9460</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update freetype to 2.14.2 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9449">#9449</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update actions/download-artifact action to v8 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9451">#9451</a>
[@<a href="https://github.com/apps/renovate">renovate[bot]</a>]</li>
<li>Updated libpng to 1.6.55 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9425">#9425</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
</ul>
<h2>Testing</h2>
<ul>
<li>Cleanup .spider extension in the same test where it is added <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9517">#9517</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Run tests in parallel via tox for 3.5x speedup <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9516">#9516</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Enable colour in CI logs <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9486">#9486</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Update Ghostscript to 10.7.0 <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9469">#9469</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Simplify TGA test code <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9477">#9477</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Update tests to check for ValueError when encoding an empty image <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9464">#9464</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Upgrade CI from <code>macos-15-intel</code> to
<code>macos-26-intel</code> <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9454">#9454</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Add check-case-conflict hook <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9446">#9446</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Specify platform when pulling docker image <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9440">#9440</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>GHA: Cache libavif and webp builds for Ubuntu <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9437">#9437</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Update macOS tested Pillow versions <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9431">#9431</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
</ul>
<h2>Other changes</h2>
<ul>
<li>Check calloc return value <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9527">#9527</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
<li>Check all allocs in the Arrow tree <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9488">#9488</a>
[<a
href="https://github.com/wiredfool"><code>@​wiredfool</code></a>]</li>
<li>Reject non-numeric elements inside list coords <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9526">#9526</a>
[<a href="https://github.com/hugovk"><code>@​hugovk</code></a>]</li>
<li>Move variable declaration inside define <a
href="https://redirect.github.com/python-pillow/Pillow/issues/9525">#9525</a>
[<a
href="https://github.com/radarhere"><code>@​radarhere</code></a>]</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="3c41c09506"><code>3c41c09</code></a>
12.2.0 version bump</li>
<li><a
href="cdaa29eb52"><code>cdaa29e</code></a>
Check calloc return value (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9527">#9527</a>)</li>
<li><a
href="585b2f5a78"><code>585b2f5</code></a>
Check calloc return value</li>
<li><a
href="ecf011ea15"><code>ecf011e</code></a>
Check all allocs in the Arrow tree (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9488">#9488</a>)</li>
<li><a
href="cf6de8ca9b"><code>cf6de8c</code></a>
Reject non-numeric elements inside list coords (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9526">#9526</a>)</li>
<li><a
href="ffdcede651"><code>ffdcede</code></a>
Update 12.2.0 release notes (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9522">#9522</a>)</li>
<li><a
href="7929d7760f"><code>7929d77</code></a>
Added security release notes (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/149">#149</a>)</li>
<li><a
href="c4f7aa5dfb"><code>c4f7aa5</code></a>
Added security release notes</li>
<li><a
href="22cdb5f2e4"><code>22cdb5f</code></a>
Move variable declaration inside define (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9525">#9525</a>)</li>
<li><a
href="fc15b3b018"><code>fc15b3b</code></a>
Resize tall images vertically first (<a
href="https://redirect.github.com/python-pillow/Pillow/issues/9524">#9524</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/python-pillow/Pillow/compare/12.1.1...12.2.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pillow&package-manager=uv&previous-version=12.1.1&new-version=12.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-13 23:48:56 +00:00
Taym Haddadi
5d3ef741b3 Indexeddb: fix IDBKeyRange lowerBound/upperBound open flags (#44183)
Testing: covered by idbkeyrange.any.html test
part of https://github.com/servo/servo/issues/40983

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-13 22:08:05 +00:00
elomscansio
97901de941 script: Pass down &mut JSContext/CurrentRealm to AudioContext methods (#44175)
Refactor AudioContext methods to use &mut JSContext 

Testing:  Just refactor.
Fixes: Part of #42638

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-13 19:50:18 +00:00
atbrakhi
7b2c95030c devtools: implement objectPreview in console (#44181)
Show `objectPreview` in console. This preview is limited to 10. And only
when we expand, we see all items.

Testing: manual testing
Fixes: Part of #39858 

<img width="1008" height="607" alt="image"
src="https://github.com/user-attachments/assets/79fd6c18-f3a7-4f5e-8c21-61634153c362"
/>

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-13 18:48:11 +00:00
Taym Haddadi
a7ef47a46e Indexeddb: Cache IDBCursor.key conversion to preserve object identity (#44161)
Testing: Covered by idbcursor-key.any.html test.
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-13 18:14:26 +00:00
atbrakhi
8918b6f53a devtools: Do not use MAX_ITEMS in object preview (#44173)
Do not use `OBJECT_PREVIEW_MAX_ITEMS` in object preview(same as array).
With this it matches the Firefox behavior and shows the complete object.

Testing: Current tests are passing.
Fixes: part of #36027 
<img width="1174" height="1056" alt="image"
src="https://github.com/user-attachments/assets/3b1a738d-4fbe-4aee-a918-88a699d6be14"
/>

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-04-13 17:36:24 +00:00
atbrakhi
fce9b10bf7 devtools: Implement showing ArrayItems in preview (#44172)
implement showing `ArrayItems` in preview

Testing: Current tests are passing.
Fixes: Part of #36027 

<img width="1146" height="913" alt="image"
src="https://github.com/user-attachments/assets/af5b009c-5983-4949-a30b-39ea32b24d20"
/>

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-04-13 16:05:05 +00:00
Jonathan Schwender
69dbc16014 devcontainer: Build multi-arch image (#44162)
Also build an arm64 version of the devcontainer and combine both into a
multi platform image.
This also fixes the upload step, which was broken on main by
b5d454eca0.
We also allow triggering the publish job on forks via manual workflow
trigger, which allows more convenient testing.
[Manually triggered
workflow](https://github.com/servo/servo/actions/runs/24336772082)

Testing: This is a CI change.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-13 13:00:39 +00:00
eri
38f77f4bfb devtools: Move debugger_value_to_json to lib.rs (#44160)
Testing: Existing tests pass
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-13 11:19:19 +00:00
eri
d58f2d4dd5 devtools: Create UUID for objects created by console logging (#44164)
Testing: Existing tests pass
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-13 10:07:10 +00:00
niya
6cd95eaa51 mach: respect --yes when installing GStreamer on Macos (#44091)
When `mach bootstrap` is run without `--yes` or `--force` on macos:
Add warning that `mach bootstrap` command is being run without elevated
permissions.
Stop execution and ask user to run the command with `--yes` or install
GStreamer manually.

Testing:  mach does not have testing
Fixes: #44021

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-13 09:03:21 +00:00
Abubakar Abdulazeez Usman
65c0ed97a8 script: Avoid forwarding body event handlers without a browsing context (#44046)
When mutating window-reflecting event handler attributes on <body>,
HTMLBodyElement::attribute_mutated forwarded handlers to owner_window()
even for documents without a browsing context.
    
This caused handlers such as onload to be attached to the wrong window
in cases involving createHTMLDocument() and node cloning.
    
Only forward these handlers when the owner document has a browsing
context. This matches the has_browsing_context() check used by
window_event_handlers!(ForwardToWindow) and the spec algorithm.
    
The Range WPT expectations added for this issue are removed, as those
tests now pass. The onerroreventhandler.html test is marked as TIMEOUT
as its failure is a separate issue tracked in #44157 .



Testing: 
- ./mach fmt
- ./mach test-tidy
- ./mach test-wpt -r dom/ranges
- ./mach test-wpt -r
html/webappapis/scripting/events/onerroreventhandler.html
- ./mach try linux-wpt ( Try run
[#24328414549](https://github.com/arabson99/servo/actions/runs/24328414549))

Reproduced locally with the parent.html/child.html testcase from #36561.
Before this change, Servo logged "foo is not defined".
After this change, the error no longer appears.

Fixes: #36561

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-04-13 06:20:43 +00:00
Jonathan Schwender
b5d454eca0 devcontainer: Verify build on PRs. (#44111)
This allows us to verify that the devcontainer builds, when a PR changes
any of the affected files.


Testing: This is a CI change

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Sam <16504129+sagudev@users.noreply.github.com>
2026-04-13 05:59:29 +00:00
Simon Martin
625b53adb6 webgl: fix incorrect specification links (#44156)
I noticed that those links' fragments are all "off-by-one". This is due
to https://github.com/KhronosGroup/WebGL/pull/3762, that added a section
at the top of the specification. This patch fixes those links.

Testing: This is a comment-only change, so not covered by any automated
test. I manually navigated to a random subset of those links and checked
they do take to the correct section.

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-04-13 05:41:51 +00:00
Daniel Adams
ae0a9d33a1 webxr: Account for mock device VR/AR blend modes (#44155)
Previously the headless/mock device was just defaulting to opaque for
its environmentBlendMode,, but this value is actually not allowed for
immersive-ar sessions. This adds an override for
environment_blend_mode() on the headless DeviceAPI to return alpha blend
for immersive-ar sessions and opaque otherwise.

Testing: Fixes WPT test
`webxr/ar-module/xrSession_environmentBlendMode.https.html.ini`

Signed-off-by: Daniel Adams <msub2official@gmail.com>
2026-04-13 05:13:26 +00:00
Babalola Taiwo J
b7dcfdcf1c script: Remove unused has_sent_idle_message field from Window (#44154)
\`has_sent_idle_message\` was declared and initialized in \`Window\` but
never read anywhere. Removed the field and its initialization.

Fixes #44151

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-04-13 04:09:49 +00:00
CynthiaOketch
2124599d6b servoshell (Linux): Add CJK fonts for egui (#44138)
Configured fonts for Linux referring to the same pattern used for
Windows in #44055.
CJK font files are loaded from standard system font paths, trying
Noto Sans CJK (Ubuntu/Debian and Fedora/Arch paths) with WenQuanYi
Micro Hei as a fallback. Fonts that are not present on the system
are silently skipped.
Testing: Loaded `cjk_test.html` with the following content in servoshell
on Linux:
  ```html                                 
<!DOCTYPE html>
  <html>                                  
  <head>
  <title>ご利用ガイド - 경애하는</title>
  </head>                               
<body>
  <p>Test</p>
</body>
  </html>                                 
  Before: Tab title showed boxes (□□□□ - □□□□)
After: Tab title renders correctly (ご利用ガイド - 경애하는)
  ```                                    

Fixes part of #44066

---------

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-04-13 01:49:26 +00:00
dependabot[bot]
3379bf634f build: bump hyper-rustls from 0.27.7 to 0.27.8 (#44144)
Bumps [hyper-rustls](https://github.com/rustls/hyper-rustls) from 0.27.7
to 0.27.8.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/hyper-rustls/releases">hyper-rustls's
releases</a>.</em></p>
<blockquote>
<h2>0.27.8</h2>
<h2>What's Changed</h2>
<ul>
<li>Added HttpsConnector::new function by <a
href="https://github.com/0xIO32"><code>@​0xIO32</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/301">rustls/hyper-rustls#301</a></li>
<li>Exclude development scripts from published package by <a
href="https://github.com/weiznich"><code>@​weiznich</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/320">rustls/hyper-rustls#320</a></li>
<li>Drop dependency on rustls-pemfile by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/323">rustls/hyper-rustls#323</a></li>
<li>Fix tests to run on a random port by <a
href="https://github.com/erickt"><code>@​erickt</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/330">rustls/hyper-rustls#330</a></li>
<li>Upgrade to rustls-platform-verifier 0.7 by <a
href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/hyper-rustls/pull/338">rustls/hyper-rustls#338</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="6b94ec3ef1"><code>6b94ec3</code></a>
Bump version to 0.27.8</li>
<li><a
href="df300cfe7c"><code>df300cf</code></a>
Upgrade rustls-platform-verifier to 0.7</li>
<li><a
href="1c063f5e21"><code>1c063f5</code></a>
Take semver-compatible dependency updates</li>
<li><a
href="c66d2839df"><code>c66d283</code></a>
Bump MSRV to 1.85 (for rustls-platform-verifier -&gt; jni)</li>
<li><a
href="4b90026cb6"><code>4b90026</code></a>
Bump hyper from 1.8.1 to 1.9.0</li>
<li><a
href="4376d76423"><code>4376d76</code></a>
Take semver-compatible updates</li>
<li><a
href="8eaab3e6e6"><code>8eaab3e</code></a>
Take semver-compatible dependency updates</li>
<li><a
href="0deafa57c3"><code>0deafa5</code></a>
Bump rustls from 0.23.36 to 0.23.37</li>
<li><a
href="003b96e690"><code>003b96e</code></a>
Check for unexpected output if examples fail</li>
<li><a
href="81e75a4ba9"><code>81e75a4</code></a>
Fail <code>custom_ca_store</code> if <code>server</code> errors out</li>
<li>Additional commits viewable in <a
href="https://github.com/rustls/hyper-rustls/compare/v/0.27.7...v/0.27.8">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=hyper-rustls&package-manager=cargo&previous-version=0.27.7&new-version=0.27.8)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
Co-authored-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-13 01:44:09 +00:00
dependabot[bot]
b6620593ae build: bump rustls-webpki from 0.103.10 to 0.103.11 (#44148)
Bumps [rustls-webpki](https://github.com/rustls/webpki) from 0.103.10 to
0.103.11.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rustls/webpki/releases">rustls-webpki's
releases</a>.</em></p>
<blockquote>
<h2>0.103.11</h2>
<p>In response to <a
href="https://redirect.github.com/rustls/webpki/issues/464">#464</a>,
we've slightly relaxed requirements for
<code>anchor_from_trust_cert()</code> to ignore unknown extensions even
if they're marked as critical. This only affects parsing a
<code>TrustAnchor</code> from DER, for which most extensions are ignored
anyway.</p>
<h2>What's Changed</h2>
<ul>
<li>Backport parsing trust anchors with unknown critical extensions to
0.103 by <a href="https://github.com/djc"><code>@​djc</code></a> in <a
href="https://redirect.github.com/rustls/webpki/pull/466">rustls/webpki#466</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="57bc62ce53"><code>57bc62c</code></a>
Bump version to 0.103.11</li>
<li><a
href="d0fa01ee0a"><code>d0fa01e</code></a>
Allow parsing trust anchors with unknown criticial extensions</li>
<li>See full diff in <a
href="https://github.com/rustls/webpki/compare/v/0.103.10...v/0.103.11">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rustls-webpki&package-manager=cargo&previous-version=0.103.10&new-version=0.103.11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-13 01:01:31 +00:00
dependabot[bot]
c6987ebb82 build: bump pkg-config from 0.3.32 to 0.3.33 (#44146)
Bumps [pkg-config](https://github.com/rust-lang/pkg-config-rs) from
0.3.32 to 0.3.33.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/pkg-config-rs/blob/master/CHANGELOG.md">pkg-config's
changelog</a>.</em></p>
<blockquote>
<h2>[0.3.33] - 2026-04-12</h2>
<h3>Changed</h3>
<ul>
<li>Error output from <code>pkg-config</code> is included in the message
again to
help with finding the cause (<a
href="https://redirect.github.com/rust-lang/pkg-config-rs/issues/187">#187</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/rust-lang/pkg-config-rs/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pkg-config&package-manager=cargo&previous-version=0.3.32&new-version=0.3.33)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-13 00:40:14 +00:00
Simon Wülker
25d3f4b7a9 script: Don't re-parse link relations when binding element to tree (#44139)
The parsed relations of a element don't depend on its position in the
DOM tree at all, so this does nothing.

Testing: This should not change observable behaviour, WPT should catch
regressions

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-12 21:49:31 +00:00
Tim van der Lippe
7c5df4e45b script: Implement recording and restoring of values (#44137)
It fixes two new tests, but also regresses 4. That's because we don't
handle xx-small (we shouldn't, at least browsers are inconsistent on
what to do with that) and pre-existing issues where a `<font>` element
is already present as parent of the selected node. These are
pre-existing issues that are now correctly exposed.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-12 18:50:27 +00:00
Freya Arbjerg
b427fea6f8 devtools: Implement getBlackboxingActor (#44142)
Adds `BlackboxingActor` boilerplate and implements `getBlackboxingActor`

Testing: Added a geckordp test for `getBlackboxingActor`
Fixes: Part of https://github.com/servo/servo/issues/36027

Signed-off-by: Freya Arbjerg <git@arbjerg.dev>
2026-04-12 15:34:13 +00:00
Taym Haddadi
1908220198 Indexeddb: Follow the spec and make IDBRequest result/error getters throw while pending (#44128)
Testing: idbrequest WPT test.
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-12 15:23:05 +00:00
Martin Robinson
cdf13e7ca4 Make the pull request template more explicit (#44135)
There seem to be some common misconceptions about how to use the pull
request template such as:

 - The `Fixes` field going before the pull request description.
 - The `Testing` field being used to describe how the fix was tested
   locally.

This change attmepts to make the meaning of the fields of the template a
little bit more explicit to avoid confusion.

Testing: This is just updating the pull request template so no tests
necessary.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-12 08:31:59 +00:00
Martin Robinson
8eafa6e9ad script: Remove the duplicate implementation of selectors::Element (#44134)
Servo has had two implementations of `selectors::Element`, one used
during layout and one used for `Element#matches()` and
`Element#closest()`. The DOM APIs can trivially use the version that's
exposed to the layout interface, which allows removing the duplicated
implementation. This will eliminate code and prevent the two
implementations from drifting apart.

Testing: This should not change behavior in a testable way so should
be covered by existing tests.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-12 08:26:13 +00:00
Simon Martin
78305123bf script: Invalidate texture if there's a bound framebuffer in WebGLRenderingContext (#43608)
This should be done for CopyTexImage2D, like it is already done for
TexImage2D and CompressedTexImage2D.

Testing: Regular testsuite. I was unable to add a dedicated case because
all I could think of it check the bound buffer's status before and after
copyTexImage2D, but I could not find a way to change it from say
complete to something else.
Fixes: #23264

---------

Signed-off-by: Simon Martin <simon@nasilyan.com>
Signed-off-by: Martin Robinson <martin@abandonedwig.info>
Co-authored-by: Martin Robinson <martin@abandonedwig.info>
2026-04-12 07:21:38 +00:00
Abbas Olanrewaju Sarafa
040aa2a3a5 script: Move devtools_wants_updates from GlobalScope to Window (#44121)
Moved devtools_wants_updates from GlobalScope to Window

Testing: Compiles cleanly. ```./mach test-devtools``` gives different
results each time, ```./mach test-devtools
test_sources_list_with_data_inline_classic_script``` always pass though.
Fixes: #44106

Signed-off-by: Sabb <sarafaabbas@gmail.com>
Signed-off-by: Abbas Olanrewaju Sarafa <109840351+sabbCodes@users.noreply.github.com>
2026-04-12 05:36:59 +00:00
Martin Robinson
45972e07ab script: Rewrite the layout DOM wrappers (#44114)
This change reworks the layout DOM wrappers so that they are simpler and
easier to reason about. The main changes here:

**Combine layout wrappers into one interface:**

 - `LayoutNode`/`ThreadSafeLayoutNode` is combined into `LayoutNode`:
   The idea here is that `LayoutNode` is always thread-safe when used in
   layout as long as no `unsafe` calls are used. These interfaces
   only expose what is necessary for layout.
 - `LayoutElement`/`ThreadSafeLayoutElement` is combined into
   `LayoutElement`: See above.

**Expose two new interfaces to be used *only* with `stylo` and
`selectors`:**

`DangerousStyleNode` and `DangerousStyleElement`. `stylo`
and `selectors` have a different way of ensuring safety that is
incompatible with Servo's layout (access all of the DOM tree anywhere,
but ensure that writing only happens from a single-thread). These types
only implement things like `TElement`, `TNode` and are not intended to
be used by layout at all.

All traits and implementations are moved to files that are named after
the struct or trait inside them, in order to better understand what one
is looking at.

The main goals here are:

 - Make it easier to reason about the safe use of the DOM APIs.
 - Remove the interdependencies between the `stylo` and `selectors`
   interface implementations and the layout interface. This helps
   with the first point as well and makes it simpler to know where
   a method is implemented.
 - Reduce the amount of code.
 - Make it possible to eliminate `TrustedNodeAddress` in the future.
 - Document and bring the method naming up to modern Rust conventions.

This is a lot of code changes, but is very well tested by the WPT tests.
Unfortunately, it is difficult to make a change like this iteratively.
In addition, this new design comes with new documentation at
servo/book#225.

Testing: This should not change behavior so should be covered by
existing
WPT tests.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-12 04:22:06 +00:00
Jonathan Schwender
b3d359fabf devcontainer: Fix build error on macos (#44126)
When building the devcontainer from source on arm macOS, we get arm
Ubuntu, for which we don't have a prebuild mozjs version. That triggers
a compilation from source, which fails, due to issues finding String.h.
I can't confirm this, but it might be because the mounted workspace is
case-insensitive. We definitly don't want that, so just make sure that
the cargo target directory is in a named volume. That also has the
advantage that we don't clobber the hosts target dir and still persist.

Testing: Manually tested on macOS.
Fixes:  ./mach build in a devcontainer built from source on arm64 macOS.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-12 03:33:48 +00:00
Servo WPT Sync
d854cbacf4 Sync WPT with upstream (12-04-2026) (#44129)
Automated downstream sync of changes from upstream as of 12-04-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
2026-04-12 01:37:08 +00:00
Simon Wülker
64f4f080dd script: Unbind <script> elements properly from the tree (#44127)
Necessary for https://github.com/servo/servo/pull/44120

Testing: After https://github.com/servo/servo/pull/44120 we would crash
on WPT without this change. Given that this is a pretty obscure bug with
next to no chance of regressing, I think its okay to wait for that PR
for test coverage?

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-11 20:22:18 +00:00
rovertrack
5fb69ec3f8 Push GlobalScope::crypto down into Window and WorkerGlobalScope (#44122)
Fixes: #44105 
moved member and initialization of crypto in Globlalscope to window and
workerGlobalScope
Testing: required tests passed 
` 
web-platform-test
Ran 80 checks (78 subtests, 2 tests)
Expected results: 80
Unexpected results: 0
OK
`

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-11 19:29:40 +00:00
Kelechi Ebiri
29c5604055 libservo: Export CookieSource in public API (#44124)
Fixes: #44102

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-11 18:22:14 +00:00
Jonathan Schwender
a13e3852cd bootstrap: Stop installing cargo-about (#44123)
cargo-about is only used in the ./mach release command, which will only
be used by very few people (when preparing a release). Hence it doesn't
make sense to install it for everyone, and instead we can just tell the
user how to install if it is missing, and save resources for everyone
else.

Testing: Not tested, but trivial

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-11 16:55:42 +00:00
Jonathan Schwender
6bfaab4079 bootstrap/devcontainer: Install required packages for wpt. (#44109)
Based on our linux-wpt.yml workflow update our bootstrap and
devcontainer package list.
This should make the local environment closer to our CI environment when
running WPT. We only purge the droid font in the devcontainer, since we
shouldn't purge packages for the user.


mesa-vulkan-drivers was added in
71e0372ac1, so it's probably required for
WebGPU.
fonts-noto-cjk was added in 2b0d2ecc73.

In both cases no reason was given why it can't be in bootstrap, so
presumably its just an oversight.

Testing: bootstrap is ran in CI, and the packages were already being
installed by the wpt workflow.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-11 16:21:43 +00:00
Tim van der Lippe
ec513ff851 script: Split up contenteditable.rs into multiple files (#44110)
This file was getting way too big and too cluttered. Instead, split it
up into multiple files in a dedicated folder.

Part of #25005
Part of #43709

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-11 15:18:36 +00:00
Domenico Rizzo
93c9918cd5 script: Replace WebGLShader Drop implementation with a droppable substruct (#26488) (#44119)
Implementing Drop for DOM types is being forbidden. This change moves
the shader deletion logic into a separate DroppableWebGLShader struct,
allowing WebGLShader to comply with this restriction while still
ensuring GPU resources are released when the object is finalized.

Testing: Covered by existing WebGL tests.
Fixes: #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-04-11 13:30:48 +00:00
Simon Wülker
84ce5a6c14 script: Don't associate form elements with forms across shadow boundaries (#44117)
Step 4 of [`reset the form
owner`](https://html.spec.whatwg.org/multipage/#reset-the-form-owner)
says to search for matching `<form>` elements in the same tree. We were
searching in the owner document, which is not the same when the form
element is in a shadow tree.

Testing: A new test starts to pass
Part of https://github.com/servo/servo/issues/44113 (unblocks my patch
that would otherwise crash)

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-11 13:05:22 +00:00
Abbas Olanrewaju Sarafa
00ef0f439f servo: Remove unnecessary RefCell from site_data_manager (#44116)
Removed unnecessary ```RefCell``` from ```site_data_manager```

Testing: ```./mach test-unit -p servo``` result; ```Summary [ 10.204s] 1
test run: 1 passed, 0 skipped```
Fixes: #44100

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-11 12:25:58 +00:00
Kelechi Ebiri
3cb97fc17b script: Move cookie_store from GlobalScope into Window (#44115)
Push GlobalScope::cookie_store down into Window

Testing: ./mach test-wpt tests/wpt/tests/cookiestore
Fixes: #44107

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-11 11:27:39 +00:00
Jonathan Schwender
d8cc8f3992 ci: Secure release workflow using environment (#44108)
The publish environment enforces additional restrictions, mainly that
the workflow can only be run from protected branches and additional
prevents access of the publish secrets from workflows which do not use
this environment.

Testing: Requires a manual workflow run on a protected branch. Given
that we already tested environments in previous PRs, I think this PR
might be safe to test after merging, instead of protecting the PR
branch.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-11 08:09:23 +00:00
Martin Robinson
12a655d42c script: Move StyleData to Element from Node (#44074)
Many things are nodes, such as `CharacterData` and attributes. They
don't need style data at all. This saves 16 bytes on every attribute and
text node.

Testing: This should not change testable behavior (only save some
memory),
so it should be covered by existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-04-11 07:46:28 +00:00
niya
9fff951a5e storage: fix incorrect data sharing by passing document origin to storage thread (#43988)
Changes all the uses of `ServoUrl` to `ImmutableOrigin` in
`WebStorageThreadMsg`

Testing: Adds a test case as described in the issue.

```html
<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title></title>
</head>

<body>
  <main>
    <h1>Tab and Program crashes!</h1>
    <iframe srcdoc="
          <body>
            <p>Hello Web users! <br/> I am an iframe, <br /> I set a key and then retreive it. </p> 
            <script>
              for (let i = 0; i < 1000; i++) {
                window.localStorage.setItem('truth', 'Servo is awesome! 🌐')
                const example = window.localStorage.getItem('truth')
                
                console.log(example === 'Servo is awesome! 🌐')
              }
            </script>
          </body> 
          "></iframe>
  </main>
</body>

</html>

```

Fixes: #44001

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-11 07:26:24 +00:00
Euclid Ye
99c53f8cdf layout/script: Remove unused layout optimization heuristics (#44103)
`dom_count` was used to determine whether it is worth it to run layout
parallel algorithm.
Now this is based on `layout_threads` pref.

Testing: Just removing dead code.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-11 05:58:01 +00:00
Jonathan Schwender
f59491d36f CI: Simplify release workflow (#44085)
Using the new yaml anchor feature, we can inline the upload_release
workflow file without duplicating code.
In combination with the matrix feature this allows us to remove quite a
bit of duplication. I'm not sure why we didn't use matrix to begin with.

This is also a preparation for a follow-up PR, that uses github
environments to improve secret protection, since reusable workflows
don't support environments.

Testing: [manually triggered nightly
release](https://github.com/servo/servo/actions/runs/24236862409)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-11 05:50:28 +00:00
webbeef
80e8441231 script: make all keyboard events composed (#44094)
Adjust event targeting for keyboard events when a shadow host is
involved. This is needed to not interfere with keyboard default action
like tabindex focusing.

Testing: Updated WPT tests expectations
Fixes: #43809

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-04-11 01:16:05 +00:00
Martin Robinson
1444aa942b script: Make DocumentFocusHandler hold a FocusableArea (#44029)
Make Servo match the focus bits of the HTML specification a bit more by
storing a `FocusableArea` as the currently focused thing in a
`Document` instead of an optional `Element`. There is always a focused
area of a `Document`, defaulting to the viewport. This is important to
support the case of focused navigables and image maps parts in the
future.

Some focus chain debugging code has been removed as the focus chain
concept needs to be reworked to match the specification more closely.

Testing: This should not change behavior so existing tests should
suffice.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-10 21:37:42 +00:00
Messi II Innocent R.
74de42f4f7 canvas: Make ImageBitmapRenderingContext render to the canvas (#43984)
I noticed that the transferFromImageBitmap() was running without errors
but the canvas stayed blank and this was becacuse of two issues:

The mark_as_dirty was empty meaning the canvas never knew it needed to
repaint
The BitmapRenderer context had no rendering pipeline as such no ImageKey
was allocated and update_rendering always returned false, so the way I
fixed it is by

1. Implemented mark_as_dirty to call self.canvas.mark_as_dirty()
2. Allocated an ImageKey for BitmapRenderer contexts
3.Implemented set_image_key and update_rendering that sends the bitmap's
pixel data to WebRender via the paint API
4, Calling mark_as_dirty after set_bitmap in TransferFromImageBitmap

Now the reason we are setting an ImageKey on the
ImageBitmaRenderingContext is because it needs one to render to the
screen and without it the canvas was always blank

Also I noticed that for some reasons I don't understand yet, the
createImageBitmap hangs or is slow to render but after loading servo on
an open tab, if I then go ahead and open another tab and paste the file
link there, the previous tab which had the bitmap image now renders
properly

Fixes: #43565

<img width="383" height="238" alt="Screenshot from 2026-04-06 13-44-28"
src="https://github.com/user-attachments/assets/4c5096ba-ee84-4e7a-a3c6-673cc12276c4"
/>
<img width="389" height="292" alt="Screenshot from 2026-04-06 15-38-55"
src="https://github.com/user-attachments/assets/43b45e60-61d8-48de-b53e-6da5ab988768"
/>

Signed-off-by: Messi002 <rostandmessi2@gmail.com>
2026-04-10 19:20:30 +00:00
Josh Matthews
f70f94ad0e servoshell: Update egui to 0.34. (#44053)
Testing: We have no automated testing for the servoshell UI. Some quick
manual testing of servo.org seemed to work as expected.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-10 19:19:01 +00:00
Simon Wülker
0fef52f10c script: Remove layout helper traits (#44092)
Servo has lots of `LayoutXYZHelper` traits that are used to define
additional methods on `LayoutDom<XYZ>`. We can replace them with `impl
LayoutDom<XYZ>` blocks, reducing the number of LoC and making it easier
to add or modify methods.

Testing: These should be covered by existing tests

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-10 18:31:10 +00:00
Kelechi Ebiri
a670c7a52b script: implement missing steps for form submission (#43700)
Implement missing history handling steps for form submission 
Test: ./mach test-wpt
tests/wpt/tests/html/semantics/forms/form-submission-0
Fixes: #43670

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-10 18:13:46 +00:00
Jonathan Schwender
34337273a3 deps: Fix sea-query pre-release versions (#44093)
This prevents issues for users that don't already have a lockfile, since
prerelease versions can have breaking changes.
This should also be backported to the release branch.

Testing: No changes, covered by existing tests.
Fixes: #44089

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-10 18:06:48 +00:00
Narfinger
a80744cc32 script: Move more iterators to unrooted iterators (#44018)
This is another part of moving more operations safely to unrooted
iterators.
- Some uses of inclusively_*_siblings
- Some uses of children()
- Some uses of child_elements()

Testing: Compilation is the test as we only use previously made iterator
functions.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-10 18:03:03 +00:00
niya
c3d4c014c7 localstorage: test storage is not shared across iframes with opaque origins (#44038)
Adds a WPT test to make sure we do not share the storage thread between
any document that has an opaque URL.
The test is required for #43988

Testing: Adds a WPT test.
Fixes: #44001

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-10 17:58:58 +00:00
Babalola Taiwo J
3bf38ef7ea script: Fix panic in compressedTexSubImage2D when no base image exists (#44050)
Calling `compressedTexSubImage2D` without a prior `compressedTexImage2D`
for the same texture target and level caused the panic at
`tex_image_2d.rs:633` because `image_info_for_target` returned `None`
and `.unwrap()` was called on it.

Per the WebGL spec, this should generate `GL_INVALID_OPERATION` instead
of panicking. So this PR replaces the unwrap with proper error handling.
And also includes a WPT crash test that reproduces the original panic.

Fixes #43527

---------

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-04-10 17:08:55 +00:00
Taym Haddadi
daf15e8e07 IndexedDB: Implement storage-key checks for IDBFactory entry points (#44088)
Testing: idbfactory-databases-opaque-origin.html test passed.
Fixes: part of https://github.com/servo/servo/issues/40983

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-10 17:00:11 +00:00
Jonathan Schwender
c3d2df22c0 release: Add job to publish to crates.io (#43972)
When triggering the release action on a non-protected branch in this
repo, the job is rejected (as intended):
<img width="1484" height="304" alt="image"
src="https://github.com/user-attachments/assets/236d3a41-2765-4652-8709-93110e03c77b"
/>

When triggering the action on a protected branch in this repository, the
publish-crates-io job will be pending, until explicitly approved by one
of the required approvers (thanks to the `environment` settings).
This allows us to publish all of our packages in one go.


Testing: Tested by manually
[triggering](https://github.com/servo/servo/actions/runs/24119955943/job/70371705395)
a release for `0.1.0-rc2`, which got successfully published to
crates.io. This was also a resume-after-cancellation test, since the
first ~30 crates of the release had already been published via `cargo
publish --workspace`, before running into the issue that `cargo publish
--workspace` can't resume after intermediate failures. The last commit
"Fix buffering issue in CI" is untested, and was added after observing
the stdout log messages only appearing at the end of the script. That
commit is trivial though, and probably does not justify using crates.io
resources for another test release.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Mukilan Thiyagarajan <mukilanthiagarajan@gmail.com>
2026-04-10 16:54:53 +00:00
Abbas Olanrewaju Sarafa
fbb37acf15 layout: Resolve word-spacing percentages against computed font-size (#44031)
Changes ```word-spacing``` to resolve percentages against the computed
```font-size```, instead of the size of a space.

Testing:
```tests/wpt/tests/css/css-text/word-spacing/word-spacing-percent-001.html```
is now passing

Fixes: #43997

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-10 16:17:22 +00:00
Tim van der Lippe
6118b0e5e4 script: Further implement fontsize command (#44075)
Several more TODO's are now implemented:

1. We correctly restore values for fontsize now
2. We implement relevant logic in wrap_node_list
3. We implement simple modifiable
4. We clear overrides whenever the selection changes
(which is triggered for both the selection itself and
any containing  ranges).

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-10 15:59:38 +00:00
Euclid Ye
b62dc72c73 config: Fix panic when converting convertible PrefValue::Int to u64 (#44079)
The macro `impl_from_pref!` would cause panic in this case.

Testing: Add more test cases to existing UT.
Fixes: #44078

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-10 15:51:07 +00:00
Simon Wülker
80c6846dfb script: Accept names of PerformanceTiming members as marks in Performance.measure (#43990)
This change allows users to pass a mark like `"navigationStart"` to
`Performance.measure` and that will resolve to the value of
`navigationStart` on the `PerformanceTiming` interface.

Testing: New tests start to pass
Part of https://github.com/servo/servo/issues/43821 - we no longer throw
an exception in the case above.

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-10 14:36:10 +00:00
Jonathan Schwender
03a7d42cf5 release: Only mark scheduled runs as latest nightly. (#44086)
If we make manual releases, e.g. for release candidate testing, then
they shouldn't appear on the nightly download page on servo.org, which
just displays the release that is marked as "latest".

Since the Github API documentation updated to a new API version, also
opt-in to the new version while we are at it.
There seem to be no changes affecting the usage in release.yml, but
probably the old API will be removed eventually, so why not switch to
the new version now.

See
https://docs.github.com/en/rest/releases/releases?apiVersion=2026-03-10#create-a-release

Testing: [Manual release workflow
run](https://github.com/servo/servo/actions/runs/24241705213). The
release should not be marked as latest after the run finishes.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-10 13:15:29 +00:00
Ashwin Naren
046a8346c8 indexeddb: Implement encoding module (#39009)
Indexeddb keys need to remain sorted in the database, so that key range
queries can be made via sql. This allows for key range querying without
having to load each key into memory. The solution is to serialize keys
with a custom encoding that sorts them according to the spec. The
implementation is taken from firefox.

Testing: WPT, and unit tests
Fixes: None

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
2026-04-10 09:43:21 +00:00
eri
81fb8293d4 devtools: Clean up StyleRuleActor variable names (#44084)
Last naming changes for `StyleRuleActor`.

Testing: Existing tests pass
Part of: #43606

Signed-off-by: eri <eri@igalia.com>
2026-04-10 08:48:37 +00:00
Kelechi Ebiri
5606cf3f65 Stylo: Enable text align match parent servo (#44073)
Companion PR for servo/stylo#350
Testing: Various WPT improve
Fixes: #43575

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-10 07:37:45 +00:00
Tim van der Lippe
c8029ea092 script: Rename CanGc::note() to CanGc::deprecated_note() (#44081)
Per the suggestion in

https://servo.zulipchat.com/#narrow/channel/263398-general/topic/PSA.3A.20avoid.20new.20usages.20of.20CanGc.20whenever.20possible/near/583995807
to mark this method as deprecated and make clear it shouldn't be used
anymore, as alternatives exist.

Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-10 06:07:52 +00:00
Luke Warlow
55e586737b script: Implement drop-down select multiple (#43189)
Implement drop-down select multiple: 
 - Updates the embedder API to support multi-selects.
- Updates the select element to correctly reset when multiple attribute
is removed.
- Select now renders "n selected" as button text when more than 1, or 0
options are selected.

Note that listbox selects are not yet supported, once they are these new
features will be for `<select multiple size=1>`.

Testing: WPTs and also manually using
https://demo.lukewarlow.dev/css-forms.html. The two test regressions are
due to the lack of listbox support rather than an issue with this PR.
Fixes: #38509

---------

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
Signed-off-by: Martin Robinson <martin@abandonedwig.info>
Co-authored-by: Martin Robinson <martin@abandonedwig.info>
2026-04-10 05:47:21 +00:00
Tim van der Lippe
4b02f87cce script: Implement preserving ranges for moves during commands (#44041)
This ensures that the selection after the move is as expected.
It mostly fixes tests that had fully passing implementation, but
the after fontsize was incorrect, since the selection wasn't
properly updated.

Some new regressions were false positives.

Part of #25005

Testing: WPT

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-04-10 04:35:08 +00:00
dependabot[bot]
eb9784c9fb build: bump libredox from 0.1.15 to 0.1.16 (#44077)
Bumps libredox from 0.1.15 to 0.1.16.


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libredox&package-manager=cargo&previous-version=0.1.15&new-version=0.1.16)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-10 00:40:36 +00:00
Euclid Ye
560498923e script: Skip clearing subtree layout boxes of detached element when attaching shadow to it (#44052)
There is no layout boxes to clear in this case. For the example in
#43998,
this skips the traversal many times.

Testing: Should not change visible behaviour.
[Try](https://github.com/servo/servo/actions/runs/24131782865).

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-10 00:12:07 +00:00
Euclid Ye
8b61ca94fc script: Make Node::clean_up_style_and_layout_data work as named (#44072)
Do not `cancel_animations_for_node` for this function.
We can then reuse it more often.

Testing: Just a refactor.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-10 00:11:19 +00:00
elomscansio
65b917bd4f devtools: Replace new with register for NodeActor (#44071)
Added a `register` method to `NodeActor` following the same pattern used
by other actors in the devtools codebase. Updated
`NodeInfoToProtocol::get_or_register_node_actor` to use it instead of
constructing `NodeActor` directly.
Testing: 
Ran `./mach try linux-unit-tests` and `./mach test-devtools`. No new
failures introduced.

Fixes:part of  #43800

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-10 00:06:39 +00:00
rtjkro
f56c108625 font: Refactor font list generation on OpenHarmony platform (#44061)
font: Use `read_fonts` module to generate font list on OpenHarmony
platform. Specifically:

- `Family name` is obtained from the font's `name` table.
- `width` & `weight`  is obtained from the font's `os2` table.
- `style` is obtained from the font's `postscript` table.

Additionally, I'd like to mention that I plan to add a caching mechanism
to store the font list in the near future (as mentioned in the related
issue)

Reference: [TrueType reference
manual](https://developer.apple.com/fonts/TrueType-Reference-Manual/RM06/Chap6.html)
Testing: No behavior changes expected.
Fixes: Part of [#43596](https://github.com/servo/servo/issues/43596)

---------

Signed-off-by: Richard Tjokroutomo <richard.tjokro2@gmail.com>
2026-04-09 16:18:28 +00:00
elomscansio
11cea2f023 devtools: Replace new with register for PageStyleActor (#44068)
Added a `register` method to `PageStyleActor` following the same pattern
used by other actors in the devtools codebase. Updated
`InspectorActor::register` to use it instead of constructing
`PageStyleActor` directly.
  Testing: 
Ran `./mach try linux-unit-tests` and `./mach test-devtools`. No new
failures introduced.

  Fixes:part of  #43800

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
Signed-off-by: eri <eri@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-09 16:07:20 +00:00
atbrakhi
9e5e5603df devtools: Use DebuggerValue in console (#44064)
Use same `DebuggerValue` in console actor as well. This helps us have
single source of truth!

Testing: Added a new test
Fixes: part of https://github.com/servo/servo/issues/39858

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-09 14:25:02 +00:00
Martin Robinson
f45223568e servoshell: Ignore requests to focus unknown WebViews via keyboard shortcuts (#44070)
Instead of panicking when pressing a keyboard shortcut for an uknown
WebView, just silently ignore the request. This code path is only
followed when using keyboard shortcuts, so this isn't going to hide any
unexpected behavior.

Testing: We do not have testing at this level of servoshell.
Fixes: #44056.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-09 14:09:07 +00:00
Messi II Innocent R.
4029f196e6 media: Clean up shadow root content when removing controls (#43983)
When media controls are removed (either by removing the controls
attribute or by removing the element from the DOM), the shadow root's
children are now cleared. This breaks the reference cycle between the js
mediacontrols instance and the media element, the event listeners and
this.media reference in the controls script would otherwise keep the
element alive and prevent garbage collection.

I tested the controls and it renders correctly and deleting a video with
controls doesn't crash.

Fixes: #43828

Signed-off-by: Messi002 <rostandmessi2@gmail.com>
2026-04-09 13:21:03 +00:00
CynthiaOketch
c52726eda0 devtools: Replace new with register for HighlighterActor (#44067)
Added a `register` method to `HighlighterActor` following the same
pattern used by other actors in the devtools codebase. Updated
`InspectorActor::register` to use it instead of onstructing
`HighlighterActor` directly.
  Testing: 
Ran `./mach try linux-unit-tests` and `./mach test-devtools`. No new
failures introduced.

  Fixes:part of  #43800

---------

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-04-09 12:40:40 +00:00
atbrakhi
f32cc3dc51 devtools: Make isAsync and isGenerator optional (#44023)
Make `isAsync` and `isGenerator` optional

Testing: Current tests as passing
Fixes:  part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Signed-off-by: eri <eri@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-09 11:52:09 +00:00
Oriol Brufau
e9fbed1d74 fonts: Use ICU's Language instead of Stylo's XLang (#44057)
Testing: Not needed, no behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-04-09 10:53:44 +00:00
Euclid Ye
4c6d13d11e servoshell (Windows): Add CJK fonts for egui (#44055)
We configure fonts for Windows referring to [doc
example](https://docs.rs/egui/latest/egui/struct.FontDefinitions.html).
There is a [discussion](https://github.com/emilk/egui/discussions/1344)
on this about various ways.

Testing: Not possible to write automated test.
Before: 
<img width="232" height="109" alt="image"
src="https://github.com/user-attachments/assets/be9f3724-9ee5-4157-bd9d-313b519d1e57"
/>

After: 
<img width="243" height="67" alt="image"
src="https://github.com/user-attachments/assets/e748389f-48e3-48c1-bdaf-23c49837a1c6"
/>

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-09 10:43:41 +00:00
atbrakhi
3c4b8c61ea devtools: Handle different number values and their types (#44022)
Handle different number values and their types

Testing: Current tests are passing
Fixes:  part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-09 10:42:05 +00:00
Martin Robinson
718c8913af script/constellation: Rename and consolidate cross-Document focus messaging (#44020)
There are two times that Servo needs to ask other `Document`s to either
focus or blur.

- During processing of the "focusing steps". When a new element gains
  focus this may cause focus to be lost or gained in parent `<iframe>`s.
- When calling `focus()` on a DOM Window from another origin.

In both of these cases we need to request that a `Document` gain or lose
focus via the Constellation, but in the second case we may have a
`BrowsingContextId` of the `<iframe>` gaining focus and a
`FocusSequence`. This change splits those cases into two kinds of
messages.

Finally, run the entire focusing steps when calling `window.focus()`
instead of going to the constellation immediately. This will be
important in a followup changes where messaging order is made more
consistent.

Testing: This should not change behavior so is covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-09 08:59:47 +00:00
Taym Haddadi
553f125773 IndexedDB: Align IDBDatabase.transaction validation with the IndexedDB spec (#44059)
Testing: Existing WPT test pass.
part of https://github.com/servo/servo/issues/40983

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-09 08:59:05 +00:00
elomscansio
ae5abfbdea mach: remove shorthand support for direct test file paths in mach test-unit (#43951)
This PR removes support for passing direct test file paths (e.g.,
`./mach test-unit <test_file.rs>`) to `mach test-unit`.

Previously, this shorthand was supported in `test-unit` but was
subsequently broken in #39897. Supporting this behavior now requires
extracting test names from a generic parameter list, which is
error-prone due to the presence of arbitrary arguments and inconsistent
argument ordering.

With this change, `mach test-unit` aligns more closely with standard
Cargo test patterns. Users are expected to specify test modules or
patterns instead (e.g., `./mach test-unit <module>::` or using
Cargo-compatible arguments).

This simplifies the implementation and avoids maintaining fragile logic
for shorthand support that was not widely used.

---

### Testing

* Ran `./mach test-unit` with various valid patterns and module-based
inputs
* Verified that tests execute correctly across supported use cases
* Confirmed that removal of direct file path support does not affect
standard workflows

---

Fixes: #41065

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-09 07:41:31 +00:00
Gae24
a0d397bd1a script: Queue a networking task to proceed when a pending module fetch is terminated (#44042)
Our implementation of [fetch a single module
script](https://html.spec.whatwg.org/multipage/webappapis.html#fetch-a-single-module-script)
was missing the task queueing steps:
```
5. If moduleMap[(url, moduleType)] is "fetching", wait in parallel until that entry's value changes,
   then queue a task on the networking task source to proceed with running the following steps.

6. If moduleMap[(url, moduleType)] exists, run onComplete given moduleMap[(url, moduleType)], and return.
```
Instead we appended a `PromiseNativeHandler`, which would run
`on_complete` when resolved, on the promise of the pending fetch.

Testing: This change shouldn't be observable since modules are evaluated
in sync, but it's required for #39417.

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-09 07:27:53 +00:00
dependabot[bot]
046ed0f236 build: bump tokio from 1.51.0 to 1.51.1 in the tokio-rs-related group (#44048)
Bumps the tokio-rs-related group with 1 update:
[tokio](https://github.com/tokio-rs/tokio).

Updates `tokio` from 1.51.0 to 1.51.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tokio/releases">tokio's
releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.51.1</h2>
<h1>1.51.1 (April 8th, 2026)</h1>
<h3>Fixed</h3>
<ul>
<li>sync: fix semaphore reopens after forget (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8021">#8021</a>)</li>
<li>net: surface errors from <code>SO_ERROR</code> on <code>recv</code>
for UDP sockets on Linux (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8001">#8001</a>)</li>
</ul>
<h3>Fixed (unstable)</h3>
<ul>
<li>metrics: fix <code>worker_local_schedule_count</code> test (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8008">#8008</a>)</li>
<li>rt: do not leak fd when cancelling io_uring open operation (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7983">#7983</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/tokio-rs/tokio/issues/7983">#7983</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7983">tokio-rs/tokio#7983</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8001">#8001</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8001">tokio-rs/tokio#8001</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8008">#8008</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8008">tokio-rs/tokio#8008</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8021">#8021</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/8021">tokio-rs/tokio#8021</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="98df02d7a4"><code>98df02d</code></a>
chore: prepare Tokio v1.51.1 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8023">#8023</a>)</li>
<li><a
href="3ea11e2a5f"><code>3ea11e2</code></a>
sync: fix semaphore reopens after forget (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8021">#8021</a>)</li>
<li><a
href="c79121391d"><code>c791213</code></a>
rt: do not leak fd when cancelling io_uring open operation (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7983">#7983</a>)</li>
<li><a
href="ad8c59add6"><code>ad8c59a</code></a>
net: surface errors from <code>SO_ERROR</code> on <code>recv</code> for
UDP sockets on Linux (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8001">#8001</a>)</li>
<li><a
href="654d38b132"><code>654d38b</code></a>
metrics: fix <code>worker_local_schedule_count</code> test (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8008">#8008</a>)</li>
<li><a
href="857ba80933"><code>857ba80</code></a>
docs: improve contributing docs on how to specify crates dependency
versions ...</li>
<li><a
href="95b9342da7"><code>95b9342</code></a>
chore: remove path deps for tokio-macros 2.7.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8007">#8007</a>)</li>
<li>See full diff in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-1.51.0...tokio-1.51.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio&package-manager=cargo&previous-version=1.51.0&new-version=1.51.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 06:50:01 +00:00
Tim van der Lippe
1c849a362d script: Fix computation of "fontsize" command value (#44039)
The initial interpretation of "convert the font size to the value in
pixels" was completely off. I thought it meant the existing font
elements in the DOM, but instead it implied that you would have to
convert these into pixels according to the HTML size table.

Therefore, use the implementation in Stylo to convert the html size to a
keyword and then compute the value for the keyword.

To make that work, we need to compute the pixel size as fallback when
resolving the CSS value on the node. We check if it were pixels and then
go through the conversion. If they aren't pixels, we can skip all that
logic and directly convert, saving a few cycles.

Part of #25005

Testing: WPT

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-04-09 06:38:42 +00:00
dependabot[bot]
5eb2ffc623 build: bump thin-vec from 0.2.14 to 0.2.15 (#44051)
Bumps [thin-vec](https://github.com/gankra/thin-vec) from 0.2.14 to
0.2.15.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/mozilla/thin-vec/blob/main/RELEASES.md">thin-vec's
changelog</a>.</em></p>
<blockquote>
<h1>Version 0.2.15 (2025-02-19)</h1>
<ul>
<li>Support AutoTArrays created from rust in Gecko FFI mode.</li>
<li>Add extract_if.</li>
<li>Add const new() support behind feature flag.</li>
<li>Fix <code>thin_vec</code> macro not being hygienic when
recursing</li>
<li>Improve extend() performance.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="70bcca0960"><code>70bcca0</code></a>
chore: Bump version to v0.2.15</li>
<li><a
href="322423b7a6"><code>322423b</code></a>
Fix miri error on extract_if().</li>
<li><a
href="eca5334c29"><code>eca5334</code></a>
Don't make push_unchecked public.</li>
<li><a
href="90e23c39cc"><code>90e23c3</code></a>
Minor nits, go back to call push_reserved push_unchecked.</li>
<li><a
href="ee9d6bb28f"><code>ee9d6bb</code></a>
Optimize extend() to avoid unnecessary capacity checks</li>
<li><a
href="7fd47080c0"><code>7fd4708</code></a>
feat: add const_new feature for const ThinVec::new()</li>
<li><a
href="beb652d66b"><code>beb652d</code></a>
Merge pull request <a
href="https://redirect.github.com/gankra/thin-vec/issues/75">#75</a>
from jtracey/patch-1</li>
<li><a
href="6f3da2525d"><code>6f3da25</code></a>
Merge pull request <a
href="https://redirect.github.com/gankra/thin-vec/issues/73">#73</a>
from emilio/auto-array-tweaks</li>
<li><a
href="d3d7475118"><code>d3d7475</code></a>
gecko: Keep the auto-bit across relocations.</li>
<li><a
href="faa01eb790"><code>faa01eb</code></a>
Merge pull request <a
href="https://redirect.github.com/gankra/thin-vec/issues/66">#66</a>
from GnomedDev/extract-if</li>
<li>Additional commits viewable in <a
href="https://github.com/gankra/thin-vec/compare/v0.2.14...v0.2.15">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=thin-vec&package-manager=cargo&previous-version=0.2.14&new-version=0.2.15)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 00:38:28 +00:00
dependabot[bot]
071c35e5a2 build: bump zerofrom-derive from 0.1.6 to 0.1.7 (#44049)
Bumps [zerofrom-derive](https://github.com/unicode-org/icu4x) from 0.1.6
to 0.1.7.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/unicode-org/icu4x/blob/main/CHANGELOG.md">zerofrom-derive's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h2>icu 2.2.x</h2>
<p>Several crates have had patch releases in the 2.2 stream:</p>
<ul>
<li>Components
<ul>
<li>(2.2.1) <code>icu_calendar</code>
<ul>
<li>Fix extended year calculations in Gregorian-like and Coptic-like
calendars (unicode-org#7849)</li>
</ul>
</li>
</ul>
</li>
</ul>
<h2>icu4x 2.2</h2>
<ul>
<li>Components
<ul>
<li>General
<ul>
<li>Use HTTPS links in docs (unicode-org#7212)</li>
<li>Update MSRV to 1.86 (unicode-org#7576)</li>
<li>Updated to CLDR 48.2 (unicode-org#7792)</li>
<li>Replace <code>experimental</code> features with
<code>unstable</code> features (unicode-org#7566)</li>
<li>Add categories and keywords to Cargo.toml for all components
(unicode-org#7737)</li>
</ul>
</li>
<li><code>icu_calendar</code>
<ul>
<li>Add <code>Date::try_new</code>, which replaces
<code>Date::try_new_from_codes</code>, and takes typed year/month
values. (unicode-org#7773, unicode-org#7764)</li>
<li>New methods: <code>Date::try_new</code> (and primarily-internal
<code>Calendar::new_date</code>)</li>
<li>New types: <code>InputYear</code>, <code>DateNewError</code></li>
<li>Handle possible <code>Overflow</code> values on individual calendars
(unicode-org#7795)</li>
<li>New <code>Date::try_from_fields</code> API for fully general date
construction from various choices of year and month values
(unicode-org#7798)</li>
<li>New methods: <code>Date::try_from_fields()</code></li>
<li>New types: <code>DateFields</code>,
<code>DateFromFieldsOptions</code>, <code>Overflow</code>,
<code>MissingFieldsStrategy</code>,
<code>DateFromFieldsError</code></li>
<li>New associated method: <code>Calendar::from_fields()</code></li>
<li>New Date arithmetic APIs for adding and subtracting dates
(unicode-org#7798, unicode-org#7355, unicode-org#7257)</li>
<li>New methods: <code>Date::try_add_with_options</code>,
<code>Date::try_added_with_options</code>,
<code>Date::try_until_with_options</code></li>
<li>New types: <code>DateDuration</code>, <code>DateAddOptions</code>,
<code>DateDifferenceOptions</code>, <code>DateDurationUnit</code>,
<code>DateDurationParseError</code>, <code>DateAddError</code>,
<code>MismatchedCalendarError</code></li>
<li>New associated items: <code>Calendar::add</code>,
<code>Calendar::until</code>,
<code>Calendar::DateCompatibilityError</code></li>
<li>Introduce a new <code>Month</code> type, preferred over using month
codes (unicode-org#7147, unicode-org#7756)
<ul>
<li>New type: <code>Month</code></li>
<li>New method: <code>MonthInfo::to_input()</code></li>
</ul>
</li>
<li>Introduce year/date ranges to all APIs, documented on the APIs
themselves. <code>Date</code> now has a fundamental range (ISO years
between ±999,999), and most constructors enforce a stricter range of
±9999 years for input years. (unicode-org#7676, unicode-org#7062,
unicode-org#7629, unicode-org#7753, unicode-org#7219,
unicode-org#7227)</li>
<li>Add constructors with <code>Month</code> for lunisolar calendars
(unicode-org#7485)</li>
<li>New methods: <code>Date::try_new_korean_traditional()</code>,
<code>Date::try_new_chinese_traditional()</code>,
<code>Date::try_new_hebrew_v2()</code></li>
<li>Expose <code>LeapStatus</code> on <code>MonthInfo</code>
(unicode-org#7667)</li>
<li>New method: <code>MonthInfo::leap_status()</code></li>
<li>New enum: <code>LeapStatus</code></li>
<li>(Unstable) Integrate with <code>chrono</code>, <code>jiff</code>,
and <code>time</code> (unicode-org#7617, unicode-org#7711)</li>
<li>New impls: <code>From&lt;chrono::NaiveDate&gt;</code>,
<code>From&lt;jiff::civil::Date&gt;</code>,
<code>From&lt;time::Date&gt;</code> for
<code>Date&lt;Gregorian&gt;</code></li>
<li>Replace <code>Date::day_of_week</code> by <code>Date::weekday</code>
(unicode-org#7288)
<ul>
<li>New method: <code>Date::weekday()</code></li>
</ul>
</li>
<li>Deprecate <code>Date::new_from_iso</code>/<code>Date::to_iso</code>
(unicode-org#7287)</li>
<li>Deprecate <code>Date::extended_year()</code> (use
<code>Date::year().extended_year()</code>) (unicode-org#7289)</li>
<li>Remove <code>YearInfo: PartialEq</code> bound
(unicode-org#7743)</li>
<li>Start producing Meiji era only after Meiji 6 (unicode-org#7503)</li>
</ul>
</li>
</ul>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/unicode-org/icu4x/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zerofrom-derive&package-manager=cargo&previous-version=0.1.6&new-version=0.1.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-09 00:37:01 +00:00
dependabot[bot]
ceb8cf07c1 build: bump cryptography from 46.0.6 to 46.0.7 (#44045)
Bumps [cryptography](https://github.com/pyca/cryptography) from 46.0.6
to 46.0.7.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst">cryptography's
changelog</a>.</em></p>
<blockquote>
<p>46.0.7 - 2026-04-07</p>
<pre><code>
* **SECURITY ISSUE**: Fixed an issue where non-contiguous buffers could
be
  passed to APIs that accept Python buffers, which could lead to buffer
  overflow. **CVE-2026-39892**
* Updated Windows, macOS, and Linux wheels to be compiled with OpenSSL
3.5.6.
<p>.. _v46-0-6:<br />
</code></pre></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="622d672e42"><code>622d672</code></a>
46.0.7 release (<a
href="https://redirect.github.com/pyca/cryptography/issues/14602">#14602</a>)</li>
<li>See full diff in <a
href="https://github.com/pyca/cryptography/compare/46.0.6...46.0.7">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cryptography&package-manager=uv&previous-version=46.0.6&new-version=46.0.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 22:40:19 +00:00
Martin Robinson
b8ef264268 layout: Integrate more details into FontAndScriptInfo (#43974)
This will be needed for ensuring that shaped text is valid during
relayout. It duplicates some information, but the hope is that when all
of these change are done, there will be many fewer individual shaped
segments of text.

Testing: This should not really change observable behavior so is covered
by existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-08 21:37:44 +00:00
Tim van der Lippe
eca6eb2b4e script: Further implement fontsize command (#44030)
While debugging test failures, I discovered that I had reversed the
`is_allowed_child` arguments. That made a bunch more tests pass, but
then also started to fail tests as we weren't clearing the previous
value and computing loose equivalence.

Therefore, this PR fixes the reversal and implements the relevant parts
of some algorithms as to not regress too much. There are two new
failures related to how integers should be parsed, but tackling that
separately.

Part of #25005

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-08 18:51:48 +00:00
Jonathan Schwender
516dba791f allocator: Add libc Heap information on macos (#44037)
Despite using `jemalloc` by default on macos as the Rust global
allocator, the default system allocator will still be used by some C/C++
libraries.
Using `malloc_zone_statistics` on macos allows us to get information
about the system allocator heap usage.
Since the macos statistic also provides information about reserved, but
currently unused memory, we also expose that and attempt to calculate
the same metric on Linux, which should be
arena (Non-mmapped space allocated (bytes)) + hblkhd (Space allocated in
mmapped regions (bytes)) See
https://man7.org/linux/man-pages/man3/mallinfo.3.html

Loading `servo.org` in a debug build on macOS and then navigating to
about:memory, I see 31MB system-heap-allocated and 92 MB
system-heap-reserved.

Testing: Manually tested on macOS. Not tested on Linux.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-08 18:23:49 +00:00
CynthiaOketch
1174dfe3d2 script: Remove pointless import renames in components/script/dom/request.rs (#44025)
CacheMode, CredentialsMode, Destination, RedirectMode, and Referrer were
imported with NetTraitsRequest* aliases to avoid naming conflicts. These
conflicts no longer exist; their original names do not clash with any
other imports or types in this file, so the aliases are restored.

Testing: Pure refactor with no behavior change. Ran `./mach try
linux-unit-tests` to verify existing tests continue to pass.
Fixes: #42981

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-04-08 17:26:51 +00:00
Simon Wülker
695b8ee913 script: Claim blob before loading <video> poster frame (#44035)
Refer to https://github.com/servo/servo/pull/43746 for a description of
the problem. This change ensures that video posters can be loaded from
blob URLs, even if the URL is revoked right after.

Testing: This change adds a test

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-08 17:03:56 +00:00
atbrakhi
e50cfa7af6 devtools: Fix recursion in debugger (#44024)
Fix recursion causing panic in debugger

Testing: Current tests are passing, also manual testing 
Fixes: part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-08 15:29:20 +00:00
Taym Haddadi
78c9fe2a4c IndexedDB: Align IndexedDB binary key conversion with the spec (#44009)
IndexedDB: Align IndexedDB binary key conversion with the spec

Testing: covered by WPT test.

part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-08 10:26:52 +00:00
Freya Arbjerg
adde320fb0 paint: Add minimum size checks for RenderingContext (#44011)
Returns an error on `RenderingContext` constructors when size is 0 in
either dimension. Also adds panics to resize functions in the same case.

Testing: Added a unit test for the new error on
`SoftwareRenderingContext::new()`.
Fixes: https://github.com/servo/servo/issues/36061

Signed-off-by: Freya Arbjerg <git@arbjerg.dev>
Co-authored-by: Martin Robinson <martin@abandonedwig.info>
2026-04-08 10:18:21 +00:00
TIN TUN AUNG
280d984d3b media: Implement Player for ohos backend (#43208)
Implement Player Trait in ohos backend using Harmony OS MediaKit's[
AVPlayer](https://developer.huawei.com/consumer/en/doc/harmonyos-references/capi-avplayer-h).

The modular design of `VideoSink`, `InnerPlayer`, and `MediaSource` is
taken from the GStreamer backend.
Only support HarmonyOS SDK API 21, because the
`OH_AVPlayer_SetDataSource` only started to be exposed on API 21.

Testing: N/A, as there are no platform specific task.
Fixes: N/A, now we can play video on HarmonyOS phone using `<video>`

---------

Signed-off-by: rayguo17 <rayguo17@gmail.com>
2026-04-08 08:48:10 +00:00
Simon Wülker
1b336760ae mozjs: Rebuild from source if jitspew feature is enabled (#44010)
The `IONFLAGS` environment variable configure logging for the JIT, but
it must be enabled in spidermonkey at compile time. The prebuilt mozjs
binaries don't enable it, so we must build from source.

Companion PR for https://github.com/servo/mozjs/pull/728

Testing: We don't have tests for the build process

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-08 08:40:07 +00:00
Euclid Ye
712b4f9bc2 script: Reduce ShadowRoot::bind_to_tree complexity from O(2^N) to O(N) (#44016)
During traversal, exclude shadow roots.

Analysis:
Each shadow root is processed twice:
- via host: Element::bind_to_tree()
-  Via iterator

In total, this would be
```math
\sum_{i=0}^{N-1} 2^i = 2^N - 1
```

Testing: Added a test.
Fixes: https://github.com/servo/servo/issues/43998

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
Co-authored-by: webbeef <me@webbeef.org>
2026-04-08 08:20:20 +00:00
Jonathan Schwender
0ea14d1b60 release: Fix result check for cancelled workflows (#44017)
If the entire workflow was cancelled we also need to check for
`cancelled()`. Simply checking needs.*.result is not sufficient - it was
observed that the success branch was still entered when only checking
needs.

Testing: Tested manually, by cancelling [this
workflow](https://github.com/servo/servo/actions/runs/24119740924/job/70371050119)
which resulted in a draft release publish (failure branch)

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Mukilan Thiyagarajan <mukilanthiagarajan@gmail.com>
2026-04-08 05:58:58 +00:00
Bennet Bleßmann
cff186777c devtools: remove impl JsonPacketStream for TcpStream (#44006)
Removes the `impl JsonPacketStream for TcpStream` that was supposed to
be removed as part of servo/servo#43472

> Testing: [..] Removing the JsonPacketStream implementation for
TcpStream should discourage regressions due to improper use of raw
streams.

Confirmed in
https://github.com/servo/servo/pull/43472#issuecomment-4201684071

Testing: no new test needed as this only removes code

Signed-off-by: Bennet Bleßmann <bennet.blessmann+github@googlemail.com>
2026-04-08 01:09:46 +00:00
rovertrack
ba4f031f86 script: Pass &CStr to get_callable_property (#44008)
Fixes: #43968 
made get callable property accept ` &CStr ` instead of `&str`

Testing: no behaviour change expected, so existing WPT tests are
sufficient.

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-08 00:56:47 +00:00
dependabot[bot]
b561212988 build: bump async-signal from 0.2.13 to 0.2.14 (#44015)
Bumps [async-signal](https://github.com/smol-rs/async-signal) from
0.2.13 to 0.2.14.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/async-signal/releases">async-signal's
releases</a>.</em></p>
<blockquote>
<h2>v0.2.14</h2>
<ul>
<li>Fix build error on haiku. (<a
href="https://redirect.github.com/smol-rs/async-signal/issues/59">#59</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/async-signal/blob/master/CHANGELOG.md">async-signal's
changelog</a>.</em></p>
<blockquote>
<h1>Version 0.2.14</h1>
<ul>
<li>Fix build error on haiku. (<a
href="https://redirect.github.com/smol-rs/async-signal/issues/59">#59</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d750e57adc"><code>d750e57</code></a>
Release 0.2.14</li>
<li><a
href="eb72cfd64a"><code>eb72cfd</code></a>
Fix build error on haiku</li>
<li><a
href="1ffadd3db8"><code>1ffadd3</code></a>
Update signal-hook requirement from 0.3.14 to 0.4.1 (<a
href="https://redirect.github.com/smol-rs/async-signal/issues/57">#57</a>)</li>
<li><a
href="a43dca7fd1"><code>a43dca7</code></a>
Fix clippy::io_other_error warning</li>
<li><a
href="c00258a4a6"><code>c00258a</code></a>
Bump MSRV to 1.85</li>
<li><a
href="3fdfdee177"><code>3fdfdee</code></a>
ci: Use taiki-e/checkout-action action</li>
<li><a
href="0f8053d9af"><code>0f8053d</code></a>
ci: Use cargo-hack's --rust-version flag for msrv check</li>
<li>See full diff in <a
href="https://github.com/smol-rs/async-signal/compare/v0.2.13...v0.2.14">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=async-signal&package-manager=cargo&previous-version=0.2.13&new-version=0.2.14)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 00:52:05 +00:00
dependabot[bot]
0941407c8f build: bump fastrand from 2.3.0 to 2.4.1 (#44013)
Bumps [fastrand](https://github.com/smol-rs/fastrand) from 2.3.0 to
2.4.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/fastrand/releases">fastrand's
releases</a>.</em></p>
<blockquote>
<h2>v2.4.1</h2>
<ul>
<li>Fix build failure with <code>js</code> feature. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/125">#125</a>)</li>
</ul>
<h2>v2.4.0</h2>
<ul>
<li>Bump MSRV to 1.63. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/104">#104</a>)</li>
<li>Improve quality of f32/f64 generation. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/103">#103</a>)</li>
<li>Add <code>f{32,64}_inclusive</code> and
<code>Rng::f{32,64}_inclusive</code>. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/103">#103</a>)</li>
<li>Make <code>Rng::with_seed</code> const. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/107">#107</a>)</li>
<li>Update <code>getrandom</code> to 0.3. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/104">#104</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/fastrand/blob/master/CHANGELOG.md">fastrand's
changelog</a>.</em></p>
<blockquote>
<h1>Version 2.4.1</h1>
<ul>
<li>Fix build failure with <code>js</code> feature. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/125">#125</a>)</li>
</ul>
<h1>Version 2.4.0</h1>
<ul>
<li>Bump MSRV to 1.63. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/104">#104</a>)</li>
<li>Improve quality of f32/f64 generation. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/103">#103</a>)</li>
<li>Add <code>f{32,64}_inclusive</code> and
<code>Rng::f{32,64}_inclusive</code>. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/103">#103</a>)</li>
<li>Make <code>Rng::with_seed</code> const. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/107">#107</a>)</li>
<li>Update <code>getrandom</code> to 0.3. (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/104">#104</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="728a5b503f"><code>728a5b5</code></a>
Release 2.4.1</li>
<li><a
href="0c619f6a39"><code>0c619f6</code></a>
Fix build failure with js feature</li>
<li><a
href="a4077e2373"><code>a4077e2</code></a>
ci: Add missing js feature test</li>
<li><a
href="1fd5bbb300"><code>1fd5bbb</code></a>
Release 2.4.0 (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/116">#116</a>)</li>
<li><a
href="074345b7e7"><code>074345b</code></a>
chore: make some documents clearer (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/115">#115</a>)</li>
<li><a
href="ce9a48c2ee"><code>ce9a48c</code></a>
chore: update dependencies to latest versions and bump MSRV to 1.63 (<a
href="https://redirect.github.com/smol-rs/fastrand/issues/104">#104</a>)</li>
<li><a
href="978dde1cad"><code>978dde1</code></a>
ci: Use reusable workflows for clippy</li>
<li><a
href="8561f13c21"><code>8561f13</code></a>
bench: Add benchmark of f32()</li>
<li><a
href="1def02cb23"><code>1def02c</code></a>
Fix rustdoc::broken_intra_doc_links warning</li>
<li><a
href="c2cbdd4965"><code>c2cbdd4</code></a>
Remove manual doc(cfg(..))</li>
<li>Additional commits viewable in <a
href="https://github.com/smol-rs/fastrand/compare/v2.3.0...v2.4.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=fastrand&package-manager=cargo&previous-version=2.3.0&new-version=2.4.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-08 00:41:56 +00:00
Taym Haddadi
ac4df79bd6 Make localStorage and sessionStorage throw on opaque origins (#44002)
Testing: covered by WPT test.
Fixes #43999

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-07 20:41:10 +00:00
Josh Matthews
9334d3094b script: Use the global's origin when claiming blob tokens. (#44004)
`global.api_base_url().origin()` returns a unique opaque origin when the
base URL is an opaque origin. When we use the global's origin instead,
requests for claimed blobs can now pass the same-origin check.

Testing: Newly passing tests.
Fixes: #43326
Fixes: #43973

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-07 19:40:15 +00:00
Kelechi Ebiri
a7e4b80b31 script: Support sprintf-style substitutions in console methods (#43897)
Implement the Console Formatter operation for all console methods.
Fixes: #43827

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-07 18:55:36 +00:00
Abbas Olanrewaju Sarafa
66d232e1e7 Remove introduction_type_override field from HTMLScriptElement (#44003)
Removed ```introduction_type_override``` field from
```HTMLScriptElement``` & passed the new variable to
```fetch_inline_module_script```

Testing: No testing required, compiles successfully.
Fixes: #43980

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-07 18:36:21 +00:00
Simon Wülker
37a1f93b91 url: Let origins of file:// URLs be potentially trustworthy (#43989)
The origin of a `file` URL is unspecified. Engines act like they're
opaque except in a few special cases - one of which is the "is
potentially trustworthy" algorithm. This change allows consumers of
`servo-url` to distinguish between regular opaque origins and file
origins. Then we use that to mark file origins as "potentially
trustworthy" which is what the spec wants.

For now we can get away without changes to the `url` crate (the one used
in the wider ecosystem, not just servo), but I'm unsure if that will be
the case in the future.

Testing: This change adds a test
Fixes: https://github.com/servo/servo/issues/42540

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-07 18:29:30 +00:00
Alex Feyerke
f977c06f9d Modernize and improve the Android UI (#43795)
Modernize and improve the Android UI, and add browsing history panel.

---------

Signed-off-by: Alex Feyerke <alex@neighbourhood.ie>
2026-04-07 16:39:19 +00:00
Euclid Ye
8b1619ba1d script/net: Make URL List closer to spec (#43987)
[Redirected](https://fetch.spec.whatwg.org/#dom-response-redirected)
should be decided by the URL List.
Currently it does not. We add some TODO, fill URL in more places
according to spec.

Testing: This should not change behaviour, as URL list is mostly used by
[Redirected](https://fetch.spec.whatwg.org/#dom-response-redirected). If
we do it now, we get test failures as URL list is not fully set in all
spec steps.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-07 14:55:40 +00:00
Oriol Brufau
0615c394b9 stylo: Enable multiple color arguments in color-mix() (#43890)
Bumps Stylo to https://github.com/servo/stylo/pull/348

Testing: 2 WPT improve

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-04-07 14:08:50 +00:00
Narfinger
3612ba9e5b OHOS CI: Fix parsefromstring (#42995)
ParseFromString currently complains that it matches multiple trace
lines. The reason for that is a bit unclear as it should only produce
one alert. Local testing shows that it produces multiple (even for one
run). This should at least give us the metric back.

Testing: This is currently untested. As it is a small CI change that
can't break a broken test it should be fine.
Fixes: https://github.com/servo/servo/issues/42992

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-07 13:48:17 +00:00
Abubakar Abdulazeez Usman
750fb41bdb devtools: Include layer rules in CSS panel using rule tree (#43912)
DevTools was collecting CSS rules by walking stylesheets and matching
selector text. This ignored cascade order and did not correctly handle
rules inside layer blocks.

This change uses computed values (rule tree) to get the actual applied
rules in cascade order. It then maps those rules back to CSSStyleRule
using the declaration block identity, and walks the CSSOM to get
selector text and layer ancestry.

This fills ancestor_data with layer names and lets the inspector show
layered rules correctly.


Testing: 
- Verified using the minimized testcase from the issue

- Verified on https://www.sharyap.com/

- Confirmed that rules inside layer blocks are now shown with correct
order and hierarchy.


Fixes: #43541

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-04-07 11:26:12 +00:00
Simon Wülker
57adfc136f script: Remove FIXME about deprecated performance.timing (#43996)
`performance.timing` is not going anywhere anytime soon. Deprecating it
is none of servo's concern. The spec links are also outdated.

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-07 11:16:35 +00:00
eri
4f13fcc38d devtools: Pass steppingType to onPop hook (#43995)
Fixes crashes when stepping in certain situations.

Testing: Ran `mach test-devtools` and manual testing
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-07 09:57:20 +00:00
Messi II Innocent R.
88a08d775c Don't crash if rustup is not installed (#43982)
Check if rustup is available before calling it. 

If it is not found, skip the step with a warning instead of crashing.
This allows users who installed Rust through their distribution's
package manager (without rustup) to build Servo without errors.

Three places were updated:

- In command_base.py I added a skip automatic target installation for
cross-compilation
- In base.py, I added the skip toolchain installation
- In, bootstrap_commands.py , it is a skip clean-nightlies if rustup not
found

Fixes: #43871

Signed-off-by: Messi002 <rostandmessi2@gmail.com>
2026-04-07 09:42:55 +00:00
Narfinger
8a38c5e217 servoshell: Port from sig to signal_hook_registry (#43891)
Testing: We do not currently have a way to test signal handling in the
servoshell binary, so this change does not include tests.
Fixes: #43836

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-07 08:28:36 +00:00
atbrakhi
7a559ba459 devtools: Fix worker targets in debugger tab (#43981)
Firefox DevTools client determines target type by checking if the actor
contains specific substring. For workers it
[requires](https://searchfox.org/firefox-main/source/devtools/client/fronts/watcher.js#65)
`/workerTarget` in the actor name to create a `WorkerTargetFront`.

Testing: Manual testing
Fixes: #36727


<img width="1084" height="558" alt="Screenshot 2026-04-06 at 21 47 59"
src="https://github.com/user-attachments/assets/207a8368-0f8a-48a6-ab7e-a5ee3750381f"
/>

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-04-07 07:49:43 +00:00
dependabot[bot]
793f0c8ec8 build: bump zerofrom from 0.1.6 to 0.1.7 (#43986)
Bumps [zerofrom](https://github.com/unicode-org/icu4x) from 0.1.6 to
0.1.7.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/unicode-org/icu4x/blob/main/CHANGELOG.md">zerofrom's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h2>icu 2.2.x</h2>
<p>Several crates have had patch releases in the 2.2 stream:</p>
<ul>
<li>Components
<ul>
<li>(2.2.1) <code>icu_calendar</code>
<ul>
<li>Fix extended year calculations in Gregorian-like and Coptic-like
calendars (unicode-org#7849)</li>
</ul>
</li>
</ul>
</li>
</ul>
<h2>icu4x 2.2</h2>
<ul>
<li>Components
<ul>
<li>General
<ul>
<li>Use HTTPS links in docs (unicode-org#7212)</li>
<li>Update MSRV to 1.86 (unicode-org#7576)</li>
<li>Updated to CLDR 48.2 (unicode-org#7792)</li>
<li>Replace <code>experimental</code> features with
<code>unstable</code> features (unicode-org#7566)</li>
<li>Add categories and keywords to Cargo.toml for all components
(unicode-org#7737)</li>
</ul>
</li>
<li><code>icu_calendar</code>
<ul>
<li>Add <code>Date::try_new</code>, which replaces
<code>Date::try_new_from_codes</code>, and takes typed year/month
values. (unicode-org#7773, unicode-org#7764)</li>
<li>New methods: <code>Date::try_new</code> (and primarily-internal
<code>Calendar::new_date</code>)</li>
<li>New types: <code>InputYear</code>, <code>DateNewError</code></li>
<li>Handle possible <code>Overflow</code> values on individual calendars
(unicode-org#7795)</li>
<li>New <code>Date::try_from_fields</code> API for fully general date
construction from various choices of year and month values
(unicode-org#7798)</li>
<li>New methods: <code>Date::try_from_fields()</code></li>
<li>New types: <code>DateFields</code>,
<code>DateFromFieldsOptions</code>, <code>Overflow</code>,
<code>MissingFieldsStrategy</code>,
<code>DateFromFieldsError</code></li>
<li>New associated method: <code>Calendar::from_fields()</code></li>
<li>New Date arithmetic APIs for adding and subtracting dates
(unicode-org#7798, unicode-org#7355, unicode-org#7257)</li>
<li>New methods: <code>Date::try_add_with_options</code>,
<code>Date::try_added_with_options</code>,
<code>Date::try_until_with_options</code></li>
<li>New types: <code>DateDuration</code>, <code>DateAddOptions</code>,
<code>DateDifferenceOptions</code>, <code>DateDurationUnit</code>,
<code>DateDurationParseError</code>, <code>DateAddError</code>,
<code>MismatchedCalendarError</code></li>
<li>New associated items: <code>Calendar::add</code>,
<code>Calendar::until</code>,
<code>Calendar::DateCompatibilityError</code></li>
<li>Introduce a new <code>Month</code> type, preferred over using month
codes (unicode-org#7147, unicode-org#7756)
<ul>
<li>New type: <code>Month</code></li>
<li>New method: <code>MonthInfo::to_input()</code></li>
</ul>
</li>
<li>Introduce year/date ranges to all APIs, documented on the APIs
themselves. <code>Date</code> now has a fundamental range (ISO years
between ±999,999), and most constructors enforce a stricter range of
±9999 years for input years. (unicode-org#7676, unicode-org#7062,
unicode-org#7629, unicode-org#7753, unicode-org#7219,
unicode-org#7227)</li>
<li>Add constructors with <code>Month</code> for lunisolar calendars
(unicode-org#7485)</li>
<li>New methods: <code>Date::try_new_korean_traditional()</code>,
<code>Date::try_new_chinese_traditional()</code>,
<code>Date::try_new_hebrew_v2()</code></li>
<li>Expose <code>LeapStatus</code> on <code>MonthInfo</code>
(unicode-org#7667)</li>
<li>New method: <code>MonthInfo::leap_status()</code></li>
<li>New enum: <code>LeapStatus</code></li>
<li>(Unstable) Integrate with <code>chrono</code>, <code>jiff</code>,
and <code>time</code> (unicode-org#7617, unicode-org#7711)</li>
<li>New impls: <code>From&lt;chrono::NaiveDate&gt;</code>,
<code>From&lt;jiff::civil::Date&gt;</code>,
<code>From&lt;time::Date&gt;</code> for
<code>Date&lt;Gregorian&gt;</code></li>
<li>Replace <code>Date::day_of_week</code> by <code>Date::weekday</code>
(unicode-org#7288)
<ul>
<li>New method: <code>Date::weekday()</code></li>
</ul>
</li>
<li>Deprecate <code>Date::new_from_iso</code>/<code>Date::to_iso</code>
(unicode-org#7287)</li>
<li>Deprecate <code>Date::extended_year()</code> (use
<code>Date::year().extended_year()</code>) (unicode-org#7289)</li>
<li>Remove <code>YearInfo: PartialEq</code> bound
(unicode-org#7743)</li>
<li>Start producing Meiji era only after Meiji 6 (unicode-org#7503)</li>
</ul>
</li>
</ul>
</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/unicode-org/icu4x/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zerofrom&package-manager=cargo&previous-version=0.1.6&new-version=0.1.7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 01:00:46 +00:00
dependabot[bot]
d596c5dc9e build: bump cc from 1.2.58 to 1.2.59 (#43985)
Bumps [cc](https://github.com/rust-lang/cc-rs) from 1.2.58 to 1.2.59.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/releases">cc's
releases</a>.</em></p>
<blockquote>
<h2>cc-v1.2.59</h2>
<h3>Fixed</h3>
<ul>
<li><em>(ar)</em> deterministic archives with <code>D</code> modifier
(<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1697">#1697</a>)</li>
</ul>
<h3>Other</h3>
<ul>
<li>Regenerate target info (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1698">#1698</a>)</li>
<li>Fix target abi parsing for sanitiser targets (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1695">#1695</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md">cc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.58...cc-v1.2.59">1.2.59</a>
- 2026-04-03</h2>
<h3>Fixed</h3>
<ul>
<li><em>(ar)</em> deterministic archives with <code>D</code> modifier
(<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1697">#1697</a>)</li>
</ul>
<h3>Other</h3>
<ul>
<li>Regenerate target info (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1698">#1698</a>)</li>
<li>Fix target abi parsing for sanitiser targets (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1695">#1695</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f4c5ac7a7e"><code>f4c5ac7</code></a>
chore(cc): release v1.2.59 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1699">#1699</a>)</li>
<li><a
href="9cfcecbb9d"><code>9cfcecb</code></a>
Regenerate target info (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1698">#1698</a>)</li>
<li><a
href="025d046f99"><code>025d046</code></a>
fix(ar): deterministic archives with <code>D</code> modifier (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1697">#1697</a>)</li>
<li><a
href="fe32d6834a"><code>fe32d68</code></a>
Fix target abi parsing dor sanitiser targets (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1695">#1695</a>)</li>
<li>See full diff in <a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.58...cc-v1.2.59">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cc&package-manager=cargo&previous-version=1.2.58&new-version=1.2.59)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-07 00:54:38 +00:00
Simon Wülker
0ddc7a08d0 script: Lock blob URL entry during XHR open() (#43977)
This is a followup to https://github.com/servo/servo/pull/43746 that
applies the same fix to XHR. Refer to that PR for a description of the
problem.

Testing: New tests start to pass

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-06 19:46:52 +00:00
Babalola Taiwo J
6279f7bdef devtools: Rename ThreadActor variable names (#43955)
Renames local variables holding a `ThreadActor` instance to
`thread_actor`, following the `{}_actor` convention for actor variables
as described in #43606.

Changes:
- `actors/thread.rs`: `actor` → `thread_actor` in
`ThreadActor::register()`
- `lib.rs`: `thread` → `thread_actor` in
`handle_notifyscriptinterrupted` and `handle_create_frame_actor`

Part of #43606.

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
Signed-off-by: eri <eri@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-06 19:42:05 +00:00
Abbas Olanrewaju Sarafa
02a350d864 layout: Rename confusing ``SequentialLayoutState::collapse_margins`` (#43978)
Renamed ```SequentialLayoutState::collapse_margins``` to
```commit_margin``` in ```float.rs```, ```mod.rs``` &
```inline/mod.rs```

Testing: No testing required - just renaming. Compiles successfully.
Fixes: #43941

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 19:10:28 +00:00
Babalola Taiwo J
f38de75888 devtools: Rename SourceActor variable names (#43959)
Renames local variable holding a `SourceActor` instance to
`source_actor`, following the `{}_actor` convention for actor variables
as described in #43606.

Changes:
- `actors/source.rs`: `actor` → `source_actor` in
`SourceActor::register()`

Part of #43606.

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-04-06 16:01:26 +00:00
Babalola Taiwo J
a7870df4c7 devtools: Rename WorkerActor variables and add register method (#43963)
Renames local variable `worker` to `worker_actor` in `lib.rs` and
`root.rs`, following the `{}_actor` convention for actor struct
variables and `{}_name` for actor name string variables established in
#43606.

Also adds a `WorkerActor::register()` method (part of #43800), replacing
the inline struct construction in `lib.rs` with a consistent pattern
pattern matching other actors like `ThreadActor` and `SourceActor`.

**Changes:**
- `actors/worker.rs`: Add `WorkerActor::register()` method
- `actors/root.rs`: Rename `worker` → `worker_actor` in
`listServiceWorkerRegistrations` handler
- `lib.rs`: Replace inline struct construction with
`WorkerActor::register()` call

**Testing:** No testing required, compiles successfully.

Fixes: Part of #43606
Fixes: Part of #43800

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-04-06 15:37:58 +00:00
Jonathan Schwender
d21fc8238a profile: Add debug_span and minor refactoring (#43971)
Add an internal macro to avoid duplication, and use that to implement
the existing two `trace` and `info` macros and add `debug_span`. We skip
`warn` and `error` (from the tracing-rs library), since those names
don't fit our profiling usage too well, and 3 different levels should
also be enough. If we need more levels in the future we could still add
more macros than (after deciding on better names than warn and error)

Testing: Servo is built with the tracing feature in CI (for HarmonyOS)

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-06 15:22:49 +00:00
Simon Wülker
e73c010bb1 Force callers to claim blob url before making a fetch request (#43746)
`blob` URLs have a implicit blob URL entry attached, which stores the
data contained in the blob. The specification requires this entry to be
resolved as the URL is parsed. We only resolve it inside `net` when
loading the URL. That causes problems if the blob entry has been revoked
in the meantime - see https://github.com/servo/servo/issues/25226.

Ideally we would want to resolve blobs at parse-time as required. But
because `ServoUrl` is such a fundamental type, I've not managed to do
this change without having to touch hundreds of files at once.

Thus, we now require passing a `UrlWithBlobClaim` instead of a
`ServoUrl` when `fetch`-ing. This type proves that the caller has
acquired the blob beforehand.

As a temporary escape hatch, I've added
`UrlWithBlobClaim::from_url_without_having_claimed_blob`. That method
logs a warning if its used unsafely. This method is currently used in
most places to keep this change small. Only workers now acquire the blob
beforehand.

Testing: A new test starts to pass
Part of https://github.com/servo/servo/issues/43326
Part of https://github.com/servo/servo/issues/25226

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-04-06 14:21:55 +00:00
Tim van der Lippe
324fed274a script: Pass &mut JSContext to Clipboard API's (#43975)
Part of #40600
Follow-up to #43943

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-06 13:47:17 +00:00
Tim van der Lippe
cac1a7f0fc script: Add basic implementation of font-size command (#43287)
This makes the most basic tests pass for the font-size command. Future
PR's will continue the work,
but since this is already large enough, this is a good save point.

Part of #25005

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-06 13:23:36 +00:00
Euclid Ye
cb2dd62e62 net: Improve HTTP fetch compliance (#43970)
Most notably, implement step 5 and removes the incorrect place for it.
Part of follow up to #43798

Testing:
[Try](https://github.com/yezhizhen/servo/actions/runs/24021988217/job/70054752138)

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-06 12:28:52 +00:00
Abbas Olanrewaju Sarafa
3d0cfe34bb storage: Make add_new_environment return a Result instead of panicking (#43949)
Removed the ```.unwrap()``` in ```add_new_environment``` causing the
storage thread to panic on SQLite failures

Testing: Ran ```./mach test-wpt tests/wpt/tests/webstorage/```
Result; 
```
▶ TIMEOUT [expected OK] /webstorage/storage_local_setitem_quotaexceedederr.window.html

Ran 53 tests finished in 63.9 seconds.
  • 52 ran as expected.
  • 1 tests timed out unexpectedly
```
Fixes: #43880

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 12:25:52 +00:00
Martin Robinson
82c2f1434e fonts: Clean up application of word-spacing (#43899)
Let `word_spacing` be optional in `ShapingOptions` like
`letter_spacing`. In addition, send `None` for Canvas rendering instead
of the width of the space character. It is supposed to represent *extra*
space added between words. Finally, remove duplicated code that applied
word and letter spacing for the fast shaper. This can just reuse the
code from the Harfbuzz shaper.

Testing: This causes some canvas tests to start passing.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-06 09:20:34 +00:00
Taym Haddadi
12ab179b05 IndexedDB: Fix object-store key range handling (#43901)
Fix object-store key range handling

Testing: key range handling wpt test fixed.
Fixes: part of #40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-06 09:15:27 +00:00
Abbas Olanrewaju Sarafa
00aa8c0e85 devtools: Replace new with register for LayoutInspectorActor (#43954)
Replaced new with register for LayoutInspectorActor in walker.rs &
layout.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 09:13:33 +00:00
Abbas Olanrewaju Sarafa
c938e97b3c devtools: Replace new with register for TargetConfigurationActor (#43915)
Replaced new with register for TargetConfigurationActor in
target_configuration.rs & watcher.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 09:12:17 +00:00
elomscansio
a7bc4a6fa9 script: implement render-blocking option for script fetch and load events (#43741)
Implement render-blocking option for script fetch and load events

## Testing: 
### Test summary on main branch
```bash
  ▶ OK [expected CRASH] /html/semantics/scripting-1/the-script-element/moving-between-documents/move-back-createHTMLDocument-success-external-module.html

Ran 470 tests finished in 217.9 seconds.
  • 453 ran as expected.
  • 4 tests crashed unexpectedly
  • 1 tests timed out unexpectedly
  • 11 tests unexpectedly okay
  • 2 tests had unexpected subtest results

/home/elomscansio/.local/share/uv/python/cpython-3.11.15-linux-x86_64-gnu/lib/python3.11/multiprocessing/resource_tracker.py:254: UserWarning: resource_tracker: There appear to be 3 leaked semaphore objects to clean up at shutdown
  warnings.warn('resource_tracker: There appear to be %d '

```

### Test summary for this commits
```bash

Ran 470 tests finished in 488.0 seconds.
  • 397 ran as expected.
  • 15 tests crashed unexpectedly
  • 27 tests timed out unexpectedly
  • 11 tests unexpectedly okay
  • 28 tests had unexpected subtest results

```
Fixes: #43697
Fixes: #43354

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
Signed-off-by: elomscansio <163124154+elomscansio@users.noreply.github.com>
Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
Co-authored-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-04-06 08:08:43 +00:00
Abbas Olanrewaju Sarafa
414a97c2e3 devtools: Replace new with register for AccessibleWalkerActor (#43967)
Replaced new with register for AccessibleWalkerActor in accessibility.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 07:26:54 +00:00
dependabot[bot]
5184707255 build: bump tokio from 1.50.0 to 1.51.0 in the tokio-rs-related group across 1 directory (#43960)
Bumps the tokio-rs-related group with 1 update in the / directory:
[tokio](https://github.com/tokio-rs/tokio).

Updates `tokio` from 1.50.0 to 1.51.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tokio/releases">tokio's
releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.51.0</h2>
<h1>1.51.0 (April 3rd, 2026)</h1>
<h3>Added</h3>
<ul>
<li>net: implement <code>get_peer_cred</code> on Hurd (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7989">#7989</a>)</li>
<li>runtime: add <code>tokio::runtime::worker_index()</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7921">#7921</a>)</li>
<li>runtime: add runtime name (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7924">#7924</a>)</li>
<li>runtime: stabilize <code>LocalRuntime</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7557">#7557</a>)</li>
<li>wasm: add wasm32-wasip2 networking support (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7933">#7933</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li>runtime: steal tasks from the LIFO slot (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7431">#7431</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>docs: do not show &quot;Available on non-loom only.&quot; doc label
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7977">#7977</a>)</li>
<li>macros: improve overall macro hygiene (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7997">#7997</a>)</li>
<li>sync: fix <code>notify_waiters</code> priority in
<code>Notify</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7996">#7996</a>)</li>
<li>sync: fix panic in <code>Chan::recv_many</code> when called with
non-empty vector on closed channel (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7991">#7991</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/tokio-rs/tokio/issues/7431">#7431</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7431">tokio-rs/tokio#7431</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7557">#7557</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7557">tokio-rs/tokio#7557</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7921">#7921</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7921">tokio-rs/tokio#7921</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7924">#7924</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7924">tokio-rs/tokio#7924</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7933">#7933</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7933">tokio-rs/tokio#7933</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7977">#7977</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7977">tokio-rs/tokio#7977</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7989">#7989</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7989">tokio-rs/tokio#7989</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7991">#7991</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7991">tokio-rs/tokio#7991</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7996">#7996</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7996">tokio-rs/tokio#7996</a>
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7997">#7997</a>:
<a
href="https://redirect.github.com/tokio-rs/tokio/pull/7997">tokio-rs/tokio#7997</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="0af06b7bab"><code>0af06b7</code></a>
chore: prepare Tokio v1.51.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8005">#8005</a>)</li>
<li><a
href="01a7f1dfab"><code>01a7f1d</code></a>
chore: prepare tokio-macros v2.7.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8004">#8004</a>)</li>
<li><a
href="eeb55c733b"><code>eeb55c7</code></a>
runtime: steal tasks from the LIFO slot (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7431">#7431</a>)</li>
<li><a
href="1fc450aefb"><code>1fc450a</code></a>
runtime: stabilize <code>LocalRuntime</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7557">#7557</a>)</li>
<li><a
href="324218f9bb"><code>324218f</code></a>
Merge tag 'tokio-1.47.4' (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8003">#8003</a>)</li>
<li><a
href="aa65d0d0b8"><code>aa65d0d</code></a>
chore: prepare Tokio v1.47.4 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/8002">#8002</a>)</li>
<li><a
href="bf18ed452d"><code>bf18ed4</code></a>
sync: fix panic in <code>Chan::recv_many</code> when called with
non-empty vector on clo...</li>
<li><a
href="43134f1e57"><code>43134f1</code></a>
wasm: add wasm32-wasip2 networking support (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7933">#7933</a>)</li>
<li><a
href="b4c3246d33"><code>b4c3246</code></a>
macros: improve overall macro hygiene (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7997">#7997</a>)</li>
<li><a
href="7947fa4bd7"><code>7947fa4</code></a>
rt: add runtime name (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7924">#7924</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-1.50.0...tokio-1.51.0">compare
view</a></li>
</ul>
</details>
<br />

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-06 07:16:38 +00:00
niya
06921b0725 devtools: rename the remaining NodeActor variables (#43969)
- Renames variables containing the `NodeActor` name to `node_name`

Testing: Manually tested with `mach test-devtools` 
Fixes: #43606 as described
[here](https://github.com/servo/servo/issues/43606#issuecomment-4189623228)
for `NodeActor`

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-06 07:05:26 +00:00
Martin Robinson
73c64b6182 servoshell: Only dismiss the most-recently opened IME (#43932)
Servo may hide and show IME when handling `blur` and `focus` events, but
those events can be fired asynchronously when `<iframe>`s are involved.
This change ensures that we only dismiss the IME when it was the
most-recently opened one, making it so that an asynchronously fired
'blur' event for another control doesn't dismiss a newly opened one.

Testing: We don't really have testing for this level of servoshell.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-06 07:02:26 +00:00
Abbas Olanrewaju Sarafa
9799656127 devtools: Replace new with register for PauseActor (#43957)
Replaced new with register for PauseActor in pause.rs & lib.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-06 05:20:01 +00:00
Abbas Olanrewaju Sarafa
b8cff58b6c devtools: Replace new with register for WatcherActor (#43911)
Replaced new with register for WatcherActor in browsing_context &
watcher.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-04-06 05:14:13 +00:00
Tim Miller
3b128b37e3 script: Fix GC tracing of compiled JSScript pointers in ClassicScript (#43933)
Stores the compiled JSScript pointer in a rooted location that is
traceable by the GC. This fixes a crash observed in an experimental C#
Servo binding that could not be reproduced in servoshell.

Testing: No automated deterministic way to trigger this problem.

---------

Signed-off-by: Tim Miller <innerlogic4321@gmail.com>
2026-04-06 04:44:37 +00:00
Euclid Ye
0353f11ee2 script/mach: Increase stack size of ScriptThread/StyleThread to 8MiB to match recursion depth of other browsers (#43888)
TL;DR: We increase stack size of `ScriptThread` to 8MiB, and set Stylo
stack size environment var
to 8 MiB for all builds. This only reserves virtual memory space which
is
basically unlimited for 64-bit machine,
matches the recursion depth of Chromium for the example, which also uses
8MiB.

Stylo stack increase is necessary to prevent overflow when
refreshing/navigating to the example,
probably because initial load restyle incrementally but not refresh.

Testing: Added a Servo-specific test.

---
For example in #43845, we get stack overflow when we got more than 394
nested shadow roots.
For Chromium, it happens for more than 1631: 
<img width="290" height="127" alt="image"
src="https://github.com/user-attachments/assets/b3d75627-4e80-4586-9b85-4b58d8a0cd33"
/>
For Firefox, it overflows for more than 1052.

Initially I thought we didn't implement this optimally, and have
unnecessary recursion depth.
But the real reason is explained in Rust std:
> The default stack size is platform-dependent and subject to change.
Currently, it is 2 MiB on all Tier-1 platforms.

For Chromium, the visual studio dumpbin shows the stack size :
```
Dump of file C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe
OPTIONAL HEADER VALUES
          800000 size of stack reserve
```
This is hex value, which is $8*16^5$, exactly 8MiB.

After we make the same change in Servo, we are fine at 1601 and
overflows at 1602.
This matches Chromium behaviour, defeating firefox, and should not
create much overhead,
as this only reserves virtual memory space: 
I tried to increase the value to 512MiB, but task manager still says
73MB RAM used,
and we won't crash even with 10000 nested shadow roots. 
But that is just for more evidence and uncalled for.

Fixes: #43845

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-06 03:10:11 +00:00
dependabot[bot]
da9b9d9aa0 build: bump semver from 1.0.27 to 1.0.28 (#43966)
[//]: # (dependabot-start)
⚠️  **Dependabot is rebasing this PR** ⚠️ 

Rebasing might not happen immediately, so don't worry if this takes some
time.

Note: if you make any changes to this PR yourself, they will take
precedence over the rebase.

---

[//]: # (dependabot-end)

Bumps [semver](https://github.com/dtolnay/semver) from 1.0.27 to 1.0.28.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/dtolnay/semver/releases">semver's
releases</a>.</em></p>
<blockquote>
<h2>1.0.28</h2>
<ul>
<li>Documentation improvements</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7625c7aa3f"><code>7625c7a</code></a>
Release 1.0.28</li>
<li><a
href="fd404d082c"><code>fd404d0</code></a>
Merge pull request 351 from czy-29/master</li>
<li><a
href="f75f26e984"><code>f75f26e</code></a>
The <code>doc_auto_cfg</code> and <code>doc_cfg</code> features have
been merged</li>
<li><a
href="9e2bfa2ec8"><code>9e2bfa2</code></a>
Enable <code>serde</code> on <code>docs.rs</code> and automatically add
<code>serde</code> flag to the docs</li>
<li><a
href="8591f2344b"><code>8591f23</code></a>
Unpin CI miri toolchain</li>
<li><a
href="66bdd2ce5f"><code>66bdd2c</code></a>
Pin CI miri to nightly-2026-02-11</li>
<li><a
href="324ffce5d9"><code>324ffce</code></a>
Switch from cargo bench to criterion</li>
<li><a
href="34133a568a"><code>34133a5</code></a>
Update actions/upload-artifact@v5 -&gt; v6</li>
<li><a
href="7f935ffc72"><code>7f935ff</code></a>
Update actions/upload-artifact@v4 -&gt; v5</li>
<li><a
href="c07fb91353"><code>c07fb91</code></a>
Switch from test::black_box to std::hint::black_box</li>
<li>Additional commits viewable in <a
href="https://github.com/dtolnay/semver/compare/1.0.27...1.0.28">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=semver&package-manager=cargo&previous-version=1.0.27&new-version=1.0.28)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-06 00:56:15 +00:00
dependabot[bot]
2a47b3dcef build: bump libz-sys from 1.1.25 to 1.1.28 (#43962)
Bumps [libz-sys](https://github.com/rust-lang/libz-sys) from 1.1.25 to
1.1.28.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libz-sys/releases">libz-sys's
releases</a>.</em></p>
<blockquote>
<h2>1.1.28</h2>
<p>This release is mainly for testing the new <code>maint</code> tool to
prevent wrong releases in future.</p>
<p>It also adds a macOS fix for when the <code>cc</code> based build
script is used.</p>
<h2>1.1.27</h2>
<h2>What's Changed</h2>
<ul>
<li>Bump actions/download-artifact from 8.0.0 to 8.0.1 in the
github-actions group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/263">rust-lang/libz-sys#263</a></li>
<li>fix(zlib): remove unnecessary defines by <a
href="https://github.com/weihanglo"><code>@​weihanglo</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/264">rust-lang/libz-sys#264</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/weihanglo"><code>@​weihanglo</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/264">rust-lang/libz-sys#264</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/libz-sys/compare/1.1.25...1.1.27">https://github.com/rust-lang/libz-sys/compare/1.1.25...1.1.27</a></p>
<h2>1.1.26 [YANKED]</h2>
<h2>YANKED</h2>
<p>These didn't contain the actual source code and thus wasn't
functional.</p>
<h2>What's Changed</h2>
<ul>
<li>Bump actions/download-artifact from 8.0.0 to 8.0.1 in the
github-actions group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/263">rust-lang/libz-sys#263</a></li>
<li>fix(zlib): remove unnecessary defines by <a
href="https://github.com/weihanglo"><code>@​weihanglo</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/264">rust-lang/libz-sys#264</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/weihanglo"><code>@​weihanglo</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/264">rust-lang/libz-sys#264</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/libz-sys/compare/1.1.25...1.1.26">https://github.com/rust-lang/libz-sys/compare/1.1.25...1.1.26</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="346d882bef"><code>346d882</code></a>
bump version to 1.1.28 for macOS arm build fix via CC</li>
<li><a
href="7b4f21928c"><code>7b4f219</code></a>
cargo fmt and clippy</li>
<li><a
href="613d426250"><code>613d426</code></a>
Create a new <code>maint</code> tool to prevent common publishing
mistakes (<a
href="https://redirect.github.com/rust-lang/libz-sys/issues/265">#265</a>)</li>
<li><a
href="e4f06f16f4"><code>e4f06f1</code></a>
fix(zng): use crc32_armv8 for ARM cc builds</li>
<li><a
href="847cabf870"><code>847cabf</code></a>
bump to 1.1.27 for re-release after 1.1.26 was yanked</li>
<li><a
href="613a5cbca2"><code>613a5cb</code></a>
adapt <code>cargo-zng</code> script to deal with Cargo.lock file (by
ignoring it)</li>
<li><a
href="a2f22b1b51"><code>a2f22b1</code></a>
bump patch level prior to release</li>
<li><a
href="580d147321"><code>580d147</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/libz-sys/issues/264">#264</a>
from weihanglo/freebsd</li>
<li><a
href="817bbc0c6d"><code>817bbc0</code></a>
fix(zlib): remove unnecessary defines</li>
<li><a
href="232b03a9f9"><code>232b03a</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/libz-sys/issues/263">#263</a>
from rust-lang/dependabot/github_actions/github-actio...</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/libz-sys/compare/1.1.25...1.1.28">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libz-sys&package-manager=cargo&previous-version=1.1.25&new-version=1.1.28)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-06 00:41:52 +00:00
dependabot[bot]
56cc25aaf0 build: bump arc-swap from 1.9.0 to 1.9.1 (#43961)
Bumps [arc-swap](https://github.com/vorner/arc-swap) from 1.9.0 to
1.9.1.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/vorner/arc-swap/blob/master/CHANGELOG.md">arc-swap's
changelog</a>.</em></p>
<blockquote>
<h1>1.9.1</h1>
<ul>
<li>One more SeqCst :-| (<a
href="https://redirect.github.com/vorner/arc-swap/issues/204">#204</a>).</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f100e6c2ee"><code>f100e6c</code></a>
One more SeqCst</li>
<li>See full diff in <a
href="https://github.com/vorner/arc-swap/compare/v1.9.0...v1.9.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=arc-swap&package-manager=cargo&previous-version=1.9.0&new-version=1.9.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-06 00:37:16 +00:00
dependabot[bot]
ae1d4b56cf build: bump glib from 0.22.3 to 0.22.4 in the gstreamer-related group (#43958)
Bumps the gstreamer-related group with 1 update:
[glib](https://github.com/gtk-rs/gtk-rs-core).

Updates `glib` from 0.22.3 to 0.22.4
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gtk-rs/gtk-rs-core/releases">glib's
releases</a>.</em></p>
<blockquote>
<h2>0.22.4</h2>
<pre><code>Bilal Elmoussaoui:
      glib: Allow setting FINAL/DEPRECATED flags
      ci: Only run compile tests on glib crate
      Fix typos job
<p>Ignacio Casal Quinteiro:
glib-win32: fix export of function</p>
<p>Sebastian Dröge:
Update gir / gir-files
Regenerate with latest gir / gir-files
rustfmt: Update to 2024 edition
glib: Make sure to acquire the main context and make it thread default
in <code>MainContext::block_on()</code>
glib: Add various <code>#[allow(deprecated)]</code> to
<code>glib::wrapper!</code> for when the parent class/interface is
deprecated
Update versions to 0.22.4
</code></pre></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="48b79229f2"><code>48b7922</code></a>
Revert &quot;gio: Add &quot;D-Bus&quot; and &quot;DBus&quot; to
Cargo.toml keywords and description&quot;</li>
<li><a
href="42be84cb2e"><code>42be84c</code></a>
Update versions to 0.22.4</li>
<li><a
href="0835bbce70"><code>0835bbc</code></a>
glib: Add various <code>#[allow(deprecated)]</code> to
<code>glib::wrapper!</code> for when the par...</li>
<li><a
href="dc7961a302"><code>dc7961a</code></a>
gio: Add &quot;D-Bus&quot; and &quot;DBus&quot; to Cargo.toml keywords
and description</li>
<li><a
href="8377bd2cc7"><code>8377bd2</code></a>
glib-win32: fix export of function</li>
<li><a
href="d77af0b6c3"><code>d77af0b</code></a>
Fix typos job</li>
<li><a
href="9ea24d8403"><code>9ea24d8</code></a>
ci: Only run compile tests on glib crate</li>
<li><a
href="a9d5040cb4"><code>a9d5040</code></a>
glib: Allow setting FINAL/DEPRECATED flags</li>
<li><a
href="aae7fcb22c"><code>aae7fcb</code></a>
glib: Make sure to acquire the main context and make it thread default
in `Ma...</li>
<li><a
href="fac3d07f2a"><code>fac3d07</code></a>
rustfmt: Update to 2024 edition</li>
<li>Additional commits viewable in <a
href="https://github.com/gtk-rs/gtk-rs-core/compare/0.22.3...0.22.4">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=glib&package-manager=cargo&previous-version=0.22.3&new-version=0.22.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-06 00:17:52 +00:00
Sharan Poojari
57b86edb89 layout: Fix line breaking opportunities for Chinese and Japanese (#43744)
Enable `CJK-aware` line breaking in inline layout so Chinese/Japanese
text gets proper wrap opportunities instead of overflowing containers.

Testing: some WPT are now passing

---------

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-04-05 23:15:54 +00:00
Abbas Olanrewaju Sarafa
674bd2567c devtools: Replace new with register for TabDescriptorActor (#43909)
Replaced new with register for TabDescriptorActor in browsing_context &
tab.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-05 21:47:40 +00:00
Tim van der Lippe
a1c8896eda script: Pass &mut JSContext to reflect_node_with_proto (#43952)
A lot (and I mean, really a lot) depends on these constructors.
Therefore, this is the one spaghetti ball that I could extract and
convert all `can_gc` to `cx`. There are some new introductions of
`temp_cx` in the callbacks of the servo parser, but we already had some
in other callbacks.

Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-05 18:07:30 +00:00
rovertrack
621f6b0cf7 servo: Use _ prefixed names for unused arguments for public API functions (#43947)
updated all methods that were using underscore in arguments

- `WebViewDelegate`
   - `notify_cursor_changed`: Added _cursor.
   - `notify_traversal_complete`: Added _traversal_id.
   - `notify_input_event_handled`: Added _event_id and _result.
   - `notify_fullscreen_state_changed`: Added _is_fullscreen.
   - `request_move_to`: Added _point.
   - `request_create_new`: Added _request.
   - `request_permission:` Added _request.
   - `show_bluetooth_device_dialog`: Added _request.
 - `WebXrRegistry`
    - `register`: Added _registry

Testing: No tests necessary as this is just renaming argument.
Fixes: #43894

Signed-off-by: Rover track <rishan.pgowda@gmail.com>
2026-04-05 16:03:51 +00:00
Muhammad Mostafa
bb368dbb12 script: Add error messages in StaticRange (#43260)
Adds specific InvalidNodeType error messages in StaticRange for
Constructor().

Part of [#40756](https://github.com/servo/servo/issues/40756)

Signed-off-by: Mohamed Mostafa <mohamedmoustafaa1998@gmail.com>
2026-04-05 12:40:03 +00:00
Tim van der Lippe
46582ec41d script: Remove CanGc::note() from create.rs (#43946)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-05 12:28:12 +00:00
Tim van der Lippe
496d808ab1 script: Pass &mut JSContext to consume_stream (#43944)
Migrates all but one `CanGc::note()` to `cx`. The
last one requires `invoke_script_environment_preparer` to have a safe
hook in mozjs.

Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-05 11:31:21 +00:00
Tim van der Lippe
1fd77d022e script: Pass &mut JSContext to make_atomic_setter (#43942)
Part of #42812

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-05 11:26:55 +00:00
Tim van der Lippe
cf1b104b1a script: Pass &mut JSContext to RoutedPromiseListener (#43943)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-05 11:18:25 +00:00
Martin Robinson
9da7484061 script: Support deleting words with backspace in textual inputs (#43940)
This change makes it so that when you press alt or control (depending on
the platform) while backspacing, entire words are deleted. This matches
the behavior of the major desktop platforms.

Testing: This change adds a Servo-specific test for this behavior as
well
as for normal backspacing.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-05 10:28:31 +00:00
Taym Haddadi
6d6d1d371e IndexedDB: Fix fire-success/error event exception handling and explicit commit (#43914)
Fix fire-success/error event exception handling and explicit commit

Testing: fire-success/error event wpt test fixed.
Fixes: part of #40983

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-05 07:26:34 +00:00
webbeef
0b5688fdfa parser: add a pretty printer for top-level json documents (#43702)
This adds a new resource implementing a simple pretty printer for json
documents.

Testing: build this branch and launch with `./mach run
https://httpbin.org/json`

<img width="1044" height="1064" alt="image"
src="https://github.com/user-attachments/assets/42680c4b-2971-482a-af2b-9017f0f81752"
/>

---------

Signed-off-by: webbeef <me@webbeef.org>
Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Co-authored-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-04-05 06:50:52 +00:00
Kingsley Yung
623ce59383 script: Move Web Crypto interfaces to script/dom/webcrypto (#43939)
Move interfaces defined by the Web Crypto specification to the
`script/dom/webcrypto/` from `script/dom/`. This includes `Crypto`,
`CryptoKey` and `SubtleCrypto` (with its submodules).

Testing: No behavior changes.
Fixes: Part of #38901

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-05 06:42:00 +00:00
Jonathan Schwender
e6ed6954b4 bootstrap: Sync packages with book (#43931)
This commit removes some unneeded lines from README.md in the
linux_packages folder. This will trigger `book-export` to run, since it
creates a diff in that folder.
Since the export only happens if there is a diff, and there have been
not changes since the auto sync PR landed, the formatting related
changes never got upstreamed (sorting the packages).

This also duplicates as a test of the #43920 (merged), to be absolutely
sure that it works as intended.

Testing: not required / in a way this is a test of our book-export
action.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-05 06:36:49 +00:00
Abbas Olanrewaju Sarafa
2476d98f34 devtools: Replace new with register for ThreadConfigurationActor (#43916)
Replaced new with register for ThreadConfigurationActor in
thread_configuration.rs & watcher.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-05 06:15:27 +00:00
Euclid Ye
bb94d98bb2 mach: Set up build mode (Side effect: Stylo thread stack size reduced to 512 KiB again for most build) (#43930)
Previously the mode is always "". Now we set it to the real profile.
Note that previously, all the build has 2MiB stylo thread stack size,
which is unintended.
What we wanted is to make it so for debug build, and 8MiB for ASAN.

Now, those other than debug/ASAN would have 512KiB default stack size
again.

Testing: Manually tested and printed the mode at
0b6b97384d/python/servo/command_base.py (L419-L420).
Fixes: #43927

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-05 01:51:58 +00:00
Servo WPT Sync
ff9e242de9 Sync WPT with upstream (05-04-2026) (#43938)
Automated downstream sync of changes from upstream as of 05-04-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
2026-04-05 01:39:41 +00:00
Jambong Ralpher
54987adba2 Automatically generate CONTENT_EVENT_HANDLER_NAMES from WebIDL (#43848)
Replaced the hand-written CONTENT_EVENT_HANDLER_NAMES list in
eventtarget.rs with an auto-generated version. A new
ContentEventHandlerNames method in codegen.py iterates through WebIDL
descriptors whose prototype chain includes Node, collects attribute
members with EventHandler callback types, and generates a sorted,
duplicate free Rust array. The list is included from eventtarget.rs
eliminating manual maintenance and ensuring it stays in sync
automatically.

Testing: Build passes with cargo build -j2 -p servo-script. The
generated ContentEventHandlerNames.rs produces the same set of event
handler names as the previous hand-written list. No new runtime tests
are needed since this is a compile time change.

Fixes: #43611

Signed-off-by: staysafe020 <jambongralpher@gmail.com>
2026-04-04 20:52:41 +00:00
Abbas Olanrewaju Sarafa
7c05e1556f devtools: Replace new with register for ProcessActor (#43923)
Replaced new with register for ProcessActor in process.rs & root.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 13:17:20 +00:00
Abbas Olanrewaju Sarafa
3af1abc013 devtools: Replace new with register for AccessibilityActor (#43907)
Replaced new with register for AccessibilityActor in browsing_context &
accessibility.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 13:14:16 +00:00
Jonathan Schwender
06f6320609 ci: Secure book-sync secrets with environment (#43920)
We defined a github environment `book-sync` which contains the required
secrets.
After merging this PR we can remove the secrets from the per-repository
secrets, which reduces the scope the secrets are available in, and has
the added restriction of only being available on protected branches.

Testing: Prior to this PR, the functionality was tested on the
`environments` branch and discussed in the maintainers chat. After this
PR is merged, a manual check should be done to ensure the book-export
workflow still continues to work as expected.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-04 11:34:27 +00:00
Tim van der Lippe
a683c03140 script: Pass &mut JSContext to make_int_setter (#43928)
Part of #42638

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-04 11:23:37 +00:00
Martin Robinson
953206e7c4 script: Add an initial implementation of relatedTarget forfocus/blur events (#43926)
This is an initial implementation for `relatedTarget` of `focus` and
`blur` events. As the code doesn't yet follow the specification this is
a bit tricky to associate with specification text, but this should be
correct. A later change will adapt the code to the "focusing steps" part
of the specification.

In addition, a duplicated call to `Element::set_focus_state` is removed.

Testing: This gets one more WPT test passing.

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-04-04 10:32:22 +00:00
Ashwin Naren
3718abd626 Prevent panic on client storage directory conflict (#43918)
Instead of erroring out, it makes sense to open an in memory database so
that the thread can keep functioning.

Fixes:
https://servo.zulipchat.com/#narrow/channel/263398-general/topic/WPT.20regression

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
2026-04-04 10:24:24 +00:00
Abbas Olanrewaju Sarafa
571562c092 devtools: Replace new with register for NetworkEventActor (#43925)
Replaced new with register for NetworkEventActor in network_event.rs &
lib.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 09:24:45 +00:00
Abbas Olanrewaju Sarafa
86dca5f7dd devtools: Replace new with register for BrowsingContextActor (#43924)
Replaced new with register for BrowsingContextActor in
browsing_context.rs & lib.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 09:23:36 +00:00
Jonathan Schwender
42ba33d7ef mach: Fix typo in allocator feature name (#43922)
This name was mistyped during the rename of the servo crates to be
`servo-` prefixed.

Testing: Manual testing with `./mach build --with-asan`. This is not run
in CI.

Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
2026-04-04 09:15:58 +00:00
Abbas Olanrewaju Sarafa
0b6b97384d devtools: Replace new with register for PerformanceActor (#43921)
Replaced new with register for PerformanceActor in performance.rs &
root.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 08:27:26 +00:00
Abbas Olanrewaju Sarafa
b886d57024 devtools: Replace new with register for ThreadActor (#43910)
Replaced new with register for ThreadActor in browsing_context,
thread.rs & lib.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 07:47:23 +00:00
Abbas Olanrewaju Sarafa
f161acbdaf devtools: Replace new with register for BreakpointListActor (#43917)
Replaced new with register for BreakpointListActor in breakpoint.rs &
watcher.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 06:50:16 +00:00
Tim van der Lippe
20265ced1d script: Allow for implicit cx for setters (#43524)
Rather than specifying a cx for every single CSS property from Stylo, we
instead make it implicit. This allows us to remove the `CanGc::note()`
from the macro and pass in the `cx` as normal.

We can use a similar approach for setters in other elements where we use
the setter macros.

Part of #42812

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-04 06:46:13 +00:00
Abbas Olanrewaju Sarafa
4876a49eba devtools: Replace new with register for CssPropertiesActor (#43908)
Replaced new with register for CssPropertiesActor in browsing_context &
css_properties.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-04-04 05:57:41 +00:00
Abbas Olanrewaju Sarafa
2ce06e370d devtools: Replace new with register for NetworkParentActor (#43913)
Replaced new with register for NetworkParentActor in network_parent.rs &
watcher.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 04:59:45 +00:00
Abbas Olanrewaju Sarafa
410f4a4270 devtools: Replace new with register for ReflowActor (#43906)
Replaced new with register for ReflowActor in browsing_context &
reflow.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-04 04:56:07 +00:00
yvt
c6bb3cc363 Implement the IDL security check (#28583)
<https://heycam.github.io/webidl/#es-operations>
<https://html.spec.whatwg.org/multipage/#integration-with-idl>

This PR implements the IDL security check, which is an important (but
not only) mechanism to restrict cross-origin DOM accesses.

This implementation follows WebKit's behavior and not the specification
for the following reasons:

 - Neither Gecko nor WebKit implements the specification's behavior.
- This would require a relatively elaborate mechanism *just* to have
access to the target object's `CrossOriginProperties`.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #___ (GitHub issue number if applicable)

---
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because ___

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-04-04 04:18:08 +00:00
Simon Sapin
894327e5d9 Don’t print passing unit tests (#43902)
This removes from the output of `./mach test-unit` hundreds of lines
like:

```
        PASS [   0.011s] style_tests str::test_str_join_empty
```

Signed-off-by: Simon Sapin <simon@igalia.com>
2026-04-04 01:59:05 +00:00
xtqqczze
c8c200cf96 build(deps): bump rustix from 1.1.2 to 1.1.4 (#43898)
Signed-off-by: xtqqczze <45661989+xtqqczze@users.noreply.github.com>
2026-04-04 00:55:03 +00:00
Taym Haddadi
2c5f981d46 indexeddb: abort pending worker upgrade and delete new db on rollback (#42998)
Abort pending upgrade requests when a worker closes, correctly roll back
newlyy created databases by deleting backend state on old_version == 0.

Testing: IndexedDB/worker-termination-aborts-upgrade.window.js.ini test
pass.
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-03 22:32:13 +00:00
Martijn Gribnau
9b69acb88b Replace normal struct instantiation with register for WalkerActor (#43881)
Part of a larger refactor to name all actors and variables consistently,
#43800.

Testing: not necessary beyond `mach test-devtools` per #43800 / #43606
Fixes: `#43800` ((not linking because it's one of many PR's).

Signed-off-by: Martijn Gribnau <garm@ilumeo.com>
2026-04-03 19:04:12 +00:00
Martin Robinson
c0d0a87b01 script: Modernize the HTMLElement WebIDL (#43904)
The WebIDL file for `HTMLElement` was quite out of date. This change
makes it match the current HTML specification and also moves `blur()` to
`HTMLOrSVGElement` as it is in the spec. The implementation is just a
copy of the one for `HTMLElement` as we do for `focus()`.

Testing: This should not change behavior (other than adding a `blur()`
method
for SVG -- which we don't support), so should be covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-03 18:25:33 +00:00
Martin Robinson
b9df62427b script: Expose legacy table cellSpacing, cellPadding, and align DOM properties (#43903)
We support these setting these as attributes on the `<table>` element
itself, so I suppose it also makes sense to support their DOM APIs as
well. This trades a teensy bit of code for compatability with a some old
web content.

Testing: This causes a handful of reflection subtests to start passing.
There
isn't much testing for the behavior of the attributes, but this is
legacy
behavior so it sort of makes sense.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-03 18:09:13 +00:00
Shubham Gupta
4e315eba20 paint: Use viewport meta tag's min-scale and max-scale to clamp pinch zoom (#40098)
**Note: Targeting Mobile devices only.**

Clamp Pinch Zoom factor using `viewport`' scale range parsed from
`<meta>` tag.

## **Behavior in Servo with this PR**

Zoom Type |  Device Type | Meta Supported |Range 
-- | -- | -- | -- 
Pinch Zoom |  Mobile | Yes |Parsed from <meta> 
Pinch Zoom |  Desktop | No |Default

## **Observed behavior in Chrome**:

Device Type | Viewport Meta Support (pref) | Pinch Zoom (No Reflow) |
Zoom (using keyboard)
-- | -- | -- | --
Mobile (Android) | Yes | Clamped within Viewport Meta Range | Applied to
Pinch Zoom*
Desktop (Touch Screen) | No | Clamped within Default Range | Same as
Zoom (using menu)

## References from Chromium:
- Defination of
[page_scale_delta](https://source.chromium.org/chromium/chromium/src/+/main:cc/trees/layer_tree_host_client.h;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=39?gsn=page_scale_delta&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dcc%2Ftrees%2Flayer_tree_host_client.h%23SKME3VsvfEmKrf_3d5aQckyeMEaDxgiGETVRCM1Haac);
-
[WebViewImpl::ApplyViewportChanges](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/exported/web_view_impl.cc;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=4108?gsn=ApplyViewportChanges&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dthird_party%2Fblink%2Frenderer%2Fcore%2Fexported%2Fweb_view_impl.cc%23ll5snmeunTDzY4PwOwxyrNwNc4EI13SFfZnHIWuBsNw)
->
[SetPageScaleFactorAndLocation](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/exported/web_view_impl.cc;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=2430?gsn=SetPageScaleFactorAndLocation&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dthird_party%2Fblink%2Frenderer%2Fcore%2Fexported%2Fweb_view_impl.cc%23wJPsxPYe-aA-buH8xy-IKLTHLqtZ_IgGsuARSYerlUE)
->
[SetScaleAndLocation](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/frame/visual_viewport.cc;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=513?gsn=SetScaleAndLocation&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dthird_party%2Fblink%2Frenderer%2Fcore%2Fframe%2Fvisual_viewport.cc%23u-DPCmPBwcQcKi3oKJ1duPI83otfHDXzsQI8KMYusaA)
->
[DidSetScaleOrLocation](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/frame/visual_viewport.cc;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=543?gsn=DidSetScaleOrLocation&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dthird_party%2Fblink%2Frenderer%2Fcore%2Fframe%2Fvisual_viewport.cc%23cUPTZHhvInyEDOapVOzXmCPKg9DO_tYGVZY7y0D9EBw)
->
[ClampToConstraints](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/frame/page_scale_constraints.cc;drc=56c66e417c83e2096a4e4e8a5c4ab7bbd525c9f3;bpv=1;bpt=1;l=60?gsn=ClampToConstraints&gs=KYTHE%3A%2F%2Fkythe%3A%2F%2Fchromium.googlesource.com%2Fcodesearch%2Fchromium%2Fsrc%2F%2Fmain%3Flang%3Dc%252B%252B%3Fpath%3Dthird_party%2Fblink%2Frenderer%2Fcore%2Fframe%2Fpage_scale_constraints.cc%23hQCpRu6_p6TTaFLTpDMnO_d-g3SnRpG-p5UlazTZlK8)

Testing: New WPT Test Added:
`wpt/visual-viewport/viewport-scale-clamped.html`



Fixes: #40390 (Observed Inconsistent behavior with Chrome Android)

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-03 11:50:31 +00:00
Narfinger
6cece2de59 servo: Add WebView::load_request and UrlRequest to the API (#43338)
This is the continuation of https://github.com/servo/servo/pull/43310
with permission from https://github.com/longvatrong111 to continue the
work as they are currently busy.

This changes the previous PR by having a a new URLRequest object that
can have more parameters. Currently we only implement headers.


Testing: We only have unit tests for the embedder API and I am not sure
how they would look like in this case.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
Co-authored-by: batu_hoang <longvatrong111@gmail.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-04-03 11:09:30 +00:00
Abbas Olanrewaju Sarafa
b95dbb8721 devtools: Replace new with register for ConsoleActor (#43896)
Replace new with register for ConsoleActor in console & lib.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-03 10:50:21 +00:00
Martin Robinson
f5c23cd711 servoshell: Only send ImeEvent::Dismissed when the user dismisses the IME (#43872)
We receive the `Ime::Disabled` event both when the user dismisses the
IME and
when Servo itself dismisses it (for instance, when changing focus on the
page).
Servo will blur the current element upon receiving
`ImeEvent::Dismissed`,
leading to spurious focus behavior. Address this by only sending this
message
to Servo when it was triggered by the user (as best as we can tell).
This
problem was revealed by improvements in the internal focus APIs.

This is a bit of a bandaid until we have a more robust IME API. There
are
still missing pieces in both Servo and in winit.

Testing: This is a bit tricky to test as it depends a lot on when
messages are
sent to servoshell from winit / the windowing system and when Servo
processes
focus events.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-03 10:41:49 +00:00
Martin Robinson
e3c894b12e servo: Remove WebViewDelegate::play_gamepad_haptic_effect and WebViewDelegate::stop_gamepad_haptic_effect (#43895)
This functionality was moved to the `GamepadDelegate`, but the old
delegate methods were never removed. They are currently unused.

Testing: This change just removes dead code, so no tests are necessary.
Fixes: #43743

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-03 10:23:08 +00:00
Simon Wülker
a9dd2b3d15 servo: Fix rustdoc warnings (#43892)
One warning remains:
```
warning: public documentation for `intercept` links to private item `InterceptedWebResourceLoad`
   --> components/servo/webview_delegate.rs:240:11
    |
240 |     /// [`InterceptedWebResourceLoad`].
    |           ^^^^^^^^^^^^^^^^^^^^^^^^^^ this item is private
    |
    = note: this link resolves only because you passed `--document-private-items`, but will break without
    = note: `#[warn(rustdoc::private_intra_doc_links)]` on by default

warning: `servo` (lib doc) generated 1 warning
```

I think that's a false positive, because `InterceptedWebResourceLoad`
*is* public.

Testing: We don't run `./mach doc` in CI, so there's no way to test this

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-03 10:19:38 +00:00
Abbas Olanrewaju Sarafa
91ede77766 devtools: Replace new with register for DeviceActor (#43893)
Replace new with register for DeviceActor in device & root.rs

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-03 10:18:04 +00:00
Babalola Taiwo J
ac712151b5 script: Fix assertion failure when stringifying cross-origin location object (#43844)
This fixes the assertion failure (`!JS_IsExceptionPending(*cx)`) that
happens when `console.log()` is called on a cross-origin location object
(e.g. `console.log(frame.contentWindow.location)`).

The problem was that `maybe_stringify_dom_object` calls `ToString` on
cross-origin objects, which throws a JS exception via the
`DissimilarOriginLocation` stringifier. That exception was never
cleared, so subsequent JS API calls would hit the assertion.

The fix refactors `console_argument_from_handle_value` using an
inner/outer function pattern based on @jdm's suggestion:
- The inner function returns `Result<ConsoleArgument, ()>` and returns
`Err(())` when `console_object_from_handle_value` returns `None` for an
object, instead of falling through to `stringify_handle_value` which
could trigger the same crash
- The outer function catches the `Err`, reports any pending JS exception
via `report_pending_exception`, and returns a fallback `ConsoleArgument`

Fixes #43530

---

- [x] `./mach build -d` does not report any errors
- [x] `./mach fmt` produces no changes
- [x] There are tests for these changes

---------

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-04-03 10:15:05 +00:00
Sam
e6782a5bda script: Support auto generating all types of cx (#43174)
This will be useful in the future but for now we just always emit old
cx.

Testing: None
Work for #40600

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-04-03 08:43:58 +00:00
Abbas Olanrewaju Sarafa
c5c26230a2 devtools: Replace new with register for StyleSheetsActor (#43889)
Replaced new with register for StyleSheetsActor in browsing_context &
stylesheets

Testing: No testing required, compiles successfully.
Fixes: Part of #43800

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-03 07:00:54 +00:00
Kingsley Yung
c1e9e04868 script: Implement SubtleCrypto.supports (#43703)
Implement the `SubtleCrypto.supports` method in our WebCrypto API. The
*check support for an algorithm* algorithm is also implemented to
support the functionality of the `SubtleCrypto.supports` method.

The `SubtleCrypto.supports` method has two overloads. One of them has a
union containing a non-object value at the distinguishing index. Our
`codegen.py` currently does not support unions of non-object values at
distinguish index. So, `codegen.py` is also patched to extend its
support to unions of objects, strings, numbers and boolean values.

Specification of `SubtleCrypto.supports`:

https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-supports
Specification of "check support for an algorithm":

https://wicg.github.io/webcrypto-modern-algos/#dfn-check-support-for-algorithm

Testing:
- Pass WPT tests related to `supports` method.
- Add new tests for IDL operation overloading with unions of various
types.

Fixes: Part of #40687

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-04-03 06:52:26 +00:00
Euclid Ye
b47ab9c500 net: Set "request-includes-credentials" and URL list of response for "HTTP-network-or-cache fetch" (#43798)
Part of #33616

Implement step 11, 13 of [HTTP-network-or-cache
fetch](https://fetch.spec.whatwg.org/#concept-http-network-or-cache-fetch)

Testing: The value should be used in
https://fetch.spec.whatwg.org/#cross-origin-resource-policy-internal-check,
which will be done in a follow up. Right now it is not used.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-03 06:49:10 +00:00
treetmitterglad
0054b71d38 Fix error message for illegal HTML element constructors (#41107) (#43882)
Changes the error message for illegal HTML element constructors like
`new HTMLElement()` from `new.target must not be the active function
object` to `Illegal constructor.`, matching Chrome, Firefox, and the
HTML spec.

Ran `./mach test-wpt tests/wpt/tests/custom-elements`. 180 tests passed
as expected, 1 pre-existing unrelated crash in `HTMLMediaElement`.

#41107

Signed-off-by: Eli Bowman <asdfup@protonmail.com>
2026-04-03 01:41:56 +00:00
Josh Matthews
b386708c93 script: Move eventsource out of event module. (#43884)
The EventSource interface is unrelated to the other code in the event
module.

Testing: Just moving code around; no runtime impact.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-03 01:40:49 +00:00
CynthiaOketch
1385107eb9 wpt: Enable /infrastructure tests (#20889) (#43879)
Added the top-level `/infrastructure` WPT directory to `include.ini`,
which was previously excluded by the root `skip: true` default.

- Skipped `[reftest]` as I was unsure whether the failures indicate a
real bug in Servo's reftest engine
- Skipped `[testdriver][bidi]` as BiDi WebDriver is not supported
- Added metadata for known expected failures (service workers, shared
workers, expected-fail harness tests, etc.)
- Removed stale metadata for tests that now pass


Testing: 
  Ran` ./mach test-wpt infrastructure/ ` before and after the change.
                                                                  
  Before: 114 ran as expected, 69 unexpected results.
  After: 166 ran as expected. Remaining 15 unexpected results are
  all in /infrastructure/reftest/ which is skipped in include.ini.

Fixes: #20889

---------

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-04-03 00:46:22 +00:00
Oriol Brufau
b0582911db Upgrade Stylo to 2026-04-01 (#43878)
This continues  #43045

Changelog:
- Upstream:
74ddab4091...6de1071549
- Servo fixups:
9f2f4f3f1b...6cfce6f329

Stylo tracking issue: https://github.com/servo/stylo/issues/347

Summary of improvements:
 - Adding support for the CSS-wide `revert-rule` keyword
- `::details-content` becomes element-backed, thus accepting nested
pseudo-elements like `::details-content::before`.
- Custom properties can now be registered using dashed idents in their
syntax
 - Various `attr()` improvements

Testing: Various WPT improvements

---------

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-04-03 00:03:25 +00:00
niya
b1fc99bc6c refactor: rename PropertyIteratorActor related variable names (#43876)
Rename variables associated with `PropertyIteratorActor`

Testing: Tested locally with `mach test-devtools`

Fixes: A part of #43606

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-02 19:06:09 +00:00
niya
ff4122bc51 devtools: rename ObjectActor and SymbolIteratorActor variables names (#43875)
Rename variables associated with `ObjectActor` and `SymbolIteratorActor`

Testing: Tested locally with mach test-devtools

Fixes: A part of https://github.com/servo/servo/issues/43606

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-02 17:52:01 +00:00
Martin Robinson
87627c4c74 script: Also set the focus state on focused area's shadow hosts (#43873)
The specification says that `:focus` should be active on all shadow
hosts of ancestors of focused areas. This change does that by exposing a
new `DocumentFocusHandler::set_focused_element` method and also using it
during the "removing steps." This is important because unlike the
"focusing steps" `set_focused_element` does not cause focus and blur
events.

Testing: This leads to a progression in results on 8 WPT tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-02 17:21:16 +00:00
Kelechi Ebiri
e1f4c1f869 stylo: Update Stylo to remove PseudoElement::DetailsSummary. (#43849)
Companion PR for servo/stylo#345
Fixes: #43812

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-02 17:14:52 +00:00
Martin Robinson
ed8576b163 script: Move all focus-related code to components/script/document/focus.rs and create DocumentFocusHandler (#43868)
This continues the work to split up the large DOM structs. In this case
we create a helper struct to store focus-related state much like
`DocumentEventHandler`.

Testing: This is mostly code motion, so should be covered by existing
tests.
Fixes: #43720

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-02 14:11:32 +00:00
Abbas Olanrewaju Sarafa
782dce68c4 Used encoding-parsing algorithm in follow_hyperlink (#43822)
Used encoding-parsing algorithm in follow_hyperlink

Testing: Ran ```./mach test-wpt
tests/wpt/tests/html/semantics/links/links-created-by-a-and-area-elements```
Result;
```
Running 11 tests in web-platform-tests

Ran 11 tests finished in 74.9 seconds.
  • 11 ran as expected.
```

Second test;
```./mach test-wpt tests/wpt/tests/html/semantics/links/links-created-by-a-and-area-elements/anchor-src-encoding.html```
Result;
```
web-platform-test
~~~~~~~~~~~~~~~~~
Ran 2 checks (1 subtests, 1 tests)
Expected results: 2
Unexpected results: 0
OK
```

Fixes: #43508

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-04-02 13:45:08 +00:00
Jonathan Schwender
78ffbe8caa servo-hyper-serde: Use the workspace version (#43866)
`hyper_serde` currently has no dependants on crates.io. We give up the
independant versioning and simplify our setup by using the same version
as our workspace. The new crate is servo-hyper-serde.

Testing: Not required, policy change.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-02 12:25:12 +00:00
elomscansio
1e213e59b2 script: Move MutationObserver DOM interfaces to script/dom/mutationobserver (#43865)
Moves MutationObserver interfaces into script/dom/mutationobserver/
module from script/dom/.

Testing: Just a refactor shouldn't need any testing.
Fixes: Part of https://github.com/servo/servo/issues/38901

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-04-02 11:52:56 +00:00
Martin Robinson
33f74feffd script: Fully implement DocumentOrShadowRoot#activeElement (#43861)
`DocumentOrShadowRoot#activeElement` should return retargeted results.
What that means is that if the DOM anchor of the `Document`'s focused
focusable area is within a shadow root, `Document#activeElement` should
return the shadow host. This change implements that behavior, properly
returning the `activeElement` from both `Document` and `ShadowRoot`.

Testing: This causes a decent number of WPT tests and subtests to start
passing. One subtest starts to fail, because it uses the `autofocus`
attribute
which we do not yet support.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-02 11:12:30 +00:00
atbrakhi
9a43d43c32 devtools: Merge preview and scopes (#43860)
Before we had seperate parsing functions for preview and scopes. In this
change we merge them into one.

Testing: current tests are passing, also tested manually.
Fixes: #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-04-02 10:02:38 +00:00
Martin Robinson
5b743ef1f4 script: Run the focusing steps when navigating to a fragment (#43859)
When navigating to a fragment the specification says to run the focusing
steps. This is possible now that the focusing steps are properly
exposed. This change also adds support for the fallback option, which is
used when the focus target is not associated with a focuable area. In
this case the fallback is to focus the viewport.

Testing: This change adds a new WPT for this behavior, which was
seemingly not tested before.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-02 09:34:05 +00:00
Narfinger
f7d77754ff base: Implement MallocSizeOf for some more types (#43858)
This implements MallocSizeOf for a couple more types and removes some
"ignore_malloc_size_of" throughout the codebase.
- std::path::PathBuf
- tokio::sync::oneshot::Sender
- http::HeaderMap (with a reasonable approximation of iterating over all
headers)
- data_url::Mime by looking at the inner type
- http::Method: Is an enum internally
- urlpattern::Urlpattern: Iterating over all public fields that are
strings as an approximation.

Testing: We cannot test if MallocSizeOf is correct currently.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-04-02 08:13:08 +00:00
Tim van der Lippe
5fdd425dd2 script: Align navigate more with spec steps (#43857)
This moves step 23 to the end of the algorithm and also updates the spec
steps related to JavaScript navigations.

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-04-02 08:11:07 +00:00
Euclid Ye
beed34612c devtools: Update outdated TODO (#43851)
These were here 10 years ago.

1. All Actor names are already immutable: 
- All actor implementations store a name: String field set at
construction and never mutate it.
- The name is only used as key by `ActorRegistry` to look up
2. There is no `register_later`

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-02 07:37:16 +00:00
dependabot[bot]
12fb7f415d build: bump hyper from 1.8.1 to 1.9.0 (#43856)
Bumps [hyper](https://github.com/hyperium/hyper) from 1.8.1 to 1.9.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/hyperium/hyper/releases">hyper's
releases</a>.</em></p>
<blockquote>
<h2>v1.9.0</h2>
<h2>Features</h2>
<ul>
<li><strong>client:</strong>
<ul>
<li>expose HTTP/2 current max stream count (<a
href="https://redirect.github.com/hyperium/hyper/issues/4026">#4026</a>)
(<a
href="d51cb71569">d51cb715</a>)</li>
<li>add HTTP/2 <code>max_local_error_reset_streams</code> option (<a
href="https://redirect.github.com/hyperium/hyper/issues/4021">#4021</a>)
(<a
href="577874591c">57787459</a>)</li>
</ul>
</li>
<li><strong>error:</strong> add 'Error::is_parse_version_h2' method (<a
href="393c77c711">393c77c7</a>)</li>
<li><strong>http1:</strong> add UpgradeableConnection::into_parts (<a
href="e21205cfe4">e21205cf</a>)</li>
</ul>
<h2>Bug Fixes</h2>
<ul>
<li><strong>ffi:</strong> validate null pointers before dereferencing in
request/response functions (<a
href="https://redirect.github.com/hyperium/hyper/issues/4038">#4038</a>
(<a
href="28e73ccd23">28e73ccd</a>)</li>
<li><strong>http1:</strong>
<ul>
<li>allow keep-alive for chunked requests with trailers (<a
href="https://redirect.github.com/hyperium/hyper/issues/4043">#4043</a>)
(<a
href="7211ec25ef">7211ec25</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4044">#4044</a>)</li>
<li>use case-insensitive matching for trailer fields (<a
href="https://redirect.github.com/hyperium/hyper/issues/4011">#4011</a>)
(<a
href="3b344cac9f">3b344cac</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4010">#4010</a>)</li>
<li>use httparse config for Servers (<a
href="https://redirect.github.com/hyperium/hyper/issues/4002">#4002</a>)
(<a
href="bcb8ec5766">bcb8ec57</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/3923">#3923</a>)</li>
</ul>
</li>
<li><strong>http2:</strong>
<ul>
<li>cancel sending client request body on response future drop (<a
href="https://redirect.github.com/hyperium/hyper/issues/4042">#4042</a>)
(<a
href="5b17a69ebc">5b17a69e</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4040">#4040</a>)</li>
<li>non-utf8 char in Connection header may cause panic when calling
to_str (<a
href="https://redirect.github.com/hyperium/hyper/issues/4019">#4019</a>)
(<a
href="c36ca8a5c5">c36ca8a5</a>)</li>
</ul>
</li>
</ul>
<h2>Refactors and chores</h2>
<ul>
<li>docs(error): add more information about is_incomplete_message by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/hyper/pull/3978">hyperium/hyper#3978</a></li>
<li>Run cargo-audit in CI to check for known vulnerabilities in
dependencies. by <a
href="https://github.com/f0rki"><code>@​f0rki</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/3246">hyperium/hyper#3246</a></li>
<li>refactor(http1): simplify match of Token parse error by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/hyper/pull/3981">hyperium/hyper#3981</a></li>
<li>refactor(http1): use saturating_sub instead of manual impl by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/hyper/pull/3983">hyperium/hyper#3983</a></li>
<li>refactor(http1): replace many args of Chunked::step with struct by
<a href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a>
in <a
href="https://redirect.github.com/hyperium/hyper/pull/3982">hyperium/hyper#3982</a></li>
<li>docs: fix comment in <code>put_slice()</code> by <a
href="https://github.com/coryan"><code>@​coryan</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/3986">hyperium/hyper#3986</a></li>
<li>test(lib): fix unused warnings due to feature gating test imports by
<a href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a>
in <a
href="https://redirect.github.com/hyperium/hyper/pull/3997">hyperium/hyper#3997</a></li>
<li>docs: improve Read trait and ReadBufCursor documentation by <a
href="https://github.com/majiayu000"><code>@​majiayu000</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4000">hyperium/hyper#4000</a></li>
<li>fix: use h1 parser config when parsing server req by <a
href="https://github.com/0xPoe"><code>@​0xPoe</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4002">hyperium/hyper#4002</a></li>
<li>test(server): fix flaky disable_keep_alive_mid_request by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/hyper/pull/4009">hyperium/hyper#4009</a></li>
<li>chore(ci): update to actions/checkout@v6 by <a
href="https://github.com/tottoto"><code>@​tottoto</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4005">hyperium/hyper#4005</a></li>
<li>chore(ci): update to cargo-check-external-types 0.4.0 by <a
href="https://github.com/tottoto"><code>@​tottoto</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4006">hyperium/hyper#4006</a></li>
<li>update copyright year to 2026 by <a
href="https://github.com/jasmyhigh"><code>@​jasmyhigh</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4007">hyperium/hyper#4007</a></li>
<li>refactor: avoid unwrap examples by <a
href="https://github.com/0xPoe"><code>@​0xPoe</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4001">hyperium/hyper#4001</a></li>
<li>fix(http1): use case-insensitive matching for trailer fields by <a
href="https://github.com/HueCodes"><code>@​HueCodes</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4011">hyperium/hyper#4011</a></li>
<li>chore: convert bug report template to GitHub form by <a
href="https://github.com/njg7194"><code>@​njg7194</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4015">hyperium/hyper#4015</a></li>
<li>chore(ci): force toml mode in yq selecting msrv by <a
href="https://github.com/seanmonstar"><code>@​seanmonstar</code></a> in
<a
href="https://redirect.github.com/hyperium/hyper/pull/4020">hyperium/hyper#4020</a></li>
<li>fix: non-utf8 char may cause panic when calling to_str by <a
href="https://github.com/cuiweixie"><code>@​cuiweixie</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4019">hyperium/hyper#4019</a></li>
<li>feat(http2/client): add <code>max_local_error_reset_streams</code>
option by <a
href="https://github.com/ffuugoo"><code>@​ffuugoo</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4021">hyperium/hyper#4021</a></li>
<li>chore: drop pin-utils dependency by <a
href="https://github.com/tottoto"><code>@​tottoto</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4023">hyperium/hyper#4023</a></li>
<li>[minor] doc: Fix HTTP/2 max concurrent stream link by <a
href="https://github.com/dentiny"><code>@​dentiny</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4037">hyperium/hyper#4037</a></li>
<li>fix(ffi): validate null pointers before dereferencing in
request/resp… by <a
href="https://github.com/DhruvaD1"><code>@​DhruvaD1</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4038">hyperium/hyper#4038</a></li>
<li>h2: expose current max stream count by <a
href="https://github.com/howardjohn"><code>@​howardjohn</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4026">hyperium/hyper#4026</a></li>
<li>fix(http1): allow keep-alive for chunked requests with trailers by
<a href="https://github.com/wi-adam"><code>@​wi-adam</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4043">hyperium/hyper#4043</a></li>
<li>fix(http2): cancel pipe_task and send RST_STREAM on response future
drop by <a
href="https://github.com/mmishra100"><code>@​mmishra100</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/4042">hyperium/hyper#4042</a></li>
<li>Add APIs to allow switching an HTTP1 connection to HTTP2 if H2
preface is seen by <a
href="https://github.com/pborzenkov"><code>@​pborzenkov</code></a> in <a
href="https://redirect.github.com/hyperium/hyper/pull/3996">hyperium/hyper#3996</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/hyperium/hyper/blob/master/CHANGELOG.md">hyper's
changelog</a>.</em></p>
<blockquote>
<h2>v1.9.0 (2026-03-31)</h2>
<h4>Bug Fixes</h4>
<ul>
<li><strong>ffi:</strong> validate null pointers before dereferencing in
request/response functions (<a
href="https://redirect.github.com/hyperium/hyper/issues/4038">#4038</a>
(<a
href="28e73ccd23">28e73ccd</a>)</li>
<li><strong>http1:</strong>
<ul>
<li>allow keep-alive for chunked requests with trailers (<a
href="https://redirect.github.com/hyperium/hyper/issues/4043">#4043</a>)
(<a
href="7211ec25ef">7211ec25</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4044">#4044</a>)</li>
<li>use case-insensitive matching for trailer fields (<a
href="https://redirect.github.com/hyperium/hyper/issues/4011">#4011</a>)
(<a
href="3b344cac9f">3b344cac</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4010">#4010</a>)</li>
<li>use httparse config for Servers (<a
href="https://redirect.github.com/hyperium/hyper/issues/4002">#4002</a>)
(<a
href="bcb8ec5766">bcb8ec57</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/3923">#3923</a>)</li>
</ul>
</li>
<li><strong>http2:</strong>
<ul>
<li>cancel sending client request body on response future drop (<a
href="https://redirect.github.com/hyperium/hyper/issues/4042">#4042</a>)
(<a
href="5b17a69ebc">5b17a69e</a>,
closes <a
href="https://redirect.github.com/hyperium/hyper/issues/4040">#4040</a>)</li>
<li>non-utf8 char in Connection header may cause panic when calling
to_str (<a
href="https://redirect.github.com/hyperium/hyper/issues/4019">#4019</a>)
(<a
href="c36ca8a5c5">c36ca8a5</a>)</li>
</ul>
</li>
</ul>
<h4>Features</h4>
<ul>
<li><strong>client:</strong>
<ul>
<li>expose HTTP/2 current max stream count (<a
href="https://redirect.github.com/hyperium/hyper/issues/4026">#4026</a>)
(<a
href="d51cb71569">d51cb715</a>)</li>
<li>add HTTP/2 <code>max_local_error_reset_streams</code> option (<a
href="https://redirect.github.com/hyperium/hyper/issues/4021">#4021</a>)
(<a
href="577874591c">57787459</a>)</li>
</ul>
</li>
<li><strong>error:</strong> add 'Error::is_parse_version_h2' method (<a
href="393c77c711">393c77c7</a>)</li>
<li><strong>http1:</strong> add UpgradeableConnection::into_parts (<a
href="e21205cfe4">e21205cf</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="0d6c7d5469"><code>0d6c7d5</code></a>
v1.9.0</li>
<li><a
href="e21205cfe4"><code>e21205c</code></a>
feat(http1): add UpgradeableConnection::into_parts</li>
<li><a
href="393c77c711"><code>393c77c</code></a>
feat(error): add 'Error::is_parse_version_h2' method</li>
<li><a
href="5b17a69ebc"><code>5b17a69</code></a>
fix(http2): cancel sending client request body on response future drop
(<a
href="https://redirect.github.com/hyperium/hyper/issues/4042">#4042</a>)</li>
<li><a
href="7211ec25ef"><code>7211ec2</code></a>
fix(http1): allow keep-alive for chunked requests with trailers (<a
href="https://redirect.github.com/hyperium/hyper/issues/4043">#4043</a>)</li>
<li><a
href="d51cb71569"><code>d51cb71</code></a>
feat(client): expose HTTP/2 current max stream count (<a
href="https://redirect.github.com/hyperium/hyper/issues/4026">#4026</a>)</li>
<li><a
href="28e73ccd23"><code>28e73cc</code></a>
fix(ffi): validate null pointers before dereferencing in
request/response fun...</li>
<li><a
href="e13e783927"><code>e13e783</code></a>
docs(client): fix HTTP/2 max concurrent stream link to spec (<a
href="https://redirect.github.com/hyperium/hyper/issues/4037">#4037</a>)</li>
<li><a
href="8ba900853b"><code>8ba9008</code></a>
chore(dependencies): drop pin-utils dependency (<a
href="https://redirect.github.com/hyperium/hyper/issues/4023">#4023</a>)</li>
<li><a
href="577874591c"><code>5778745</code></a>
feat(client): add HTTP/2 <code>max_local_error_reset_streams</code>
option (<a
href="https://redirect.github.com/hyperium/hyper/issues/4021">#4021</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/hyperium/hyper/compare/v1.8.1...v1.9.0">compare
view</a></li>
</ul>
</details>
<br />

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-02 05:55:40 +00:00
Kelechi Ebiri
ed78dadacb doc: explain how to create a WebView (#43712) (#43787)
Added a "Creating a WebView" section to the `WebView` doc comment
explaining that `WebViewBuilder` is the correct way to create a
`WebView`, with a usage example. Also expanded the `WebViewBuilder` doc
comment to be more descriptive.
Fixes: #43712

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-04-02 05:22:41 +00:00
dependabot[bot]
8bda09c65a build: bump libc from 0.2.183 to 0.2.184 (#43854)
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.183 to 0.2.184.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/releases">libc's
releases</a>.</em></p>
<blockquote>
<h2>0.2.184</h2>
<h3>MSRV</h3>
<p>This release increases the MSRV of <code>libc</code> to 1.65. With
this update, you can now always use the
<code>core::ffi::c_*</code> types with <code>libc</code> definitions,
since <code>libc</code> has been changed to reexport from
<code>core</code> rather than redefining them. (This <em>usually</em>
worked before but had edge cases.)
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4972">#4972</a>)</p>
<h3>Added</h3>
<ul>
<li>BSD: Add <code>IP_MINTTL</code> to bsd (<a
href="https://redirect.github.com/rust-lang/libc/pull/5026">#5026</a>)</li>
<li>Cygwin: Add <code>TIOCM_DSR</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5031">#5031</a>)</li>
<li>FreeBSD: Added <code>xfile</code> structe and file descriptor types
(<a
href="https://redirect.github.com/rust-lang/libc/pull/5002">#5002</a>)</li>
<li>Linux: Add CAN netlink bindings (<a
href="https://redirect.github.com/rust-lang/libc/pull/5011">#5011</a>)</li>
<li>Linux: Add <code>struct ethhdr</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4239">#4239</a>)</li>
<li>Linux: Add <code>struct ifinfomsg</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5012">#5012</a>)</li>
<li>Linux: Define <code>max_align_t</code> for riscv64 (<a
href="https://redirect.github.com/rust-lang/libc/pull/5029">#5029</a>)</li>
<li>NetBSD: Add missing <code>CLOCK_</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5020">#5020</a>)</li>
<li>NuttX: Add <code>_SC_HOST_NAME_MAX</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5004">#5004</a>)</li>
<li>VxWorks: Add <code>flock</code> and <code>F_*LCK</code> constants
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4043">#4043</a>)</li>
<li>WASI: Add all <code>_SC_*</code> sysconf constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5023">#5023</a>)</li>
</ul>
<h3>Deprecated</h3>
<p>The remaining fixed-width integer aliases, <code>__uint128_t</code>,
<code>__uint128</code>, <code>__int128_t</code>, and
<code>__int128</code>,
have been deprecated. Use <code>i128</code> and <code>u128</code>
instead. (<a
href="https://redirect.github.com/rust-lang/libc/pull/4343">#4343</a>)</p>
<h3>Fixed</h3>
<ul>
<li><strong>breaking</strong> Redox: Fix signal action constant types
(<a
href="https://redirect.github.com/rust-lang/libc/pull/5009">#5009</a>)</li>
<li>EspIDF: Correct the value of <code>DT_*</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5034">#5034</a>)</li>
<li>Redox: Fix locale values and add <code>RTLD_NOLOAD</code>, some TCP
constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5025">#5025</a>)</li>
<li>Various: Use <code>Padding::new(&lt;zeroed&gt;)</code> rather than
<code>Padding::uninit()</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5036">#5036</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li><strong>potentially breaking</strong> Linux: Add new fields to
<code>struct ptrace_syscall_info</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4966">#4966</a>)</li>
<li>Re-export <code>core::ffi</code> integer types rather than
redefining (<a
href="https://redirect.github.com/rust-lang/libc/pull/5015">#5015</a>)</li>
<li>Redox: Update <code>F_DUPFD</code>, <code>IP</code>, and
<code>TCP</code> constants to match relibc (<a
href="https://redirect.github.com/rust-lang/libc/pull/4990">#4990</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/blob/0.2.184/CHANGELOG.md">libc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/libc/compare/0.2.183...0.2.184">0.2.184</a>
- 2026-04-01</h2>
<h3>MSRV</h3>
<p>This release increases the MSRV of <code>libc</code> to 1.65. With
this update, you can now always use the
<code>core::ffi::c_*</code> types with <code>libc</code> definitions,
since <code>libc</code> has been changed to reexport from
<code>core</code> rather than redefining them. (This <em>usually</em>
worked before but had edge cases.)
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4972">#4972</a>)</p>
<h3>Added</h3>
<ul>
<li>BSD: Add <code>IP_MINTTL</code> to bsd (<a
href="https://redirect.github.com/rust-lang/libc/pull/5026">#5026</a>)</li>
<li>Cygwin: Add <code>TIOCM_DSR</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5031">#5031</a>)</li>
<li>FreeBSD: Added <code>xfile</code> structe and file descriptor types
(<a
href="https://redirect.github.com/rust-lang/libc/pull/5002">#5002</a>)</li>
<li>Linux: Add CAN netlink bindings (<a
href="https://redirect.github.com/rust-lang/libc/pull/5011">#5011</a>)</li>
<li>Linux: Add <code>struct ethhdr</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4239">#4239</a>)</li>
<li>Linux: Add <code>struct ifinfomsg</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5012">#5012</a>)</li>
<li>Linux: Define <code>max_align_t</code> for riscv64 (<a
href="https://redirect.github.com/rust-lang/libc/pull/5029">#5029</a>)</li>
<li>NetBSD: Add missing <code>CLOCK_</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5020">#5020</a>)</li>
<li>NuttX: Add <code>_SC_HOST_NAME_MAX</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5004">#5004</a>)</li>
<li>VxWorks: Add <code>flock</code> and <code>F_*LCK</code> constants
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4043">#4043</a>)</li>
<li>WASI: Add all <code>_SC_*</code> sysconf constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5023">#5023</a>)</li>
</ul>
<h3>Deprecated</h3>
<p>The remaining fixed-width integer aliases, <code>__uint128_t</code>,
<code>__uint128</code>, <code>__int128_t</code>, and
<code>__int128</code>,
have been deprecated. Use <code>i128</code> and <code>u128</code>
instead. (<a
href="https://redirect.github.com/rust-lang/libc/pull/4343">#4343</a>)</p>
<h3>Fixed</h3>
<ul>
<li><strong>breaking</strong> Redox: Fix signal action constant types
(<a
href="https://redirect.github.com/rust-lang/libc/pull/5009">#5009</a>)</li>
<li>EspIDF: Correct the value of <code>DT_*</code> constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5034">#5034</a>)</li>
<li>Redox: Fix locale values and add <code>RTLD_NOLOAD</code>, some TCP
constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/5025">#5025</a>)</li>
<li>Various: Use <code>Padding::new(&lt;zeroed&gt;)</code> rather than
<code>Padding::uninit()</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/5036">#5036</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li><strong>potentially breaking</strong> Linux: Add new fields to
<code>struct ptrace_syscall_info</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4966">#4966</a>)</li>
<li>Re-export <code>core::ffi</code> integer types rather than
redefining (<a
href="https://redirect.github.com/rust-lang/libc/pull/5015">#5015</a>)</li>
<li>Redox: Update <code>F_DUPFD</code>, <code>IP</code>, and
<code>TCP</code> constants to match relibc (<a
href="https://redirect.github.com/rust-lang/libc/pull/4990">#4990</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="b1fd610c7e"><code>b1fd610</code></a>
chore: Release libc 0.2.184</li>
<li><a
href="f596819d7c"><code>f596819</code></a>
ci: Don't enforce cargo-semver-checks</li>
<li><a
href="4645f60c3a"><code>4645f60</code></a>
linux: update ptrace_syscall_info struct</li>
<li><a
href="14cbbec353"><code>14cbbec</code></a>
types: Remove <code>Padding::uninit</code></li>
<li><a
href="b5dcda885f"><code>b5dcda8</code></a>
pthread: Use <code>Padding::new(\&lt;zeroed&gt;)</code> rather than
<code>Padding::uninit()</code></li>
<li><a
href="bbb1c5d350"><code>bbb1c5d</code></a>
types: Add a <code>new</code> function to <code>Padding</code></li>
<li><a
href="df06e43309"><code>df06e43</code></a>
Fix locale values and add RTLD_NOLOAD, some TCP constants</li>
<li><a
href="078f5c6b3c"><code>078f5c6</code></a>
newlib/espidf: Move DT_* to espidf/mod.rs</li>
<li><a
href="d32b83db3c"><code>d32b83d</code></a>
Add IP_MINTTL to bsd</li>
<li><a
href="939e0ec2a8"><code>939e0ec</code></a>
Define max_align_t for riscv64-linux</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/libc/compare/0.2.183...0.2.184">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libc&package-manager=cargo&previous-version=0.2.183&new-version=0.2.184)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-02 04:51:16 +00:00
dependabot[bot]
eb296b77f6 build: bump the wayland-related group with 5 updates (#43853)
Bumps the wayland-related group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [wayland-client](https://github.com/smithay/wayland-rs) | `0.31.13` |
`0.31.14` |
| [wayland-cursor](https://github.com/smithay/wayland-rs) | `0.31.13` |
`0.31.14` |
| [wayland-protocols](https://github.com/smithay/wayland-rs) | `0.32.11`
| `0.32.12` |
| [wayland-protocols-plasma](https://github.com/smithay/wayland-rs) |
`0.3.11` | `0.3.12` |
| [wayland-protocols-wlr](https://github.com/smithay/wayland-rs) |
`0.3.11` | `0.3.12` |

Updates `wayland-client` from 0.31.13 to 0.31.14
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-cursor` from 0.31.13 to 0.31.14
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols` from 0.32.11 to 0.32.12
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols-plasma` from 0.3.11 to 0.3.12
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols-wlr` from 0.3.11 to 0.3.12
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-02 04:44:54 +00:00
treetmitterglad
a81b15d5a5 devtools: Rename NodeActor variables in walker.rs (#43847)
Standardize variable naming in `WalkerActor` (`walker.rs`), renaming
`node` → `node_name` in `find_child` to follow the `{}_name` convention.

Testing: `./mach test-devtools`, all 60 tests pass.

Fixes: Part of #43606

Signed-off-by: Eli Bowman <asdfup@protonmail.com>
2026-04-01 23:27:27 +00:00
niya
6150b1b2c0 devtools: rename NodeActor related variables (#43841)
Rename variables associated with `NodeActor`

Testing: Tested locally with mach test-devtools

Fixes: A part of https://github.com/servo/servo/issues/43606

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
2026-04-01 23:13:52 +00:00
Messi II Innocent R.
ce61f2eaa9 Fix child disappearing with mixed overflow clip/visible. (#43620)
Fix child element disappearing when parent has mixed overflow
clip/visible

When a parent element clips overflow on one axis but not the other (e.g.
overflow-y: clip with overflow-x: visible), the non-clipped axis was
using f32::MIN/f32::MAX. On screens with a device pixel ratio above 1,
this causes child elements to disappear.

The fix uses LayoutRect::max_rect() instead.

Testing: Reproduced the bug using --device-pixel-ratio 2 on Linux and
the child disappears on main branch but renders correctly with this fix.


fixes: #43599

Signed-off-by: Messi002 <rostandmessi2@gmail.com>
2026-04-01 22:38:51 +00:00
Oriol Brufau
827129a1a9 layout: Update group index when reusing table-column box (#43846)
Even if we can reuse the box, its column group index may have changed,
e.g. due to the removal of a previous column group. So just update it.

Testing: Adding crash test
Fixes: #39142

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-04-01 21:44:26 +00:00
Martin Robinson
a486ed525e script: Move "scroll into view" call out of "focusing steps" (#43842)
`HTMLOrSVGElement#focus` specifies the "scroll into view" steps should
be run after focusing. This was happening implicitly as part of the
`Document`'s implementation of the "focusing steps." That behavior is
not in the specification, so this change moves the scrolling call to
where it is specified. Along with making the code match the
specification, this change simplifies it as well.

Testing: This should not modify behavior, so existing tests should
suffice.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-01 21:40:13 +00:00
Simon Wülker
155016354c script: Implement PerformanceMeasureOptions (#43753)
The relevant changes are in `Performance::Measure`, the rest are
comments I added.

Testing: New tests start to pass

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-01 20:15:16 +00:00
Simon Wülker
8791236c7a script: Let wheel, keyboard- and pointerevents be composed when fired by the user agent (#43799)
Addtionally, this updates lots of outdated spec links for mouse-related
things that have moved from the uievents spec to the pointerevents spec.

Testing: This change adds new tests

Part of https://github.com/servo/servo/issues/35997
Fixes https://github.com/servo/servo/issues/37772

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-04-01 19:59:10 +00:00
niya
305276c55a devtools: rename LongStringActor name variables (#43838)
Changes `name` to `long_string_name`
`long_string` to `long_string_actor`

Testing: Tested locally with mach test-devtools

Fixes: A part of #43606

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
Co-authored-by: Niya Gupta <niyabits@disroot.org>
2026-04-01 16:44:09 +00:00
Martin Robinson
ceac966c34 script: Remove focus transaction concept (#43834)
For years Servo has had the concept of a focus transaction which was
used only to allow falling back to focusing the viewport when focusing a
clicked element failed. As this concept isn't part of the specification,
this change removes it.

Instead, a `FocusableArea` (a specification concept) is passed to
the `Document` focusing code. A `FocusableArea` might also be the
`Document`'s viewport.

As part of this change, some focus-related methods are moved to `Node`
from `Element` as the `Document` is not an `Element`.  This brings the
code closer to implementing the "focusing steps" from the specification.

Testing: This should not change behavior and is thus covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-01 15:12:21 +00:00
Euclid Ye
5fb3877f9f layout/script: Free memory earlier by consuming instead of draining the temporary container if it is unused (#43826)
Follow up of https://github.com/servo/servo/pull/43226
This also allows us to remove some `mut` declaration.
Fix some unintended Chinese quotation mark.

Testing: This is a micro-optimization which does not change visible
behaviour.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-04-01 13:46:53 +00:00
Jonathan Schwender
a463495c90 webgpu: Fix feature guard (#43831)
Remove the dependency on the `webgpu` crate if the feature is disabled.

Note: This doesn't seem to improve the binary size in production mode,
so presumably dead code elimination is already working well.
Nevertheless, it's preferable to correctly feature guard and it should
save a bit of compile-time (when not building with the webgpu feature).


Testing: `webgpu` feature is enabled by default in CI, and we test
`--no-default-features` too in the HOS build in CI. `cargo tree -p servo
--no-default-features` does not show webgpu anymore after this change.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-01 13:41:12 +00:00
eri
187206dc5a devtools: Show variable values in scopes (#43792)
<img width="312" height="307" alt="image"
src="https://github.com/user-attachments/assets/30c8cd9a-9712-4b53-9487-37c289a14520"
/>

Testing: Ran mach test-devtools and manual testing
Part of: #36027
Depends on: #43791

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-01 13:08:18 +00:00
Mukilan Thiyagarajan
069aa65d54 config: Add documentation for the public API. (#43802)
Testing: No code changes, so no testing is required.

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-04-01 11:50:19 +00:00
Martin Robinson
9cb65e242e script: Use TextInputWidget to implement <textarea> shadow DOM (#43770)
In addition to making it so that textual `<input>` and `<textarea>`
share a common shadow DOM structure, this allows styling the
`<textarea>` placeholder. It is now properly shown in grey.

Testing: This fixes a few WPT tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-04-01 11:41:28 +00:00
eri
c121a46c4f CODEOWNERS: Add atbrakhi and eerii as DevTools owners (#43832)
We have been working on the DevTools code and would like to have
notifications of new patches so we can review them.

Signed-off-by: eri <eri@igalia.com>
2026-04-01 10:10:54 +00:00
Shubham Gupta
ef3e8f7123 wpt: Add more tests to css-device-adapt to verify clamp behavior. (#43715)
Add more tests with values other than non-default values. 
Earlier tests were curated around default value. So, we never know if
anything is wrong.

Testing: Add more tests and update test expectations. Tests fail right
now, which will be dealt with in next patches. It requires two PRs to
properly fix.

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-01 10:08:16 +00:00
shuppy
4041256e24 a11y: Miscellaneous cleanups to our accessibility code (#43772)
this patch cleans up a few minor issues in our accessibility code:

- we remove the initial synchronous TreeUpdate in
[WebView::set_accessibility_active()](https://doc.servo.org/servo/struct.WebView.html#method.set_accessibility_active).
it’s not actually necessary, because AccessKit only requires that
subtree updates happen after the graft node is created in the parent,
but those subtree updates can be delayed indefinitely. removing it
simplifies our API a bit.

- we rename notify_accessibility_tree_id() to
notify_document_accessibility_tree_id(), and do the same to the
underlying ConstellationToEmbedderMsg variant. this helps clarify that
we’re referring to the (active top-level) document’s accessibility tree.

- we make that method pub(crate) too. it doesn’t need to be pub.

- we remove the label property from webview-to-pipeline graft nodes.
properties set on graft nodes are only visible in the accesskit_consumer
API, not in the platform accessibility API, and we don’t need it in our
tests, so there’s no longer any reason to keep setting it.

Testing: updated the relevant libservo accessibility tests
Fixes: part of #4344

Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-04-01 09:58:05 +00:00
shuppy
805519deac servoshell: Activate accessibility in all webviews (#43558)
this patch plumbs the webview accessibility trees (#43029, #43556) into
servoshell. we add a global flag in servoshell, which is set when the
platform activates accessibility and cleared when the platform
deactivates accessibility. the flag in turn [activates
accessibility](https://doc.servo.org/servo/struct.WebView.html#method.set_accessibility_active)
in existing and new webviews.

Testing: none in this patch, but will be covered by end-to-end platform
a11y tests in WPT
Fixes: part of #4344, extracted from our work in #42338

Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-04-01 09:46:48 +00:00
eri
fdadd1d31d devtools: Improve encoding of ObjectActor (#43791)
Remove a duplicate `ObjectPreview` and use `ObjectActor::encode` for
serialization.

Testing: Ran mach test-devtools and manual tests.
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-04-01 09:45:18 +00:00
Jonathan Schwender
d0be4e845d release: Bump version number to 0.1 (#43797)
In preparation for the next release, bump the version number to 0.1. 0.1
will be an LTS release, which receives extended support in terms of
security updates (e.g. spidermonkey security updates). Please keep in
mind that as always no specific guarantees or response times are given,
and any updated are provided on a best effort basis.

Previously some projects had a demo integration of servo based on some
version of servo, and then never or rarely updated it. Providing an LTS
release offers an option to embedders to integrate servo, while reducing
API churn and having a somewhat fixed schedule to adhere to in terms of
upgrades. Currently, the plan is for a new LTS release every 6 months,
with additional documentation regarding API changes and recommended
migration patterns (best-effort and subject to change).

Testing: No functional changes. Additional testing will be performed
post-merge on the newly created release branch.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-01 09:18:50 +00:00
Jonathan Schwender
15cc2686da servo: Fix gstreamer_plugins feature guard (#43830)
Testing: gstreamer feature is enable in CI, and we test both mac and
windows, which guard the elements in the module.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-01 08:22:32 +00:00
Shubham Gupta
23e69b0658 wpt: Delete viewport-apply-initial-scale-after-navigation.html (#43701)
Scenario proposed should be best tested using unit tests.

Testing: TODO (Waiting for #43160)
Fixes: #41582

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-04-01 08:07:27 +00:00
CynthiaOketch
4f67866cbe devtools: Rename new_registered to register and standardize variable names for SourceActor (#43810)
Part of #43800 and #43606.

I removed the `new` method from `SourceActor` entirely, as it was only
used internally by `new_registered`. I renamed `new_registered` to
`register`, inlined the struct construction directly using `Self { ...
}`, and updated the registration call to use
`registry.register::<Self>(actor)` to match the standard pattern
established across other actors.

I also standardized variable names throughout `SourceActor` and its call
sites to follow the conventions set in #43606:
- Renamed `name` and `source` to `source_name` and `source_actor`
respectively in `SourceManager::find_source`
- Renamed `actor_name` to `source_name` in `SourceManager::source_forms`
- Renamed `actor_name` to `source_name` in
`handle_update_source_content` in lib.rs

Testing: Built with cargo and ran ./mach test-devtools. 59/60 tests
pass; the one failure (test_manual_pause) is a pre-existing intermittent
timeout unrelated to these changes.


Fixes: part of  #43606 and #43800

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-04-01 07:58:42 +00:00
niya
4ef7097dc1 devtools: Rename BreakpointListActor Variable Names (#43825)
- Changes `breakpoint_list` to `breakpoint_list_actor`

Testing: Tested locally with `mach test-devtools`

Fixes: A part of #43606

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
Co-authored-by: Niya Gupta <niyabits@disroot.org>
2026-04-01 07:38:09 +00:00
webbeef
2518f97dac script: Remove useless upcast::<Element> calls (#43824)
upcast::<Type>() is costly in general, but in some cases we can avoid
that call and use a direct field access instead.

Testing: no test change expected.

Signed-off-by: webbeef <me@webbeef.org>
2026-04-01 07:33:04 +00:00
Jonathan Schwender
f4877c190e Embed default resources in Servo applications using a servo-default-resources crate (#43182)
This PR considers the following constraints:

- Resources must be available when building servo via a published
crates.io package (i.e. no `../../../resources/<file>` file references).
- Minimal setup when writing tests (`nextest` spawns each test in its
own process, so we don't want to explicitly initialize the resource
handler for every `#[test]` fn)
- Use local resources when developing locally
- Support loading the resources from a proper resource directory if the
embedder wishes so, including via a custom mechanism, not necessarily as
files

(File) Resources that are only accessed from servoshell are out of scope
of this PR, since it mainly focusses on unblocking publishing `libservo`
to crates.io.

Baking the resources into the binary by default simplifies the setup a
lot. We already supported that before, but only for testing purposes and
explicitly not for production builds.

Using [`inventory`](https://crates.io/crates/inventory) adds a simple
way for the embedder to replace the default baked in resources, while
also keeping the test usage of baked in resources simple.

rippy.png is also referenced from image_cache - We simply duplicate it,
since the image is small, to avoid adding unnecessarily complex
solutions like adding a dedicated crate.


Testing: Covered by existing tests. [mach try
full](https://github.com/jschwe/servo/actions/runs/23811669469)
Fixes: Part of #43145

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-04-01 07:16:28 +00:00
niya
05946163f2 devtools: Rename PauseActor Variable Names (#43820)
- `PauseActor` is passed as a generic for only `new_name`
- Update the variable `pause` to `pause_name`

**Testing**: Tested locally with `mach test-devtools`

```
Ran 60 tests in 74.781s

OK (expected failures=6)
```

**Fixes**: A part of #43606

Signed-off-by: Niya Gupta <niyabits@disroot.org>
Co-authored-by: Niya Gupta <niyabits@disroot.org>
2026-04-01 06:03:17 +00:00
Josh Matthews
c1bddb3801 script: Use snapshot of navigation target when navigating. (#43807)
This set of changes introduces a type matching the spec's "target
snapshot params" and uses it as part of determining the origin of new
documents. This has a side benefit of making our sandbox flag
determination more accurate, which leads to a bunch of sandboxing tests
passing as well as some new failures due to spec confusion about
origins.

Testing: Many new passing tests.
Part of the long road to #43149

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-04-01 04:45:12 +00:00
Taym Haddadi
c4d32e15cf indexeddb: fix structured cloning for transaction state, File, and FileList (#43805)
Testing: covered by WPT test.
Fixes: #43804

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-04-01 02:40:58 +00:00
dependabot[bot]
31b273dbb2 build: bump zerocopy from 0.8.47 to 0.8.48 (#43816)
Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.47 to
0.8.48.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="aa7c31671c"><code>aa7c316</code></a>
Release 0.8.48 (<a
href="https://redirect.github.com/google/zerocopy/issues/3157">#3157</a>)</li>
<li><a
href="fa6fa90177"><code>fa6fa90</code></a>
[zerocopy] Re-enable big endian aarch64 types (<a
href="https://redirect.github.com/google/zerocopy/issues/3073">#3073</a>)</li>
<li><a
href="61b2407b73"><code>61b2407</code></a>
[hermes] Release 0.1.0-alpha.7 (<a
href="https://redirect.github.com/google/zerocopy/issues/3151">#3151</a>)</li>
<li><a
href="b2c394cfa9"><code>b2c394c</code></a>
[hermes] Clone <code>hermes</code> branch at bb0e9f9f (<a
href="https://redirect.github.com/google/zerocopy/issues/3149">#3149</a>)</li>
<li><a
href="a5bc780b51"><code>a5bc780</code></a>
[hermes] Add auto-approval for <code>Cargo.lock</code> and
<code>vendor</code> (<a
href="https://redirect.github.com/google/zerocopy/issues/3150">#3150</a>)</li>
<li><a
href="b29cc75f25"><code>b29cc75</code></a>
[ci] Add <code>all-jobs-succeed</code> job in
<code>auto-approve.yml</code> (<a
href="https://redirect.github.com/google/zerocopy/issues/3147">#3147</a>)</li>
<li><a
href="10ce7672d5"><code>10ce767</code></a>
[hermes] Add description to README (<a
href="https://redirect.github.com/google/zerocopy/issues/3148">#3148</a>)</li>
<li><a
href="d01f773e99"><code>d01f773</code></a>
[ci] Disambiguate &quot;All checks succeeded&quot; jobs by name (<a
href="https://redirect.github.com/google/zerocopy/issues/3145">#3145</a>)</li>
<li><a
href="19006f87d0"><code>19006f8</code></a>
[hermes] Initial commit (<a
href="https://redirect.github.com/google/zerocopy/issues/3144">#3144</a>)</li>
<li><a
href="c6b794933a"><code>c6b7949</code></a>
[CI] Bump the all-actions group with 6 updates (<a
href="https://redirect.github.com/google/zerocopy/issues/3143">#3143</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/google/zerocopy/compare/v0.8.47...v0.8.48">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zerocopy&package-manager=cargo&previous-version=0.8.47&new-version=0.8.48)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-01 00:57:36 +00:00
dependabot[bot]
1369f85038 build: bump uuid from 1.22.0 to 1.23.0 (#43818)
Bumps [uuid](https://github.com/uuid-rs/uuid) from 1.22.0 to 1.23.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/uuid-rs/uuid/releases">uuid's
releases</a>.</em></p>
<blockquote>
<h2>v1.23.0</h2>
<h2>What's Changed</h2>
<ul>
<li>feat: add support for 'hyphenated' format in the serde module by <a
href="https://github.com/FrenchDilettante"><code>@​FrenchDilettante</code></a>
in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/865">uuid-rs/uuid#865</a></li>
<li>Fix a number of bugs in time-related code by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/872">uuid-rs/uuid#872</a></li>
<li>Reword invalid char error message by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/873">uuid-rs/uuid#873</a></li>
<li>Impl cleanups by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/874">uuid-rs/uuid#874</a></li>
<li>Use LazyLock to synchronize v1/v6 context initialization by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/875">uuid-rs/uuid#875</a></li>
<li>Prepare for 1.23.0 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/876">uuid-rs/uuid#876</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/FrenchDilettante"><code>@​FrenchDilettante</code></a>
made their first contribution in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/865">uuid-rs/uuid#865</a></li>
</ul>
<h2>Special thanks</h2>
<p><a href="https://github.com/meng-xu-cs"><code>@​meng-xu-cs</code></a>
raised a series of bugs against the timestamp logic in <code>uuid</code>
using automated tooling. The issues themselves were reasonably and
responsibly presented and the end result is a better <code>uuid</code>
library for everyone. Thanks!</p>
<h1>Deprecations</h1>
<p>This release includes the following deprecations:</p>
<ul>
<li><code>Context</code>: Renamed to <code>ContextV1</code></li>
<li><code>Timestamp::from_gregorian</code>: Renamed to
<code>Timestamp::from_gregorian_time</code></li>
</ul>
<h1>Change to <code>Version::Max</code></h1>
<p><code>Version::Max</code>'s <code>u8</code> representation has
changed from <code>0xff</code> to <code>0x0f</code> to match the value
returned by <code>Uuid::get_version_num</code>.</p>
<h1>Change to <code>Uuid::get_version</code> for the max UUID</h1>
<p><code>Uuid::get_version</code> will only return
<code>Some(Version::Max)</code> if the UUID is actually the max UUID
(all bytes are <code>0xff</code>). Previously it would return
<code>Some</code> if only the version field was <code>0x0f</code>. This
change matches the behaviour of the nil UUID, which only returns
<code>Some(Version::Nil)</code> if the UUID is the nil UUID (all bytes
are <code>0x00</code>).</p>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/uuid-rs/uuid/compare/v1.22.0...v1.23.0">https://github.com/uuid-rs/uuid/compare/v1.22.0...v1.23.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="00ab922d53"><code>00ab922</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/876">#876</a> from
uuid-rs/cargo/v1.23.0</li>
<li><a
href="726ba45fe3"><code>726ba45</code></a>
prepare for 1.23.0 release</li>
<li><a
href="996dadea02"><code>996dade</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/875">#875</a> from
uuid-rs/fix/context-ordering</li>
<li><a
href="e14047993b"><code>e140479</code></a>
simplify a use stmt</li>
<li><a
href="8ed9142847"><code>8ed9142</code></a>
reorganize and document more v7 context internals</li>
<li><a
href="e09a3225a8"><code>e09a322</code></a>
use LazyLock to synchronize v1/v6 context initialization</li>
<li><a
href="0f260cc671"><code>0f260cc</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/874">#874</a> from
uuid-rs/chore/impl-cleanups</li>
<li><a
href="1419e91097"><code>1419e91</code></a>
clean up and refactor main lib tests</li>
<li><a
href="ceeaf4b7b5"><code>ceeaf4b</code></a>
ensure we don't overflow on counters less than 12</li>
<li><a
href="63bc8f52e5"><code>63bc8f5</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/873">#873</a> from
uuid-rs/fix/error-msg</li>
<li>Additional commits viewable in <a
href="https://github.com/uuid-rs/uuid/compare/v1.22.0...v1.23.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=uuid&package-manager=cargo&previous-version=1.22.0&new-version=1.23.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-01 00:56:07 +00:00
dependabot[bot]
c056b71664 build: bump simd-adler32 from 0.3.8 to 0.3.9 (#43815)
Bumps [simd-adler32](https://github.com/mcountryman/simd-adler32) from
0.3.8 to 0.3.9.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/mcountryman/simd-adler32/commits/v0.3.9">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=simd-adler32&package-manager=cargo&previous-version=0.3.8&new-version=0.3.9)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-01 00:42:28 +00:00
dependabot[bot]
36922eed85 build: bump the wayland-related group with 3 updates (#43814)
Bumps the wayland-related group with 3 updates:
[wayland-backend](https://github.com/smithay/wayland-rs),
[wayland-scanner](https://github.com/smithay/wayland-rs) and
[wayland-sys](https://github.com/smithay/wayland-rs).

Updates `wayland-backend` from 0.3.14 to 0.3.15
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-scanner` from 0.31.9 to 0.31.10
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-sys` from 0.31.10 to 0.31.11
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-04-01 00:27:29 +00:00
Martin Robinson
d3c39bb68c script: Add support for ShadowRoot.delegatesFocus and start implementing the focusing steps (#43811)
This change has two main interdependent parts:

1. It starts to align Servo's focus code with what is written in the
   HTML specification. This is going to be a gradual change, so there
   are still many parts that do not match the specification yet. Still,
   this adds the major pieces.
2. It adds initial support for the `ShadowRoot.delegatesFocus` property
   which controls how focusing a shadow DOM root can delegate focus to
   one of its children.

Testing: This causes a few WPT tests to start passing.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-31 21:23:47 +00:00
Nico Burns
dc7487573f Implement direction property for CSS Grid (#42118)
Implement the `direction` property for CSS Grid:

- Upgrade to [Taffy
v0.10.0](github.com/DioxusLabs/taffy/releases/tag/v0.10.0)
- Add conversion function from Stylo's `Direction` enum to Taffy's
`Direction` enum
- Update assertions

---------

Signed-off-by: Nico Burns <nico@nicoburns.com>
2026-03-31 18:20:57 +00:00
Kingsley Yung
4d0c29c2c7 script: Require HMAC comparison to be constant time (#43773)
We should compare HMAC signatures in constant time when validating
user-provided signatures, to prevent leaking timing information
proportional to the number of matching bytes. The WebCrypto
specification has also updated to require to use constant-time
comparison in HMAC signatures.

We update our implementation accordingly. Since we are still using the
`aws-lc-rs` crate for our HMAC implementation, we use the function
`verify_slices_are_equal` provided by `aws_lc_rs::constant_time` to
guarantees the comparison is constant-time.

Specification Update:
c962bc7ebb
Testing: Existing tests suffice.

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-31 18:18:05 +00:00
Martin Robinson
fe9386ed7a script: Remove the special inner editor click focus workaround (#43803)
This workaround was only necessary when click focusing didn't look up
the ancestry chain for an applicable focusable area. Now that this
happens (via the code directly after), the workaround is no longer
necessary.

Testing: This should not change behvior so is covered by existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-31 15:14:38 +00:00
eri
a2980c07fa devtools: Replace new with register for PreferenceActor (#43801)
Testing: Compilation is enough
Part of: #43800

Signed-off-by: eri <eri@igalia.com>
2026-03-31 14:52:50 +00:00
niya
d9efd44c4c script: move fullscreen functionality to script/dom/fullscreen (#43771)
# Checklist

Relevant methods in Document are:

- [x] enter_fullscreen
- [x] exit_fullscreen
- [x] get_allow_fullscreen

Relevant method in DocumentOrShadowRoot is:
- [x] get_fullscreen_element

Relevant methods in Element are:

- [x] fullscreen_element_ready_check

Relevant structs in element.rs are:

- [x] ElementPerformFullscreenExit
- [x] ElementPerformFullscreenEnter

Testing: The PR moves functions around and we don't need to modify any
tests
Fixes: #43719

---------

Signed-off-by: Niya Gupta <niyabits@disroot.org>
Co-authored-by: Niya Gupta <niyabits@disroot.org>
2026-03-31 14:14:23 +00:00
nortti0
11687b3263 Port Servo to FreeBSD (#43116)
Add the minimum amount of FreeBSD-specific code to Servo, where no
platform-neutral fallback exists.

Testing: I've succesfully built and run Servo on FreeBSD with these
changes (and some fixes to dependencies). There's no functional change
to any other targets. This pull request was created with Servo running
on FreeBSD.
Fixes: #11625

---------

Signed-off-by: Juhani Krekelä <juhani@krekelä.fi>
Co-authored-by: Juhani Krekelä <juhani@krekelä.fi>
2026-03-31 14:11:13 +00:00
Tim van der Lippe
26a1942a33 Add script to show stale intermittent issues (#41739)
This script shows any issue which has not received any updates for over
a month. This means it is no longer intermittent and therefore can be
closed.

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-31 14:09:20 +00:00
Servo WPT Sync
54bc366160 Sync WPT with upstream (31-03-2026) (#43789)
Automated downstream sync of changes from upstream as of 31-03-2026
[no-wpt-sync]

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
Signed-off-by: Sam <16504129+sagudev@users.noreply.github.com>
Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-03-31 09:37:26 +00:00
Steven Novaryo
9caea2d16f base: Tidy up the usage of PipelineNamespaceId (#43790)
Use constant variable to define the `PipelineNamespaceId` for
`Constellation` and `Embedder`, and fix the comment describing the
declaration `next_pipeline_namespace_id`.

Testing: A successful build should be enough for the minimal
refactoring.

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2026-03-31 08:52:08 +00:00
Steven Novaryo
01689d241a layout: Persist ExternalScrollId for ::before and ::after pseudo element. (#43231)
In general, for a normal `BoxFragment`, a `ExternalScrollId` is created
by directly using the `OpaqueNode::id` which is the heap address of the
`Node`. But for a `BoxFragment` from a `::before` or `::after` pseudo
element, we are using the next unused id (starting from zero) with an
increment of two.

This patch modifies so that we are using the bitwise or of
`OpaqueNode::id` and `FragmentType` as the `ExternalScrollId`. With
these changes, the `ExternalScrollId` for the pseudo elements would
remain the same after reflow (instead of getting a new scroll id).

Testing: New WPT test
Fixes: #43308

---------

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2026-03-31 06:13:06 +00:00
Kelechi Ebiri
bb667737a9 script: Let Console::internal_warn take String instead of DOMString (#43780)
All callers were constructing a DOMString only to have it immediately
converted back to String inside internal_warn, resulting in an
unnecessary allocation and clone. This changes the parameter type to
String and updates all call sites to pass the result of format! or
.to_string() directly.

Fixes: #43091

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-03-31 06:02:13 +00:00
webbeef
5db86cc5f0 layout: remove noisy debug println (#43785)
These were forgotten in 17a7ee037b

Testing: no testing needed

Signed-off-by: webbeef <me@webbeef.org>
2026-03-31 01:38:14 +00:00
dependabot[bot]
efe01668ea build: bump cc from 1.2.57 to 1.2.58 (#43783)
Bumps [cc](https://github.com/rust-lang/cc-rs) from 1.2.57 to 1.2.58.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/releases">cc's
releases</a>.</em></p>
<blockquote>
<h2>cc-v1.2.58</h2>
<h3>Other</h3>
<ul>
<li>Update Compile-time Requirements to add info about clang-cl.exe (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1693">#1693</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md">cc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.57...cc-v1.2.58">1.2.58</a>
- 2026-03-27</h2>
<h3>Other</h3>
<ul>
<li>Update Compile-time Requirements to add info about clang-cl.exe (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1693">#1693</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="bf119a1581"><code>bf119a1</code></a>
chore(cc): release v1.2.58 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1694">#1694</a>)</li>
<li><a
href="8b8d71f0ec"><code>8b8d71f</code></a>
Update Compile-time Requirements to add info about clang-cl.exe (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1693">#1693</a>)</li>
<li><a
href="8c6b2d7cad"><code>8c6b2d7</code></a>
Update rusqlite requirement from 0.38.0 to 0.39.0 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1691">#1691</a>)</li>
<li>See full diff in <a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.57...cc-v1.2.58">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cc&package-manager=cargo&previous-version=1.2.57&new-version=1.2.58)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-31 00:38:41 +00:00
Abbas Olanrewaju Sarafa
4f316b7f84 script: Remove unnecessary Window::unminify_css field (#43778)
Initialize unminified_css_dir directly in Window::new instead of storing
a separate unminify_css bool and lazily setting the dir in
init_document.

Testing: Ran ```./mach run --unminify-css google.com``` also checked
```ls unminified-css/``` result was ```www.google.com www.gstatic.com```
Fixes: #43730

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 20:57:28 +00:00
Budiman Arbenta
35c3731c46 script: Implement <input type=range> widget's layout (#41562)
Implement the layout of `<input type="range">`. Support automatically
calculating the position of thumb based on the current input value, and
the size of range-track and range-thumb. Added a
document.has_script_or_layout_blocker function to detect whether it is
possible to run box_area_query during bind_to_tree, add delay_task if
there are blocker.

Here are some of the fixes made in this PR:
1. Fixed the structure for input type range's pseudo elements.
2. Fixed the positioning of input type range's thumb based on current
value, width, and direction.
3. Allow input type range to stretch vertically in a bigger container.

Original PR: #41024
Stylo PR: https://github.com/servo/stylo/pull/310

Testing: Some improvements in WPT tests, with a few regressions. This
change includes a Servo-specific appearance test to detect unexpected
changes to the look and feel of range widgets.
Fixes: #22728

---------

Signed-off-by: Budiman Arbenta <arbenta6@gmail.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: rayguo17 <tin.tun.aung1@huawei.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-30 20:20:58 +00:00
batu_hoang
399c8ebe31 servo: Add SiteDataManager::set_cookie_for_url and SiteDataManager::cookies_for_url (#43600)
Expose set_cookie_for_url, get_cookie_for_url, allow applications to
get/set cookies.

Testing: Unit test for `SiteDataManager` and manual test with
ServoShell.

---------

Signed-off-by: batu_hoang <longvatrong111@gmail.com>
2026-03-30 17:13:35 +00:00
CynthiaOketch
3a5031fd2a script: Move Element attribute getters/setters into attributes.rs (#43774)
Following #43714, which moved the element interfaces into the `element/`
directory and extracted `get_int_attribute` into `attributes.rs` as a
proof-of-concept, this PR moves the remaining attribute getter/setter
methods out of `element.rs` into the separate `attributes.rs` file.

  The following methods were moved:
  - `set_atomic_attribute`
  - `set_bool_attribute`
  - `get_url_attribute` / `set_url_attribute`
  - `get_trusted_type_url_attribute`
  - `get_trusted_html_attribute`
  - `get_string_attribute` / `set_string_attribute`
  - `get_nullable_string_attribute` / `set_nullable_string_attribute`
  - `get_tokenlist_attribute` / `set_tokenlist_attribute`
  - `set_atomic_tokenlist_attribute`
  - `set_int_attribute`
  - `get_uint_attribute` / `set_uint_attribute`

  This reduces the size of `element.rs` and groups all attribute-related
  helper methods together in one place.


Testing: 
No tests required as this is a pure code move with no behavioural
changes. The existing test suite covers the moved methods indirectly
through their callers. `cargo check` passes cleanly.

part of #38901
part of #43709
part of #43714

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-03-30 17:08:44 +00:00
Shubham Gupta
2d29c38e42 layout: Do not consider broken image as contentful (#43475)
1. Broken Images are skipped for FirstContentfulPaint as per specs.
2. Update the WPT test.

Testing: `tests/wpt/tests/paint-timing/fcp-only/fcp-broken-image.html`

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-30 15:40:08 +00:00
Ashwin Naren
2566b477ce storage: implement obtaining a storage bottle map, and create and delete databse (#42139)
Add a storage client concept, meant to implement
https://storage.spec.whatwg.org/

Implement https://storage.spec.whatwg.org/#obtain-a-storage-bottle-map

Also adds create and delete database functionality for the storage map
proxy, with a view towards indexeddb integration.


Testing: Unit tests cover basic functionality.

---------

Signed-off-by: Ashwin Naren <arihant2math@gmail.com>
Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com>
Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
Co-authored-by: gterzian <2792687+gterzian@users.noreply.github.com>
Co-authored-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-30 15:38:50 +00:00
Martin Robinson
322dfd0115 layout: Combine some common text segment data into FontAndScriptInfo (#43653)
This starts splitting out commonly shared data into a new data structure
that will make it easier to compare old shaping results to new ones in
the future. This eliminates some memory usage during inline layout, but
adds 8 bytes per segment (usually one per inline box). We hope to
recover this memory by storing one `GlyphStore` per `TextRunSegment`,
which
should recover 16 bytes.

Testing: This should not change behavior so is covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-30 13:15:23 +00:00
Kingsley Yung
c4ccb715e4 script: Guarantee constant-time all-zero check on X25519 secret (#43775)
The "deriveBits" operation of X25519 in WebCrypto throws an
OperationError when the secret is all-zero value. The check must be done
in constant time.

Although our implementation enforces comparing all bytes one-by-one
without early exit, it still does not guarantee the `u8` comparison is
constant-time due to compiler optimization and CPU microarchitectural
effects.

We switch to using the function `was_contributory` provided by the
`x25519-dalek` crate to check whether the secret is all-zero value, as
it guarantees constant-time execution. This enhances the security of our
WebCrypto API.

Testing: Security enhancement. Existing tests suffice.

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-30 12:34:50 +00:00
Martin Robinson
17a7ee037b layout: Integrate ::first-letter support into the InlineFormattingContextBuilder (#43692)
This change merges the first letter implementation into the
`InlineFormattingContextBuilder` as its more associated with inline
layout. The downside is that, due to ownership issues in Rust, the
builder must be unwrapped after ensuring it. Additionally, ensure
that `::first-letter` boxes are properly stored in a box slot meaning
that restyles work properly.

This change also makes a few small cleanups to the `first_letter_range`
function in addition to moving it to the inline code.

Testing: This does not change behavior and so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-30 11:40:09 +00:00
Abbas Olanrewaju Sarafa
6e799ca694 devtools: Rename FrameActor variable names (#43767)
Renamed FrameActor variable names to match standards in thread & lib.rs

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 09:58:29 +00:00
Jonathan Schwender
1a86292f20 embedder_traits: Add documentation for ResourceReaderMethods (#43769)
Testing: Documentation only, testing not required

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Martin Robinson <martin@abandonedwig.info>
2026-03-30 09:32:45 +00:00
Abbas Olanrewaju Sarafa
07a4335f4c devtools: Rename ThreadConfigurationActor variable names (#43765)
Renamed ThreadConfigurationActor variable names in watcher.rs.

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 07:21:31 +00:00
Abbas Olanrewaju Sarafa
906679a8c1 devtools: Rename ThreadActor variable names (#43723)
Renamed ThreadActor variable names in breakpoint, browsing_context,
watcher, worker & lib.rs.

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 07:14:12 +00:00
Abbas Olanrewaju Sarafa
134e4c7db1 devtools: Rename InspectorActor variable names (#43724)
Renamed InspectorActor variable names in browsing_context, inspector &
lib.rs

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 07:12:01 +00:00
Euclid Ye
47456e308c servo: Wait for context menu to appear to avoid race from IME embedder control (#43764)
When we mouse down the right button, we focus an input element, 
but the InputMethod embedder control request always arrives 
before that of Context Menu.


99132fe22b/components/script/dom/document/document_event_handler.rs (L906-L913)

This causes race as when we stop spinning the event loop when
`number_of_controls_shown`
is not 0, it is likely that servo has not received context menu request
yet.

Testing: This is **not an abuse of resource**, since the build finishes
within 9 sec and Unit tests 2m30s per run.
1. https://github.com/servo/servo/actions/runs/23711195455
2. https://github.com/servo/servo/actions/runs/23711197360
3. https://github.com/servo/servo/actions/runs/23711199228
4. https://github.com/servo/servo/actions/runs/23710867754
5.
https://github.com/servo/servo/actions/runs/23710874271/job/69070302172
6.
https://github.com/servo/servo/actions/runs/23710863934/job/69070280417
7.
https://github.com/servo/servo/actions/runs/23710888811/job/69070509775
8. https://github.com/servo/servo/actions/runs/23711200872

Fixes: #43726

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-30 05:16:30 +00:00
Taym Haddadi
4faaa254bb indexeddb: fix idbobjectstore rename error handling (#43754)
Implement the missing IDBObjectStore.name duplicate name checks so
renaming an object store to an existing store now throw ConstraintError

Testing: more indexeddb WPT test passed.

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-30 05:14:51 +00:00
dependabot[bot]
99132fe22b build: bump rustc-hash from 2.1.1 to 2.1.2 (#43761)
Bumps [rustc-hash](https://github.com/rust-lang/rustc-hash) from 2.1.1
to 2.1.2.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/rustc-hash/blob/master/CHANGELOG.md">rustc-hash's
changelog</a>.</em></p>
<blockquote>
<h1>2.1.2</h1>
<ul>
<li><a
href="https://redirect.github.com/rust-lang/rustc-hash/pull/65">Refactor
byte hashing to remove unreachable panic</a></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="fdb275c8a0"><code>fdb275c</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/rustc-hash/issues/67">#67</a>
from Noratrieb/new-version</li>
<li><a
href="acafa431e9"><code>acafa43</code></a>
Prepare 2.1.2</li>
<li><a
href="140e525344"><code>140e525</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/rustc-hash/issues/65">#65</a>
from morrisonlevi/split_first_chunk</li>
<li><a
href="f061387ad7"><code>f061387</code></a>
style: use consistent range format</li>
<li><a
href="211455cb39"><code>211455c</code></a>
refactor!: use split_first_chunk to help optimizer</li>
<li><a
href="464a82f557"><code>464a82f</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/rustc-hash/issues/63">#63</a>
from estebank/const-Default</li>
<li><a
href="2170d5e2a0"><code>2170d5e</code></a>
On nightly, <code>impl const Default</code></li>
<li><a
href="1a998d5b89"><code>1a998d5</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/rustc-hash/issues/62">#62</a>
from CryZe/128-bit-on-more-platforms</li>
<li><a
href="6849c16d79"><code>6849c16</code></a>
Use 128-bit Widening Multiply on More Platforms</li>
<li>See full diff in <a
href="https://github.com/rust-lang/rustc-hash/compare/v2.1.1...v2.1.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=rustc-hash&package-manager=cargo&previous-version=2.1.1&new-version=2.1.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-30 01:07:38 +00:00
dependabot[bot]
5defc0e5a9 build: bump aws-lc-sys from 0.39.0 to 0.39.1 (#43760)
Bumps [aws-lc-sys](https://github.com/aws/aws-lc-rs) from 0.39.0 to
0.39.1.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f58cfb9ded"><code>f58cfb9</code></a>
Prepare aws-lc-sys v0.39.1 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1080">#1080</a>)</li>
<li><a
href="88763b0554"><code>88763b0</code></a>
Fix Windows ARM64 FIPS build: pass correct architecture to vcvarsall.bat
(<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1075">#1075</a>)</li>
<li><a
href="04cac11b6b"><code>04cac11</code></a>
fix: follow symlinks when classifying include directory entries (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1071">#1071</a>)</li>
<li><a
href="d61726b69d"><code>d61726b</code></a>
Should be BSD-3-Clause (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1069">#1069</a>)</li>
<li>See full diff in <a
href="https://github.com/aws/aws-lc-rs/compare/aws-lc-sys/v0.39.0...aws-lc-sys/v0.39.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=aws-lc-sys&package-manager=cargo&previous-version=0.39.0&new-version=0.39.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-30 01:06:07 +00:00
Abbas Olanrewaju Sarafa
40fc2b8176 devtools: Rename CssPropertiesActor variable names (#43745)
Renamed CssPropertiesActor variable names in browsing_context

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-30 00:44:06 +00:00
dependabot[bot]
9eb4853176 build: bump mio from 1.1.1 to 1.2.0 (#43758)
Bumps [mio](https://github.com/tokio-rs/mio) from 1.1.1 to 1.2.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/mio/blob/master/CHANGELOG.md">mio's
changelog</a>.</em></p>
<blockquote>
<h1>1.2.0</h1>
<ul>
<li>Support was added for WASM Preview 2
(<a
href="https://redirect.github.com/tokio-rs/mio/pull/1931">tokio-rs/mio#1931</a>).</li>
<li>Implement <code>AsFd</code> for <code>Registry</code>
(<a
href="https://redirect.github.com/tokio-rs/mio/pull/1936">tokio-rs/mio#1936</a>).</li>
<li>The backlog size for listeners were changed to match std lib
(<a
href="https://redirect.github.com/tokio-rs/mio/pull/1934">tokio-rs/mio#1934</a>).</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="ce39a6be2c"><code>ce39a6b</code></a>
Release v1.2</li>
<li><a
href="a7b3210db7"><code>a7b3210</code></a>
Update FreeBSD 14 CI image to 14.4-RELEASE</li>
<li><a
href="adfeb3ea00"><code>adfeb3e</code></a>
Merge libc defining dependency</li>
<li><a
href="eaed9a08c7"><code>eaed9a0</code></a>
Update libc to v0.2.183</li>
<li><a
href="44d63ee7ba"><code>44d63ee</code></a>
Simplify backlog value for UnixListener</li>
<li><a
href="a87e41ece5"><code>a87e41e</code></a>
Use the same backlog size for TcpListener as std lib</li>
<li><a
href="c1bc4f8981"><code>c1bc4f8</code></a>
Fix the build on minority platforms</li>
<li><a
href="68c315cb80"><code>68c315c</code></a>
Fix FreeBSD by working around a cargo bug</li>
<li><a
href="8b6021f4dd"><code>8b6021f</code></a>
implement AsFd for Registry</li>
<li><a
href="2bb6fca39a"><code>2bb6fca</code></a>
docs: add note about zero timeout for <code>Poll::poll</code></li>
<li>Additional commits viewable in <a
href="https://github.com/tokio-rs/mio/compare/v1.1.1...v1.2.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=mio&package-manager=cargo&previous-version=1.1.1&new-version=1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-30 00:43:45 +00:00
dependabot[bot]
c325b749ef build: bump unicode-segmentation from 1.12.0 to 1.13.2 (#43756)
Bumps
[unicode-segmentation](https://github.com/unicode-rs/unicode-segmentation)
from 1.12.0 to 1.13.2.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d446fa8f00"><code>d446fa8</code></a>
Set explicit 1.84 MSRV, add MSRV CI (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/164">#164</a>)</li>
<li><a
href="cb4972bd25"><code>cb4972b</code></a>
fix: Typos in README (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/161">#161</a>)</li>
<li><a
href="88fac40e75"><code>88fac40</code></a>
Add semver check workflow to GitHub Actions (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/160">#160</a>)</li>
<li><a
href="34ae232659"><code>34ae232</code></a>
Fix accidental breakage</li>
<li><a
href="f7268ccf0c"><code>f7268cc</code></a>
Update changelog and version (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/159">#159</a>)</li>
<li><a
href="abed5f7315"><code>abed5f7</code></a>
Update quickcheck to 1.0 (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/158">#158</a>)</li>
<li><a
href="f6f5f218f9"><code>f6f5f21</code></a>
Release 1.13.0</li>
<li><a
href="13862d8894"><code>13862d8</code></a>
feat: Support Unicode 17.0.0 (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/157">#157</a>)</li>
<li><a
href="1441d3dde8"><code>1441d3d</code></a>
Update Python scripts (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/155">#155</a>)</li>
<li><a
href="63d0234320"><code>63d0234</code></a>
Exclude development scripts from published package (<a
href="https://redirect.github.com/unicode-rs/unicode-segmentation/issues/152">#152</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/unicode-rs/unicode-segmentation/compare/v1.12.0...v1.13.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=unicode-segmentation&package-manager=cargo&previous-version=1.12.0&new-version=1.13.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-30 00:28:54 +00:00
Taym Haddadi
f597231842 indexeddb: make put() overwrite existing SQLite records (#43721)
indexeddb: make put() overwrite existing SQLite records

Testing: more indexeddb test should pass.
Fixes: #43707

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-29 20:38:24 +00:00
Abbas Olanrewaju Sarafa
4b0f1a7c8b devtools: Rename ProcessActor variable names (#43752)
Renamed ProcessActor variable names in root.rs.

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
Signed-off-by: eri <eri@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-29 16:05:07 +00:00
Abbas Olanrewaju Sarafa
5054ca087b devtools: Rename HighlighterActor variable names (#43747)
Renamed HighlighterActor variable names in inspector.rs.

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 16:00:11 +00:00
Abbas Olanrewaju Sarafa
4f71c0cef9 devtools: Rename LayoutInspectorActor variable names (#43748)
Renamed LayoutInspectorActor variable names in walker.rs

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 15:55:50 +00:00
Abbas Olanrewaju Sarafa
5adddd7af4 devtools: Rename PreferenceActor variable names (#43751)
Renamed PreferenceActor variable names in root.rs.

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 14:36:11 +00:00
Abbas Olanrewaju Sarafa
1c7f16b10e devtools: Rename AccessibilityActor variable names (#43740)
Renamed AccessibilityActor variable names in browsing_context

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 14:28:54 +00:00
Abbas Olanrewaju Sarafa
4eb332251f devtools: Rename WatcherActor variable names (#43728)
Renamed WatcherActor variable names in browsing_context,
network_handler, network_event, tab, watcher & lib.rs

Testing: Ran `./mach test-devtools` locally.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 13:06:45 +00:00
Sam
242cec5770 chore: relax mozlog version requirement (#43749)
Having strict versions here prevents WPT imports. Because we resolve our
deps together with WPT deps:
c32b720ca4/pyproject.toml (L9)
we will effectively use pinned version from WPT (which will work in
upgrades).

Testing: None
Fixes:
https://servo.zulipchat.com/#narrow/channel/263398-general/topic/WPT.20import.20failed.20today

Signed-off-by: Sam <16504129+sagudev@users.noreply.github.com>
2026-03-29 11:34:33 +00:00
Abbas Olanrewaju Sarafa
be1468f279 devtools: Rename StyleSheetsActor variable names (#43729)
Renamed StyleSheetsActor variable names in browsing_context

Testing: Ran `./mach test-devtools` locally.
Fixes: Part of #43606

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 10:49:00 +00:00
Abbas Olanrewaju Sarafa
c32b720ca4 devtools: Rename RootActor variable names (#43731)
Renamed RootActor variable names in root, watcher, tab & lib.rs

Testing: No testing required.
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-29 06:49:34 +00:00
Euclid Ye
db719abced script: Add TODO for Computed Role (#43736)
Beginning of #43734.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-29 03:12:34 +00:00
Euclid Ye
209c99198c net: Enable fetch and http_loader unit tests for Windows (#43738)
fetch and http_loader module were completely disabled for Windows. 
I ran them locally for a few rounds, and there's nothing abnormal.

Testing: [Windows Try with
UT](https://github.com/servo/servo/actions/runs/23687830144/job/69010191251)

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-28 21:31:46 +00:00
Martin Robinson
1f6e1d2004 layout: Add support for background-blend-mode (#43666)
This change adds support for `background-blend-mode` to Servo by
creating one stacking context per blend and a single stacking context to
serve as the blend container. This matches the approach that Gecko
takes.

Stylo PR: servo/stylo#344
Testing: This change causes some WPT tests to start passing. In general
this feature
is not well exercised by tests. I suspect that blending is hard to test
properly.
Fixes: #43621

Signed-off-by: Martin Robinson <mrobinson@fastmail.fm>
Co-authored-by: Martin Robinson <mrobinson@fastmail.fm>
2026-03-28 20:52:27 +00:00
Tim van der Lippe
fe5c905760 net: Update reported CSP urls for websockets (#43645)
Per the spec discussion [1], we should report `http(s)` URLs rather than
the original `ws(s)` URLs. The WPT tests are updated to reflect what the
spec says and are reviewed by other browser engineers in the WPT PR.

[1]: https://github.com/w3c/webappsec-csp/issues/735

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-03-28 15:15:40 +00:00
dependabot[bot]
099b8e0b80 build: bump cryptography from 46.0.5 to 46.0.6 (#43735)
Bumps [cryptography](https://github.com/pyca/cryptography) from 46.0.5
to 46.0.6.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pyca/cryptography/blob/main/CHANGELOG.rst">cryptography's
changelog</a>.</em></p>
<blockquote>
<p>46.0.6 - 2026-03-25</p>
<pre><code>
* **SECURITY ISSUE**: Fixed a bug where name constraints were not
applied
  to peer names during verification when the leaf certificate contains a
wildcard DNS SAN. Ordinary X.509 topologies are not affected by this
bug,
including those used by the Web PKI. Credit to **Oleh Konko (1seal)**
for
  reporting the issue. **CVE-2026-34073**
<p>.. _v46-0-5:<br />
</code></pre></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="91d728897b"><code>91d7288</code></a>
Cherry-pick <a
href="https://redirect.github.com/pyca/cryptography/issues/14542">#14542</a>
(<a
href="https://redirect.github.com/pyca/cryptography/issues/14543">#14543</a>)</li>
<li>See full diff in <a
href="https://github.com/pyca/cryptography/compare/46.0.5...46.0.6">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cryptography&package-manager=uv&previous-version=46.0.5&new-version=46.0.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-28 10:35:18 +00:00
Josh Matthews
6526ee532a script: Use result of determining the origin in more cases. (#43732)
We were previously conflating the concept of a navigation request's
origin with the origin of the resulting document. These changes ensure
that the navigation request's origin is based on the navigation
initiator's origin, and the document's origin is not computed until
after the navigation response is received.

The most visible effect of these changes is that documents in sandboxed
iframes now correctly have an opaque origin.

Testing: Lots of new passing tets.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-28 10:03:12 +00:00
Tim van der Lippe
6656061fc3 script: Implement frame-ancestors CSP check (#43630)
Requires communication between the script thread and the constellation
to be able to retrieve the origin of a cross-origin document. However,
in the fast-path where the document resides in the same script-thread,
we use the `frame_element` instead.

If no CSP list is active, then we skip all this logic, to have a minimal
impact on document navigation.

Part of #4577
Fixes #36468

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-03-28 08:54:17 +00:00
Martin Robinson
bc9a86f7bd script: Use the containing node as the activable element for UA widgets (#43722)
UA widgets (such as textual `<input>`) create a shadow DOM to contain
their various parts. When clicking on these parts (such as the text node
of the widget contents), we should use the root node of the widget as
the activable node. This means that wehen you click on the inside of an
`<input>` element, the input matches the `:active` pseudo-selector.

Testing: This improves WPT tests.
Fixes: #41102

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-27 21:38:15 +00:00
Tim van der Lippe
f7876c3db8 script: Pass &mut JSContext to navigate (#43713)
Also move the related `navigate_to_fragment` method next to it.

Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-27 17:11:22 +00:00
Abbas Olanrewaju Sarafa
9dbe608558 devtools: Rename NetworkEventActor variable concerned files (#43675)
Renamed NetworkEventActor variables in network_handler & lib.rs

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-27 14:48:00 +00:00
Martin Robinson
8acfe7ad48 script: Implement AnimationTimeline and DocumentTimeline from Web Animations (#43711)
This is the first step toward implementing the Web Animations
specification. It adds support for the `AnimationTimeline` and
`DocumentTimeline` specification concepts. Note that there was already
an `AnimationTimeline`, but it did not implement the specification.

Testing: Various WPT start to pass or no longer error / timeout.

Signed-off-by: Martin Robinson <mrobinson@abandonedwig.info>
Co-authored-by: Martin Robinson <mrobinson@abandonedwig.info>
2026-03-27 14:26:23 +00:00
Sharan Poojari
6dd427683c script: React correctly to selected attributes changes in for <option> (#43582)
Fixes: #43522

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-27 14:25:54 +00:00
Euclid Ye
f80eab7018 canvas: Don't include text run without string or font when build_unshaped_text_runs (#43717)
As titled. The `Vec<UnshapedTextRun>` produced by `fn
build_unshaped_text_runs`
is only used by `into_shaped_text_run`, which filters out those without
string or font.

It is better to not allocate them in the first place.

Testing: [Try](https://github.com/servo/servo/actions/runs/23642089615).
Added a Servo-specific crash test to ensure we will not have empty
font/string in a text run.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-27 13:54:32 +00:00
Tim van der Lippe
0df9b39af9 script: move element interfaces into element/ (#43714)
It moves `Element.rs` into a subdirectory and turns on dead code
detection (found 4 methods that could be removed). Then it also extracts
the first attribute-related method into a separate file, to reduce the
file size of `Element` and add more structure as part of #43709.

Part of #38901
Part of #43709

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-27 12:59:13 +00:00
Martin Robinson
4c961cdc40 tidy: Run uv with --frozen when running flake8 (#43716)
This prevents unintended updates the `uv.lock` file which must be
reverted locally.

Testing: As this just fixes a runtime issue when running `test-tidy`,
this
probably doesn't deserve a test.

Signed-off-by: Martin Robinson <mrobinson@abandonedwig.info>
Co-authored-by: Martin Robinson <mrobinson@abandonedwig.info>
2026-03-27 12:20:09 +00:00
Luke Warlow
563dd06e52 script: Implement shadow tree for file input (#43498)
script: Implement shadow tree for file input

File inputs also now support ::file-selector-button

Testing: Existing WPTs
Fixes: https://github.com/servo/servo/issues/39565

Stylo PR: https://github.com/servo/stylo/pull/341

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Vasiluță Mihai-Alexandru <alexv@siluta.me>
2026-03-27 12:15:50 +00:00
Tim van der Lippe
442c63e2d9 net: Fix header parsing for empty strings (#43708)
If there are multiple header values and one of them is empty, we should
append the empty string rather than skipping it. The algorithm was
incorrectly advancing the operation and continuing the loop, rather than
appending and later returning the `values`.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-27 09:45:32 +00:00
Babalola Taiwo J
ed8b28b642 script: Merge Window::load_url with ScriptThread::navigate (#43668)
Both `Window::load_url` and `ScriptThread::navigate` implement parts of
the same navigate algorithm from the HTML spec
(https://html.spec.whatwg.org/multipage/browsing-the-web.html#navigate).
`ScriptThread::navigate` had only one caller: `Window::load_url`.

This merges both methods into a single `navigate` function in
`navigation.rs`, which is the appropriate home for navigation logic. All
previous callers of `Window::load_url` now call `navigation::navigate`
directly.

Testing: This is a pure refactor with no behaviour changes, so no new
tests are needed. Existing tests cover the navigation paths affected.
Fixes: #43494

---------

Signed-off-by: thebabalola <t.babalolajoseph@gmail.com>
2026-03-27 08:38:43 +00:00
Abbas Olanrewaju Sarafa
b707a59117 devtools: Rename BrowsingContextActor variable names (#43655)
Renamed BrowsingContext in tab, network_event, watcher actors & lib.rs

Testing: No testing required - only renaming done
Fixes: Part o #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-27 07:20:04 +00:00
elomscansio
7fe875ac36 constellation: Convert constellation's EmbedderProxy to GenericEmbedderProxy (#43646)
Refactor Constellation module to use GenericEmbedderProxy
- [X] create the new enum in components/<component>
- [X] for each use of EmbedderMsg::<something> in
components/<component>, extract that enum variant into the new enum
- [X] replace uses of EmbedderProxy in components/<component> with
GenericEmbedderProxy<<component>ToEmbedderMsg>
- [X] create a new instance of the generic embedder proxy in
[Servo::new](c023d8edc7/components/servo/servo.rs (L755-L756));
store the receiver in a new field in Servo and pass the sender to the
appropriate code that instantiates the component
- [X] add a new variant to the
[Message](c023d8edc7/components/servo/servo.rs (L137))
enum for the new component enum type
- [X] update
[receive_one_message](c023d8edc7/components/servo/servo.rs (L224))
to use the new receiver and return the new enum variant
- [X] extract the code from
[handle_embedder_message](c023d8edc7/components/servo/servo.rs (L345))
that handles the component-specific variants into a new method

Testing: Just a refactor shouldn't need any testing
Fixes: #42097

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
Signed-off-by: elomscansio <163124154+elomscansio@users.noreply.github.com>
Co-authored-by: Mukilan Thiyagarajan <mukilanthiagarajan@gmail.com>
2026-03-27 06:59:50 +00:00
dependabot[bot]
627f2dfe7f build: bump cmake from 0.1.57 to 0.1.58 (#43699)
Bumps [cmake](https://github.com/rust-lang/cmake-rs) from 0.1.57 to
0.1.58.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cmake-rs/releases">cmake's
releases</a>.</em></p>
<blockquote>
<h2>v0.1.58</h2>
<h3>Fixed</h3>
<ul>
<li>Fix i686-windows system import (<a
href="https://redirect.github.com/rust-lang/cmake-rs/pull/276">#276</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cmake-rs/blob/main/CHANGELOG.md">cmake's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/cmake-rs/compare/v0.1.57...v0.1.58">0.1.58</a>
- 2026-03-26</h2>
<h3>Fixed</h3>
<ul>
<li>Fix i686-windows system import (<a
href="https://redirect.github.com/rust-lang/cmake-rs/pull/276">#276</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="6319069719"><code>6319069</code></a>
chore: release v0.1.58 (<a
href="https://redirect.github.com/rust-lang/cmake-rs/issues/269">#269</a>)</li>
<li><a
href="fa894569a9"><code>fa89456</code></a>
Fix i686-windows system import (<a
href="https://redirect.github.com/rust-lang/cmake-rs/issues/276">#276</a>)</li>
<li><a
href="511160ffce"><code>511160f</code></a>
Switch to main (<a
href="https://redirect.github.com/rust-lang/cmake-rs/issues/266">#266</a>)</li>
<li>See full diff in <a
href="https://github.com/rust-lang/cmake-rs/compare/v0.1.57...v0.1.58">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cmake&package-manager=cargo&previous-version=0.1.57&new-version=0.1.58)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-27 01:17:08 +00:00
eri
2ee93de65d devtools: Rework debugger value structure (#43587)
The WebIDLs for values were duplicated in PropertyDescriptor and
EvalResultValue, with duplicated handlers across the code.

General cleanup of how debugger values are passed from debugger.js and
how the conversion from JS and to JSON happens.

There shouldn't be a behaviour change.

Testing: Existing devtools tests and manual testing
Part of: #36027

---------

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-26 20:18:12 +00:00
Abbas Olanrewaju Sarafa
190844378b devtools: Renamed WorkerActor variables in affected files (#43678)
Renamed WorkerActor variables in watcher, console, root and lib.rs

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-26 19:47:37 +00:00
Veer Pratap
235a3577f3 script: Use encoding-parsed URLs in EventSource constructor (#43634)
Fixes #43629.

The `EventSource` constructor was resolving input URLs with
`api_base_url().join(...)`, which is not the same as the HTML spec’s
encoding-parsing step for URLs relative to the relevant settings object.

This change updates `components/script/dom/eventsource.rs` to use
`global.encoding_parse_a_url(&url.str())` when constructing the
`EventSource` request URL. That makes the constructor follow the spec
more
closely while keeping the existing failure behavior of returning
`Error::Syntax(None)` when parsing fails.

Using `GlobalScope::encoding_parse_a_url` also reuses the existing
parsing
path for both window and worker globals, instead of handling
`EventSource`
URL resolution through `api_base_url().join(...)` directly.

Testing:
* Ran ./mach check
* Ran ./mach test-wpt tests/wpt/tests/eventsource/
* Checked relevant coverage under
tests/wpt/tests/html/infrastructure/urls/resolving-urls/query-encoding/

---------

Signed-off-by: veercodeprog <veerpratap945050@gmail.com>
2026-03-26 19:20:55 +00:00
Tim van der Lippe
dd89609429 script: Fire input events when executing commands (#43087)
For any enabled command, we should fire corresponding
beforeinput and input events.

Also update a WPT test to make it clearer what the
expected behavior is. None of the test expect a
beforeinput event. Before, it would fail with
"expected undefined, but got", which is not descriptive
as a failure to what's happening.

We are failing these tests, since this behavior is
currently unspecced and also requires changes in
the input element to work with text edits.

Part of #25005

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-26 18:41:36 +00:00
Tim van der Lippe
f340042c1d script: Pass &mut JSContext to FetchResponseListener::process_response_chunk (#43657)
Fixes #42841

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-26 18:05:24 +00:00
Euclid Ye
12b8f5794b webdriver: Improve error reporting for Cookie Addition (#43690)
Improve the error reporting for [cookie
addition](https://w3c.github.io/webdriver/#add-cookie).
Most notably, when
- expiry time exceeds maximum safe integer
- cookie domain is not equal to session's current browsing context's
active document's domain

There is a bug with spec:
https://github.com/servo/servo/pull/43690#discussion_r2994771111.
We fix spec in https://github.com/w3c/webdriver/pull/1955 and
make sure Servo behaves consistently with other browsers.

Testing: Added one test for invalid expiry time. New passing with
existing.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-26 17:38:30 +00:00
Shubham Gupta
ff69105712 wpt: Enable css-device-adapt tests (#43694)
Add one more directory of tests

Testing: More Tests passing.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-26 15:15:22 +00:00
shuppy
3f746481a2 libservo: Set up graft node in AccessKit trees for webviews (#43556)
in #43029, we defined an accessibility tree for each webview. we create
those trees when accessibility is activated for that webview, then the
embedder can graft it into their main accessibility tree. at the time,
this accessibility tree was empty, but we ultimately want it to contain
the accessibility tree of the documents loaded in the webview at any
given time. to do that, we need to graft the active top-level pipeline’s
accessibility tree into the webview accessibility tree. we should be
able to ignore nested documents inside iframes here, and leave it to
their parent documents to graft those in as part of layout
accessibility.

this patch hooks into the moment in the constellation where we detect
that the top-level document has changed (#43013), and notifies libservo
of the new AccessKit TreeId for the webview-to-pipeline graft node. this
moment covers navigating to a new top-level document and navigating back
or forward, but not the initial document loaded in the webview, so we
also hook into the moment a ConstellationWebView is created, and do the
same for that initial document. now the accessibility tree for a webview
with accessibility activated should look like this:

- embedder’s main tree
  - graft node for webview tree → webview tree
    - ~~graft node for document back in history~~
    - graft node for active top-level document → (nothing yet)
    - ~~graft node for document forward in history~~

Testing: this patch updates the relevant accessibility test in libservo
Fixes: part of #4344, extracted from our work in #42338

---------

Signed-off-by: Alice Boxhall <alice@igalia.com>
Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-03-26 14:48:56 +00:00
CynthiaOketch
9af19158f3 devtools: Show service workers in Firefox DevTools about:debugging (#43659)
This update makes service workers properly show up in DevTools and
behave more like dedicated workers.

- Added an is_service_worker field to DevtoolsPageInfo so the devtools
server can tell service workers apart from dedicated workers
- Triggered a NewGlobal message when a service worker is created in
serviceworker_manager.rs, similar to what already happens for dedicated
workers
- Routed service workers to root.service_workers so they appear under
"Service Workers" in about:debugging instead of "Other Workers"
- Implemented listServiceWorkerRegistrations with the expected response
format (activeWorker, installingWorker, waitingWorker, evaluatingWorker)
to match Firefox’s LegacyServiceWorkersWatcher
- Added support for getPushSubscription in WorkerActor, currently
returning subscription: null
Enabled the service_worker target type in the watcher’s SessionContext
and handled watchTargets("service_worker")

Testing

Start Servo with:

`RUST_LOG="error,devtools=debug" ./mach run --
--pref=dom_serviceworker_enabled --devtools=6080
"https://mdn.github.io/dom-examples/service-worker/simple-service-worker/"
`

In Firefox, go to about:debugging and connect to localhost:6080
Confirm the service worker shows up under "Service Workers"



Fixes #43574

---------

Signed-off-by: CynthiaOketch <cynthiaoketch6@gmail.com>
2026-03-26 13:53:29 +00:00
Luke Warlow
087c50657f script: Refactors HTMLInputElement.rs into type specific files (#43325)
Refactors HTMLInputElement.rs to split lots of type specific input code
into their own files. These SpecificInputTypes are responsible for their
own shadow trees and also for element specific data such as
FileInputType's filelist.

Testing: Covered by WPTs
Fixes: https://github.com/servo/servo/issues/38263
Fixes: https://github.com/servo/servo/issues/43351

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-26 11:59:22 +00:00
Mukilan Thiyagarajan
75d6338825 embedder_traits: Update docs for the public API of input_event module (#43681)
These are mostly formatting changes to make them consistent.

Testing: Not required as there are no code changes.

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-03-26 11:37:24 +00:00
Sayd Mateen
12756512ba devtools: Standardize EnvironmentActor variables (#43679)
Standardize EnvironmentActor variables

Testing: Ran `test-devtools` and all tests passed
Fixes: Part of https://github.com/servo/servo/issues/43606

Signed-off-by: Sayd Mateen <32889475+saydmateen@users.noreply.github.com>
2026-03-26 11:04:03 +00:00
Jayanta Pradhan
302b719ea3 devtools: Rename PageStyleActor variable names (#43684)
Rename page_style in inspector .

Testing: ran `./mach test-devtools`.

Fixes: Part of #43606

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-26 09:45:06 +00:00
Brent Schroeter
c94722d3da devtools: wrap TcpStream to synchronize network operations (#43472)
Introduces a new type `DevtoolsConnection`, which implements the
`JsonPacketStream` trait with proper coordination of I/O across threads.
This replaces the implementation of `JsonPacketStream` for raw
`TcpStream`s, which was susceptible to interleaving writes when cloned
across threads.

`DevtoolsConnection` also defensively synchronizes read operations.
These are less likely to cause issues: in practice actors should never
independently pull incoming messages without centralized coordination.

Testing: No new tests, as interleaving writes are difficult to evoke
deterministically. Removing the `JsonPacketStream` implementation for
`TcpStream` should discourage regressions due to improper use of raw
streams.

---------

Signed-off-by: Brent Schroeter <contact@brentsch.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-26 08:43:04 +00:00
Jambong Ralpher
7e6323595a devtools: Rename DeviceActor variables for consistency (#43676)
Rename `DeviceActor` local variable in `root.rs` from `device` to
`device_actor` for naming consistency across the devtools crate.

This follows the convention discussed in #43557:
- `{}_actor` for variables holding the actor 
- `{}_name` for variables holding the actor name string

The `device_actor` field in the `GlobalActors` struct was not renamed,
as it is part of a `#[derive(Serialize)]` struct used for devtools
message serialization.

Testing: `./mach test-devtools` all 60 tests pass (6 expected failures).
One unrelated flaky test
(`test_breakpoint_at_invalid_entry_point_does_not_crash`) occasionally
fails due to a race condition tracked separately. opened an isssue for
it at #43667
 

fixes part of #43606

Signed-off-by: staysafe020 <jambongralpher@gmail.com>
2026-03-26 08:36:14 +00:00
Abbas Olanrewaju Sarafa
b22ef1eadd devtools: Rename TabDescriptorActor variable names (#43664)
Renamed TabDescriptorActor variable names in browsing_context, root &
target_configuration

Cleaned up a few more names as suggested by eerii

Testing: No testing required
Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-26 08:24:01 +00:00
Euclid Ye
959ab5ad4d wdspec: tagName IDL attribute should be upper case when in html (#43673)
[Spec for
`tagName`](https://dom.spec.whatwg.org/#element-html-uppercased-qualified-name).

The expectation should use upper case here, as the test document is
definitely in HTML:

bc62b7475c/tests/wpt/tests/webdriver/tests/support/fixtures.py (L149)


bc62b7475c/tests/wpt/tests/webdriver/tests/support/inline.py (L33-L34)


Testing: New passing WPT.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-26 08:16:46 +00:00
Jayanta Pradhan
ec782e7264 Devtool: rename NetworkParentActor variable names. (#43672)
Rename NetworkParent  in watcher actors.

Testing: ran `./mach test-devtools`.

Fixes: Part of #43606

---------

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-26 07:42:55 +00:00
Josh Matthews
db3daa4324 script: Align javascript: URL evaluation closer to the spec. (#43496)
The commit contains several related changes:
* iframes that load javascript: URLs as part of the initial insertion
(ie. `<iframe src='javascript:...'>`) get a synchronous load event
dispatched
* javascript: URL evaluation that does not result in a string no longer
treated like a 204 response
* iframes that perform a javascript: URL navigation that does not result
in a new document no longer block the parent document load event

Testing: Lots of new tests passing.
Fixes: #24901

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-26 03:10:38 +00:00
Domenico Rizzo
bc62b7475c webgl: Remove manual Drop implementation for WebGLSampler (#43631)
Moves the cleanup logic to a separate helper struct to comply with the
prohibition of manual `Drop` implementations for DOM types.

Testing: WebGL tests cover these cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-26 02:12:34 +00:00
Tim van der Lippe
a6722b0d1d script: Report CSP violations for child navigations in parent page (#43652)
There were two issues here:
1. We weren't firing the `load` event when we would show an error page
because of a CSP failure. This is to avoid web pages knowing wheter a
page has failed because of CSP.
2. We were reporting the violations in the wrong global. We shouldn't
fire these in the global of the child, but instead in the parent.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-26 02:11:11 +00:00
Jayanta Pradhan
b3329fb764 devtools: Rename console_actor and console in actors (#43644)
Rename console_actor and console in  actors.

Testing: ran `./mach test-devtools`.

Fixes: Part of #43606

---------

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-25 20:36:08 +00:00
Euclid Ye
40d616c01b canvas: Support all Unicode variation selectors in text runs (#43449)
Initially I just want to update the legacy comment, since raqote backend
is gone.

This also enforces other variation selectors properly: see anchor 
below,
which ignored our text selector previously.

Fixes: https://github.com/servo/servo/issues/43448
Fixes: https://github.com/servo/servo/issues/43650
Testing: Added a test that all other browsers pass as well.

| Before | After |
|----------|----------|
| <img width="483" height="211" alt="image"
src="https://github.com/user-attachments/assets/436493bc-ec42-4641-bcf8-c39afac6cfdc"
/> | <img width="461" height="186" alt="image"
src="https://github.com/user-attachments/assets/348375a8-45a4-4fde-aea6-9657cac211d3"
/> |
| <img width="669" height="449" alt="image"
src="https://github.com/user-attachments/assets/c791e840-9791-43b6-9147-1c250ea37721"
/> | <img width="653" height="433" alt="image"
src="https://github.com/user-attachments/assets/4fd06581-ac62-48f1-8135-d3c287e898cf"
/> |

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-25 18:13:57 +00:00
minghuaw
13029a9deb font: Filter out downloaded web fonts before starting to download another web font (#43382)
Checks the web font sources and filter out the ones that are already
downloaded in the `FontContext` before starting to load new ones

Testing: Existing WPT tests.

---------

Signed-off-by: Minghua Wu <michael.wu1107@gmail.com>
2026-03-25 17:59:15 +00:00
webbeef
f38c7308b0 servo: Add a BluetoothDeviceSelectionRequest to the API for selecting Bluetooth devices (#43580)
This change has 2 parts:
- adding `BluetoothPickDeviceRequest`, similar to other request structs
used to communicate with the embedder.
- switch from a `Vec<String>` that expected 2 * <device count> strings
to `Vec<BluetoothDeviceDescription>` which is easier to reason about.

Testing: Manual testing with a build that has the `native-bluetooth`
feature enabled.

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-03-25 17:45:07 +00:00
Jayanta Pradhan
c698be8306 script: move node interfaces into node/. (#43662)
Moves node interfaces into script/dom/node/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing.
Fixes: Part of #38901

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-25 17:39:28 +00:00
Abubakar Abdulazeez Usman
0d0b392565 devtools: Rename ReflowActor variables in browsing context actor (#43656)
Renamed ReflowActor in browsing_context actor.

Testing: `./mach test-devtools`, All test passed.
Fixes: Part of #43606

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-03-25 16:09:11 +00:00
Jambong Ralpher
f4c8a39697 Add README for the servo crate (#43654)
Add `readme` field to libservo's Cargo.toml, pointing to the repository
root
README via `../../README.md`. This ensures the crates.io page displays
content
when the crate is published, as Cargo copies the referenced file into
the
package during `cargo publish`.

Testing: This change only adds a metadata field to Cargo.toml and does
not
affect build output or runtime behavior. No tests are required.
fixes #43143

Signed-off-by: staysafe020 <jambongralpher@gmail.com>
2026-03-25 14:27:57 +00:00
elomscansio
5e19c83bd6 script: Move event DOM interfaces to script/dom/event/ (#43651)
Moves interfaces defined by the event spec to the script/dom/event/
module from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially https://github.com/servo/servo/issues/38901

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-25 13:36:55 +00:00
elomscansio
14faaaf093 script: Move resizeobserver DOM interfaces to script/dom/resizeobserver/ (#43647)
Moves interfaces defined by the resizeobserver spec to the
script/dom/resizeobserver/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially https://github.com/servo/servo/issues/38901

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-25 10:56:57 +00:00
Messi II Innocent R.
1e901934b5 paint: Enable WebRender dithering to reduce gradient color banding (#43603)
Enable WebRender gradient dithering to reduce color banding

WebRender has a built-in dithering system for gradients that applies a
small amount of ordered noise to RGB channels before the framebuffer
quantizes to 8-bit.

The dithering was already fully implemented in WebRender (shader
support, dither texture, feature flag) but was disabled by default
(enable_dithering: false in WebRenderOptions).

Testing: Tested manually with the reproduction case from the issue (40
stacked divs with `linear-gradient(rgba(90, 138, 100, 0.04) 0%,
transparent 60%)`). Before the change, Servo showed harsh horizontal
bands. After the change, the gradient renders smoothly, matching Firefox
and Chrome behavior.

Fixes: #43568

<img width="740" height="471" alt="Screenshot from 2026-03-24 04-42-42"
src="https://github.com/user-attachments/assets/0caea525-e5d9-46a7-817d-2b420246f19c"
/>

---------

Signed-off-by: Messi002 <rostandmessi2@gmail.com>
2026-03-25 09:41:21 +00:00
Abbas Olanrewaju Sarafa
4820941cab devtools: Refactored ActorRegistry variables in lib.rs (#43623)
Refactored the lib.rs file to replace ``actors``` & ```self.actors```
variables with ```registry``` and ```self.registry```

No testing required, compiles successfully.

Part o the #43605

---------

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-25 08:02:34 +00:00
niya
d29ef8dcd0 layout: Display generated content for ::marker (#43515)
Implements a fix for #43036

- Renders content for `::marker`
- If content is not present render marker_image/marker_string

Here's a small webpage I wrote to test if my implementation works :) 

<img width="1136" height="880" alt="Screenshot 2026-03-21 at 4 50 43 PM"
src="https://github.com/user-attachments/assets/91ccbfd9-2c18-446d-bac5-d559f483b08c"
/>

# Testing
The existing WPT ones should be sufficient, the tests need to be
updated.


## (WPT) Stable Unexpected Results that are failing:

| Test  | Issue  | Remark |
|--------|--------|--------|
| /css/css-lists/marker-dynamic-content-change.html | #43120 | |
| /css/css-lists/marker-quotes.html | #30365 | Test File: Ordered List
showing '0' for all `li` |
| /css/css-pseudo/marker-content-001.html | #30365 | Ref file: Ordered
List showing '0' for all `li` |
| /css/css-pseudo/marker-content-001b.html | #30365 | Ref file: Ordered
List showing '0' for all `li` |
| /css/css-pseudo/marker-content-001c.html | #30365 | Ref file: Ordered
List showing '0' for all `li` |
| /css/css-pseudo/marker-content-020.html | | Test File: JavaScript
dynamically toggles the `no-marker` class, but it doesn't update the DOM
when called from inside `addEventListener()` and
`requestAnimationFrame()` functions. |
| /css/selectors/has-style-sharing-pseudo-007.html | #25133 | Test file
uses `has` to remove `content` from a `li`; `has` pseudo-class has not
been implemented yet |
| /css/selectors/has-style-sharing-pseudo-008.html | #25133 | Test file
uses `has` to remove `content` from a `li`; `has` pseudo-class has not
been implemented yet |

---------

Signed-off-by: Niya Gupta <niyabits@gmail.com>
Signed-off-by: niya <niyabits@gmail.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-25 07:24:05 +00:00
Abbas Olanrewaju Sarafa
02a2d45c30 devtools: Renamed BrowsingContext in inspector & its actors (#43642)
Renamed BrowsingContext in inspector, highlighter, page_style,
style_rule & walker actors

Testing: No testing required.

Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-25 06:36:07 +00:00
dependabot[bot]
ae7cc557e5 build: bump libredox from 0.1.14 to 0.1.15 (#43635)
Bumps libredox from 0.1.14 to 0.1.15.


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libredox&package-manager=cargo&previous-version=0.1.14&new-version=0.1.15)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-25 06:34:13 +00:00
Abbas Olanrewaju Sarafa
0d2b91a9d1 devtools: Rename registry in source, node, & network_handler (#43619)
Renamed actors to registry in source, node, & network_handler.

Testing: No tests were required, however compilation was successful
Part of #43605

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-25 06:33:53 +00:00
dependabot[bot]
19cd6026c7 build: bump zerocopy from 0.8.42 to 0.8.47 (#43636)
Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.42 to
0.8.47.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google/zerocopy/releases">zerocopy's
releases</a>.</em></p>
<blockquote>
<h2>v0.8.47</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>Change ref_from_bytes() to inline(always). by <a
href="https://github.com/korran"><code>@​korran</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3137">google/zerocopy#3137</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.46...v0.8.47">https://github.com/google/zerocopy/compare/v0.8.46...v0.8.47</a></p>
<h2>v0.8.46</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>[codegen] Document and test <code>IntoBytes</code> by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3109">google/zerocopy#3109</a></li>
<li>[codegen] Test and document codegen for <code>SplitAt</code> and
<code>Split</code> by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3111">google/zerocopy#3111</a></li>
<li>[test] Fix mis-run UI tests by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3134">google/zerocopy#3134</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.45...v0.8.46">https://github.com/google/zerocopy/compare/v0.8.45...v0.8.46</a></p>
<h2>v0.8.46-alpha.3</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>[ci] When releasing, don't dry-run zerocopy publish by <a
href="https://github.com/joshlf"><code>@​joshlf</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3126">google/zerocopy#3126</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.46-alpha.2...v0.8.46-alpha.3">https://github.com/google/zerocopy/compare/v0.8.46-alpha.2...v0.8.46-alpha.3</a></p>
<h2>v0.8.46-alpha.2</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>[ci] In releasing script, pass <code>--allow-dirty</code> by <a
href="https://github.com/joshlf"><code>@​joshlf</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3125">google/zerocopy#3125</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.46-alpha.1...v0.8.46-alpha.2">https://github.com/google/zerocopy/compare/v0.8.46-alpha.1...v0.8.46-alpha.2</a></p>
<h2>v0.8.46-alpha.1</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>[ci] Bypass vendoring during publication by <a
href="https://github.com/joshlf"><code>@​joshlf</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3124">google/zerocopy#3124</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.46-alpha...v0.8.46-alpha.1">https://github.com/google/zerocopy/compare/v0.8.46-alpha...v0.8.46-alpha.1</a></p>
<h2>v0.8.46-alpha</h2>
<!-- raw HTML omitted -->
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="a6a530d0b0"><code>a6a530d</code></a>
Release 0.8.47 (<a
href="https://redirect.github.com/google/zerocopy/issues/3138">#3138</a>)</li>
<li><a
href="d6d67bfa47"><code>d6d67bf</code></a>
Change ref_from_bytes() to inline(always). (<a
href="https://redirect.github.com/google/zerocopy/issues/3137">#3137</a>)</li>
<li><a
href="e38763fcad"><code>e38763f</code></a>
Release 0.8.46 (<a
href="https://redirect.github.com/google/zerocopy/issues/3136">#3136</a>)</li>
<li><a
href="f5c1f58f6d"><code>f5c1f58</code></a>
[test] Fix mis-run UI tests (<a
href="https://redirect.github.com/google/zerocopy/issues/3134">#3134</a>)</li>
<li><a
href="c2bdaa5ddf"><code>c2bdaa5</code></a>
ci: update step-security/harden-runner to v2.16.0 (<a
href="https://redirect.github.com/google/zerocopy/issues/3135">#3135</a>)</li>
<li><a
href="e4f2484590"><code>e4f2484</code></a>
[codegen] Test and document codegen for <code>SplitAt</code> and
<code>Split</code> (<a
href="https://redirect.github.com/google/zerocopy/issues/3111">#3111</a>)</li>
<li><a
href="0c4f843882"><code>0c4f843</code></a>
[codegen] Document and test <code>IntoBytes</code> (<a
href="https://redirect.github.com/google/zerocopy/issues/3109">#3109</a>)</li>
<li><a
href="13024e9877"><code>13024e9</code></a>
[ci] Re-enable zizmor (<a
href="https://redirect.github.com/google/zerocopy/issues/3119">#3119</a>)</li>
<li><a
href="52311da31d"><code>52311da</code></a>
[codegen] Use <code>cargo.sh +nightly</code> (<a
href="https://redirect.github.com/google/zerocopy/issues/3131">#3131</a>)</li>
<li><a
href="d8124807fc"><code>d812480</code></a>
[ci] Update <code>auto-approve.yml</code> to play nicely with CI (<a
href="https://redirect.github.com/google/zerocopy/issues/3130">#3130</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/google/zerocopy/compare/v0.8.42...v0.8.47">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zerocopy&package-manager=cargo&previous-version=0.8.42&new-version=0.8.47)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-25 06:33:28 +00:00
Luke Warlow
04fb115a6d script: Implement HTMLMarqueeElement type (#43610)
This adds the WebIDl and implementation for the HTMLMarqueeElement type.

The `<marquee>` HTML is now assigned this type.

None of the contained properties or methods are implemented yet.

Testing: Existing WPTs

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-25 06:31:16 +00:00
Jonathan Schwender
dfd2aee2f2 Re-enable sccache for the mac-arm64 workflow (#43628)
This partially reverts 017b12a627. The
intermittent issues should be resolved now.

./mach build --release results in ~3GiB of sccache size locally. Since
we build multiple configurations (with crown, tests, profiles) we will
easily hit the 10GiB cache limit even with just one architecture. Hence,
it doesn't make sense to add sccache to more workflows, at least not
before we decide to buy more cache or not.
This should hopefully make the macos-arm64 workflows faster. Locally the
speed-up on clean builds is significant.

Testing: [mach try (no existing
cache)](https://github.com/jschwe/servo/actions/runs/23507308462/job/68418624068),
[mach try
#2](https://github.com/jschwe/servo/actions/runs/23508733572/job/68423715413)
- i.e. 34 minutes vs. 19 minutes total runtime, and 30 m vs 15 m build
time (with ideal conditions for the caching)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-25 06:30:34 +00:00
Oriol Brufau
80c57f80d4 layout: Fix justify-self: auto on block-in-inline (#43625)
We were resolving `justify-self: auto` according to the `justify-items`
of the containing block. However, the CSSWG resolved to instead use the
parent box; and if the parent is an inline box, then `justify-items`
doesn't apply, so `justify-self: auto` behaves as `normal`.

Testing: Adding WPT test
Fixes: #43624

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-25 06:05:03 +00:00
Euclid Ye
2f5e3fdb5c cargo: Rename workspace-local library starting with c to servo_* (#43622)
- canvas 
- constellation_traits
- canvas_traits
- constellation

Testing: This should not change any behaviour.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-25 06:04:57 +00:00
Abbas Olanrewaju Sarafa
9e2d033047 devtools: Renamed BrowsingContext in breakpoint, console & thread actors (#43641)
Renamed BrowsingContext in breakpoint, console & thread actors

Testing: No testing required.

Fixes: Part of #43606

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-25 05:33:29 +00:00
Jonathan Schwender
e095bc4cef deps: Update mozjs to 0.15.7 (#43618)
This mainly includes:

- https://github.com/servo/mozjs/pull/717
- https://github.com/servo/mozjs/pull/725

Testing: Covered by existing tests.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-24 16:28:44 +00:00
Abbas Olanrewaju Sarafa
beafb08ae8 devtools: Rename registry in tab, watcher and browsing_context (#43614)
Renamed `actors` to `registry` in `actors/tab.rs`, `actors/watcher.rs`
and `actors/browsing_context.rs`.

Testing: No tests were required, however compilation was successful
Part of: #43605

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-24 16:20:11 +00:00
Jayanta Pradhan
0e7ca88c24 script: Move url interfaces into url/ (#43612)
Moves url interfaces into script/dom/url/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing.
Part of #38901

---------

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-24 16:06:17 +00:00
elomscansio
2bc868788f script: Move datatransfer DOM interfaces to script/dom/datatransfer/ (#43609)
Moves interfaces defined by the datatransfer spec to the
script/dom/datatransfer/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially #38901

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-24 15:46:38 +00:00
Jayanta Pradhan
ae33e48cb8 script: Move xpath interfaces into xpath/ (#43616)
Moves xpath interfaces into script/dom/xpath/ module from script/dom/.

Testing: Just a refactor.
Fixes: Part of #38901

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-24 15:22:48 +00:00
Euclid Ye
32cce8e6de cargo: Rename workspace-local dependencies starting with c to servo-* (#43615)
Also reorders alphabetically for the corresponding user .toml.

Similar to #43526.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-24 15:10:38 +00:00
Abbas Olanrewaju Sarafa
ae4a5b8de5 script: Use encoding-parse algorithm in Worker::Constructor (#43588)
Updated api base url to encoding_parse_a_url and wrote tests referencing
the suggested format

Fixes: #43557 
Testing: new passing test

Signed-off-by: Sabb <sarafaabbas@gmail.com>
2026-03-24 14:32:26 +00:00
Oriol Brufau
62b2eefc7c layout: Allow block-levels inside an inline directly, without wrapper (#43586)
When encountering a block-level inside an inline box, we would wrap it
(together with other block-level siblings, if any) inside an anonymous
block box.

That was complicating the logic for no real benefit, so just get rid of
these anonymous wrappers, and allow block-levels as direct children of
inlines.

This aligns Servo with WebKit, which did the same refactoring:
https://commits.webkit.org/304357@main

Blink still generates these wrappers, but its design doc acknowledges
that "the anonymous box is not strictly required".

Testing: No existing test fails. But note that, while minimal, this may
have some observable implications. For example, as an accidental
side-effect of #41492, Servo aligned with the CSSWG resolution in
https://github.com/w3c/csswg-drafts/issues/11462, but now we will revert
to the previous behavior. I will address it in a follow-up, and add a
test.

Fixes: #41636

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-24 14:31:42 +00:00
elomscansio
7e97e82008 script: Move document DOM interfaces to script/dom/document/ (#43602)
Moves interfaces defined by the document spec to the
script/dom/document/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially #38901

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-24 14:29:07 +00:00
elomscansio
fc29fea5e1 script: Move file DOM interfaces to script/dom/file/ (#43607)
Moves interfaces defined by the file spec to the script/dom/file/ module
from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially #38901

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-24 13:15:16 +00:00
Oriol Brufau
7c1401fff8 script: Add preshints for width and height attributes of <svg> (#43583)
Lets the `width` and `height` attributes of `<svg>` set presentational
hints for the CSS properties of the same name.

Also bumps Stylo to servo/stylo#343, in order to also set the preshints
for percentage values. However, layout will ignore percentages for the
purpose of computing the natural sizes and aspect ratio.

Testing: Improves WPT

---------

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-24 09:29:03 +00:00
elomscansio
36a5885086 script: Move Clipboard DOM interfaces to script/dom/clipboard/ (#43597)
Moves interfaces defined by the clipboard spec to the
script/dom/clipboard/ module from script/dom/.

Testing: Just a refactor shouldn't need any testing
Fixes: Partially #38901

---------

Signed-off-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-24 08:58:07 +00:00
minghuaw
75a56e567b layout: Do not trigger dirty_all_nodes when web font loading fails (#43595)
Currently, the `web_font_finished_loading_callback` sends a
`ScriptThreadMessage::WebFontLoaded` message regardless of whether web
font loading succeeds or not, which leads to dirtying all nodes in
`script_thread.rs`. This creates unnecessary reflow. This PR removes the
boolean field from the `WebFontLoaded` message and only sends the
message when the web font loading is successful.

Testing: Existing WPT tests

Signed-off-by: Minghua Wu <michael.wu1107@gmail.com>
2026-03-24 08:03:30 +00:00
Gae24
113b06f2ee script: Correctly setup request for worker module scripts (#43585)
According to spec we should fetch worker modules using the _outside
settings_, however we can't use it directly since we are on a different
thread. To fix it, a new struct `ModuleFetchClient` is now part of
`LoadState` and replace the `with_global_scope` call done in
`fetch_a_single_module_script`.
This also tidy worker classic script related code.

Testing: There are new passes

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-24 05:28:27 +00:00
dependabot[bot]
ebbe5de656 build: bump quick_cache from 0.6.20 to 0.6.21 (#43593)
Bumps [quick_cache](https://github.com/arthurprs/quick-cache) from
0.6.20 to 0.6.21.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/arthurprs/quick-cache/releases">quick_cache's
releases</a>.</em></p>
<blockquote>
<h2>v0.6.21</h2>
<h2>What's Changed</h2>
<ul>
<li>Add a crossbeam sharded rwlock backend by <a
href="https://github.com/gz"><code>@​gz</code></a> in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/110">arthurprs/quick-cache#110</a></li>
<li>Rename <code>crossbeam</code> feature to <code>sharded-lock</code>
by <a href="https://github.com/arthurprs"><code>@​arthurprs</code></a>
in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/111">arthurprs/quick-cache#111</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/gz"><code>@​gz</code></a> made their
first contribution in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/110">arthurprs/quick-cache#110</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.20...v0.6.21">https://github.com/arthurprs/quick-cache/compare/v0.6.20...v0.6.21</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="6b8a5be25a"><code>6b8a5be</code></a>
0.6.21</li>
<li><a
href="84bc22295a"><code>84bc222</code></a>
Rename <code>crossbeam</code> feature to <code>sharded-lock</code> (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/111">#111</a>)</li>
<li><a
href="752b3b44e7"><code>752b3b4</code></a>
Add a crossbeam sharded rwlock backend (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/110">#110</a>)</li>
<li>See full diff in <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.20...v0.6.21">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quick_cache&package-manager=cargo&previous-version=0.6.20&new-version=0.6.21)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-24 00:49:53 +00:00
dependabot[bot]
c992661533 build: bump itoa from 1.0.17 to 1.0.18 (#43591)
Bumps [itoa](https://github.com/dtolnay/itoa) from 1.0.17 to 1.0.18.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/dtolnay/itoa/releases">itoa's
releases</a>.</em></p>
<blockquote>
<h2>1.0.18</h2>
<ul>
<li>Simplify pointer usage in Buffer::format method (<a
href="https://redirect.github.com/dtolnay/itoa/issues/67">#67</a>,
thanks <a
href="https://github.com/xtqqczze"><code>@​xtqqczze</code></a>)</li>
<li>Optimize 128-bit integer formatting (<a
href="https://redirect.github.com/dtolnay/itoa/issues/68">#68</a>,
thanks <a
href="https://github.com/jhpratt"><code>@​jhpratt</code></a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="af77385d0d"><code>af77385</code></a>
Release 1.0.18</li>
<li><a
href="73a7c03e23"><code>73a7c03</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/itoa/issues/68">#68</a> from
jhpratt/master</li>
<li><a
href="7b4c86b03e"><code>7b4c86b</code></a>
Optimize 128-bit integer formatting</li>
<li><a
href="0d8a4899bf"><code>0d8a489</code></a>
Fill in pointer cast type</li>
<li><a
href="e693c49e60"><code>e693c49</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/itoa/issues/67">#67</a> from
xtqqczze/as_mut_ptr</li>
<li><a
href="29b34100d5"><code>29b3410</code></a>
Simplify pointer usage in Buffer::format method</li>
<li><a
href="bbf077faeb"><code>bbf077f</code></a>
Switch to 9975WX benchmark data</li>
<li><a
href="65bc721a0d"><code>65bc721</code></a>
Delete old chart code</li>
<li>See full diff in <a
href="https://github.com/dtolnay/itoa/compare/1.0.17...1.0.18">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=itoa&package-manager=cargo&previous-version=1.0.17&new-version=1.0.18)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-24 00:38:07 +00:00
dependabot[bot]
5605f3f36a build: bump jni-sys from 0.3.0 to 0.3.1 (#43590)
Bumps [jni-sys](https://github.com/jni-rs/jni-sys) from 0.3.0 to 0.3.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/jni-rs/jni-sys/releases">jni-sys's
releases</a>.</em></p>
<blockquote>
<h2>v0.3.1</h2>
<p>This release applies the <a
href="https://github.com/dtolnay/semver-trick">semver trick</a> to
re-export compatible types from <code>jni-sys 0.4</code> (namely
<code>jobject</code>) to make it easier for <code>jobject</code>
references to be passed around between APIs depending on different
versions of <code>jni-sys</code></p>
<p>The MSRV was bumped to 1.77</p>
<h2>What's Changed</h2>
<h3>Added</h3>
<ul>
<li>GetModule was added to <code>JNINativeInterface</code> (<a
href="https://redirect.github.com/jni-rs/jni-sys/pull/22">#22</a>)</li>
<li><code>JNI_VERSION_{9,10,19,20,21,24}</code> version definitions were
added</li>
</ul>
<h3>Changed</h3>
<ul>
<li>Compatible types are now re-exported from <code>jni-sys 0.4</code>
to make it easier for <code>jobject</code> references
to be passed around between APIs depending on different versions of
<code>jni-sys</code></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/jni-rs/jni-sys/compare/v0.3.0...v0.3.1">https://github.com/jni-rs/jni-sys/compare/v0.3.0...v0.3.1</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/jni-rs/jni-sys/blob/v0.3.1/CHANGELOG.md">jni-sys's
changelog</a>.</em></p>
<blockquote>
<h2>[0.3.1] - 2026-03-22</h2>
<h3>Added</h3>
<ul>
<li>GetModule was added to <code>JNINativeInterface</code> (<a
href="https://redirect.github.com/jni-rs/jni-sys/pull/22">#22</a>)</li>
<li><code>JNI_VERSION_{9,10,19,20,21,24}</code> version definitions were
added</li>
</ul>
<h3>Changed</h3>
<ul>
<li>Compatible types are now re-exported from <code>jni-sys 0.4</code>
to make it easier for <code>jobject</code> references
to be passed around between APIs depending on different versions of
<code>jni-sys</code></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="1985e8bdd0"><code>1985e8b</code></a>
Release v0.3.1</li>
<li><a
href="0a512a07ec"><code>0a512a0</code></a>
Add .vscode/ to .gitignore</li>
<li><a
href="a77b608cd0"><code>a77b608</code></a>
Add minimal test for invocation API + JNI</li>
<li><a
href="df992c4a78"><code>df992c4</code></a>
remove systest</li>
<li><a
href="0e7f6b8d7c"><code>0e7f6b8</code></a>
Use semver trick to re-export compatible types from jni-sys 0.4</li>
<li><a
href="be20758a9c"><code>be20758</code></a>
systest: update to ctest 0.5</li>
<li><a
href="1f539f53c2"><code>1f539f5</code></a>
Systest build fix for darwin/linux</li>
<li><a
href="4caf07d5c5"><code>4caf07d</code></a>
Add JNI_VERSION_24</li>
<li><a
href="e75db1c2e0"><code>e75db1c</code></a>
Use SPDX license format</li>
<li><a
href="34245b2b0b"><code>34245b2</code></a>
Update Readme</li>
<li>Additional commits viewable in <a
href="https://github.com/jni-rs/jni-sys/compare/v0.3.0...v0.3.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=jni-sys&package-manager=cargo&previous-version=0.3.0&new-version=0.3.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-24 00:30:27 +00:00
Jayanta Pradhan
29fb865a00 script: Pass down &mut JSContext to CookieStore methods (#43584)
Move CookieStore methods from CanGc to &mut JSContext.

Testing:  Just refactor.
Fixes: Part of #42638

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-23 23:44:37 +00:00
Jayanta Pradhan
166a9ddd85 script: Pass down &mut JSContext to CSSGroupingRule methods (#43579)
Move `CSSGroupingRule` methods from `CanGc` to `&mut JSContext`.

Testing:  Just refactor.
Fixes: Part of  #42638

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-23 21:19:28 +00:00
webbeef
7bdc40a1f6 bluetooth: unbreak native-bluetooth builds (#43581)
Fixes build errors when the `native-bluetooth` feature is enable:

```
error[E0308]: mismatched types
  --> components/bluetooth/bluetooth.rs:91:9
   |
90 |     pub async fn is_connected(&self) -> Result<bool, Box<dyn Error>> {
   |                                         ---------------------------- expected `Result<bool, Box<(dyn StdError + 'static)>>` because of return type
91 |         self.peripheral.is_connected().await.map_err(Box::new)
   |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Result<bool, Box<dyn Error>>`, found `Result<bool, Box<Error>>`
   |
   = note: expected enum `Result<_, Box<(dyn StdError + 'static)>>`
              found enum `Result<_, Box<btleplug::Error>>`
   = help: `btleplug::Error` implements `Error` so you could box the found value and coerce it to the trait object `Box<dyn Error>`, you will have to change the expected type as well
help: use `?` to coerce and return an appropriate `Err`, and wrap the resulting value in `Ok` so the expression remains of type `Result`
   |
91 |         Ok(self.peripheral.is_connected().await.map_err(Box::new)?)
   |         +++                                                      ++

```

Testing: `./mach build --features native-bluetooth` doesn't fail.

Signed-off-by: webbeef <me@webbeef.org>
2026-03-23 21:18:49 +00:00
Oriol Brufau
41a50106eb layout: Stretch replaced elements with aspect ratio but no natural sizes (#42666)
Instead of using the default object width of 300px, use the inline-axis
stretch size, or zero when computing the intrinsic contribution.

Note browsers don't completely agree in the details of how to do this.
This implements a behavior very similar to Blink, but without having
different behaviors for min/max-content depending on which property they
are used (which doesn't make much sense to me).

The biggest part of the patch is for block-level boxes that establish an
independent formatting context and need to avoid overlapping floats. In
that case we may need to try laying out multiple times, varying the
stretch size. Previously the code assumed that this wouldn't affect the
intrinsic inline sizes, but now we have this dependency, so the logic
had to be refactored.

Testing: Some tests pass. One test results in an error, but that happens
in all browsers.
Fixes: #38653

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-23 19:30:53 +00:00
Jonathan Schwender
64afd05d11 servoshell: Remove --userscripts option (#43573)
In #43182 it was [suggested to remove the
userscripts](https://github.com/servo/servo/pull/43182#issuecomment-4048383093)
option, since embedders can use the (new) `UserContentManager` API
instead.

Testing: This removes a commandline flag from servoshell. Existing tests
passing is sufficient.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-23 18:39:57 +00:00
eri
0ee2b03b40 devtools: Remove double optional from WebIDL (#43567)
Some values of the WebIDL were wrapped two types in nullable (from not
having `required` and having a `?`). Simplify that so we don't get
`Option<Option<...>>`.

Testing: Existing tests
Part of: #36027 
Depends on: #43566

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-23 18:15:49 +00:00
Vinayak Sharma
d47711e849 layout: Fix static position of abspos nested within a block-in-inline (#43084)
Fixes incorrect static positioning of absolutely positioned elements
nested within a block that has `margin-top` inside an inline element.
Added two lines of code to `AnonymousBlockBox::layout_into_line_items`
in components/layout/flow/inline/mod.rs:
- We snapshot the current positioning_context_length before laying out
the block.
- We call `adjust_static_position_of_hoisted_fragments` on the
positioning_context after the block fragment is placed by the state.

Testing: 
Tested the fix using the manual reproduction HTML provided in the issue,
Also ran the existing WPT tests in `tests/wpt/tests/css/css-position/`
to ensure there are no regressions.


Fixes: #42890

---------

Signed-off-by: vinayak sharma <vinayaks0111@gmail.com>
Signed-off-by: Oriol Brufau <obrufau@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-23 17:27:44 +00:00
webbeef
ae78fbb03a bluetooth: switch to btleplug (#43529)
btleplug depends on tokio so we use a bridge thread to interface with
Servo thread based messaging.
We keep feature parity except for BtleplugGATTService::get_includes()
that will require upstream implementation.
In terms of OS support, I verified on Linux and MacOS. Android is
untested, but btleplug claims support.


Testing: No test failures, green try run at
https://github.com/webbeef/servo/actions/runs/23390850825
Fixes: #43254.

Signed-off-by: webbeef <me@webbeef.org>
2026-03-23 17:01:24 +00:00
Abubakar Abdulazeez Usman
c3723affc2 script: Pass &mut JSContext to CSSStyleRule::Style (#43569)
Move `CSSStyleRule::Style` from `CanGc` to `&mut JSContext`. Also fix
the caller in `devtools.rs` to pass `cx` directly.

Testing: Refactoring, It compiles.
Fixes: Part of #42638

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-03-23 17:00:23 +00:00
Simon Wülker
1b2a1d8da4 script: Align URL::CanParse and URL::Parse more directly with the specification (#43576)
Testing: This should not change existing behaviour and these methods are
covered by existing tests

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-23 16:52:21 +00:00
Asset Malik
9efe13e003 ci: Track RAM usage in scenarios tests (#43313)
Plotting RAM usage on `etc/ci/scenario` OHOS scenarios

I've did a class that can be optionally added into scenarios to records
RAM usage on ohos platform by using the `hdc` tool to checkout
`/proc/{pid}/status` and can store the recorded data into `.csv` or plot
as `.png`

The tool can also be used on its own 
```
UV_PROJECT=etc/ci/scenario uv run etc/ci/scenario/memory_usage_plotter.py -h 
```

Testing: 
```
UV_PROJECT=etc/ci/scenario uv run etc/ci/scenario/servo_test_slide.py
```

Example output:
<img width="1500" height="750" alt="memory_usage_plotter"
src="https://github.com/user-attachments/assets/27e85787-51df-4c6b-8ad7-c6fcfc380304"
/>

---------

Signed-off-by: jane <5373400+janeoa@users.noreply.github.com>
Signed-off-by: janeoa <5373400+janeoa@users.noreply.github.com>
2026-03-23 15:47:36 +00:00
eri
de4a79facf devtools: Rename PropertyPreview to PropertyDescriptor (#43566)
Rename `PropertyPreview` to `PropertyDescriptor`

Testing: Internal refactor
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-23 15:27:44 +00:00
Domenico Rizzo
95aa798b2f webgl: Remove manual Drop implementation for WebGLRenderbuffer (#43563)
Moves the cleanup logic to a separate helper struct to comply with the
prohibition of manual `Drop` implementations for DOM types.

Testing: WebGL tests just cover its cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-23 14:47:13 +00:00
Sharan Poojari
20e11deb96 devtools: Handle service worker eval (#43492)
This completes the service-worker side while addressing earlier panic
concerns by avoiding unconditional unwrap/expect paths.

Testing: No dedicated tests were added for this change.

Fixes: #43317

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-23 14:18:25 +00:00
Sharan Poojari
34583dc66f script: Use encoding-parse algorithm when handling iframe and Document URL attributes (#43572)
This PR fixes iframe URL parsing to use document encoding, so non-UTF-8
pages reflect iframe.src correctly, and adds a WPT test for it.

Testing: added Test file 
Fixes: #43559

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-23 13:48:11 +00:00
Eyüp Can Akman
1422d2a850 script: Add error messages in HMAC WebCrypto operations (#43560)
Replace all `Error::*(None)` instances in `hmac_operation.rs` with
descriptive error messages, covering sign, verify, generate_key,
import_key, and export_key operations.

Testing: Existing WPT tests cover all HMAC operations and check error
types, not message strings. No behavioral change.
Fixes: Part of #40756

---------

Signed-off-by: Eyüp Can Akman <eyupcanakman@gmail.com>
2026-03-23 13:29:17 +00:00
Abubakar Abdulazeez Usman
dae0edb5b9 script: Pass &mut JSContext to CSSKeyframesRule methods (#43571)
Move `CSSKeyframesRule` methods (`CssRules`, `AppendRule`, `DeleteRule`,
`FindRule`) from `CanGc` to `&mut JSContext`.

Testing: It compiles.
Fixes: Part of #42638

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-03-23 12:19:44 +00:00
Abubakar Abdulazeez Usman
f78ca1cef4 script: Pass &mut JSContext to CSSNestedDeclarations::Style (#43570)
Move `CSSNestedDeclarations::Style` from `CanGc` to `&mut JSContext`.

Testing: It compiles.
Fixes: Part of #42638

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-03-23 11:37:34 +00:00
Mukilan Thiyagarajan
351f3d7849 embedder_traits: Add more documentation to public API. (#43564)
Testing: No code changes, so testing is not required.

Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
2026-03-23 11:07:55 +00:00
Shubham Gupta
70e1547771 script: Suppress unused import warning related to gamepad in navigator.rs (#43513)
Just adds some imports under gamepad cfg flag.

Testing: Successful compilation is enough to verify the change.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-23 08:41:35 +00:00
rtjkro
afa4b524ab font: Consider lang attribute when shaping (#43447)
Fonts: Added `language` field in the struct `ShapingOptions` so Harfbuzz
can also consider language when shaping glyphs.

Testing: Existing WPT. Most recent try run:
[link](https://github.com/RichardTjokroutomo/servo/actions/runs/23334049878)

2 new passes, 5 new fails.

Failures:
- `/css/css-text-decor/text-emphasis-punctuation-2.html` should be a
false positive since `text-emphasis` shorthand hasn't been supported on
stylo yet.
- Not quite sure about this, but
`/css/css-text/text-spacing-trim/text-spacing-trim-quote-001.html?class=halt,htb&amp;lang=ja`
tests `text-spacing-trim` default behavior on `JA` texts. Since this
property is not defined in Stylo, I believe that this property's
behavior (including default) hasn't been considered in Servo. So Servo
previously passing the test should be a false positive. As a side note,
this test also fails on Firefox.
- `/html/canvas/element/manual/text/canvas.2d.lang.dynamic.html`,
`/html/canvas/element/manual/text/canvas.2d.lang.html`,
`/html/canvas/element/manual/text/canvas.2d.lang.inherit.disconnected.canvas.html`
fail because canvas' experimental [`lang`
attribute](https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/lang)
hasn't been supported yet.

credits to @mrobinson for figuring out the reason for last 3 failing WPT
tests!

Fixes: #41825

---------

Signed-off-by: Richard Tjokroutomo <richard.tjokro2@gmail.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-23 08:39:53 +00:00
mishop-15
7a4d3e636b script: Migrate from utf_8 crate to encoding_rs in EventSource (#42179)
Migrate from `utf_8` to `encoding_rs` in `EventSource`. The `utf_8`
crate is archived and unmaintained. We already use `encoding_rs`, so it
makes sense to switch.

Testing: A new WPT test
(`tests/wpt/meta/eventsource/format-bom.any.js.ini`) is now passing.
Fixes: #42094.

Signed-off-by: mishop-15 <tanaybhutada03@gmail.com>
2026-03-23 08:30:49 +00:00
Euclid Ye
cae0752676 cargo: Rename workspace-local library starting with b to servo_* (#43552)
Follow up of #43526. This addresses Nico's comment:
https://github.com/servo/servo/pull/43526#issuecomment-4104953308

- `bluetooth_traits` -> `servo_bluetooth_traits`
- `base` -> `servo_base`
- `bluetooth` -> `servo_bluetooth`
- `background_hang_monitor` -> `servo_background_hang_monitor`

Testing: This should not change any behaviour.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-23 08:26:49 +00:00
Narfinger
cf0676fd26 net: Close the control stream of RequestBody to fix resource leak (#42474)
For a network fetch, the body chunk request sender keeps being alive as
long as the request is alive. This leads to a big resource leak as this
keeps a couple of IpcChannels and SharedMemory around. These would only
be cleaned up when the Gc cleans up the Request which can be too long
for tight fetch loops.

This gives a method to destroy the channel at the end of the complete
fetch (keeping in mind redirects). Currently we have to do this by hand
as a simple guard structure did not work correctly.

Additionally, this renames `RequestBody::take_stream` to the correct
clone_stream and cleans up some smaller names and documentation.

Testing: WPT should catch anything that is not spec conform.
Fixes: https://github.com/servo/servo/issues/41202

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
Co-authored-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-23 08:26:00 +00:00
Euclid Ye
ca898ea99c paint: Propogate input event dispatch failure to Servo to resolve deadlock (#43381)
`dispatch_input_event_with_hit_testing` already returns a `bool` to
indicate whether the dispatch failed.
However, for some reason this was used nowhere. When it fails, embedder
is not informed.
This is fine for embedder as right now it only handles keyboard
shortcuts for headed window,
but a disaster for WebDriver as it is synchornously waiting for the
feedback.

Testing: Several tests no longer CRASH.
Fixes: #43379

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-23 06:46:21 +00:00
Kingsley Yung
23f78a06c7 script: Implement TurboSHAKE algorithm in WebCrypto (#43551)
Implement TurboSHAKE algorithm in our WebCrypto API. This includes a
WebIDL dictionary `TurboSHAKE` and the "digest" operation of TurboSHAKE.

Specification: https://wicg.github.io/webcrypto-modern-algos/#turboshake
Testing: Pass TurboSHAKE-related WPT tests.
Fixes: Part of #40687

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-23 06:22:46 +00:00
Josh Matthews
fa5e7bffdd wpt: Add test for form action encoding. (#43554)
Verified that this test fails before #43521 and passes after it, and
matches behaviour of other browsers.

Testing: Adds a new test.
Part of #43507

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-23 06:21:08 +00:00
Tim van der Lippe
01a29209b2 script: Implement support for X-Frame-Options (#43539)
We now check for this header and corresponding logic. The WPT tests
mostly pass, but rely on the `contentDocument` of the iframe to be
`null`. This is not something we did before, which means that iframes
were able to access the contents of error pages.

Instead, we now mark the document as internal with an opaque origin
according to the spec [1]. We shouldn't do this post-fact, but is
required since we first need to construct the document and enter its
realm, before we determine that it is an invalid document.

Fixes #16103

[1]:
https://html.spec.whatwg.org/multipage/document-lifecycle.html#navigate-ua-inline

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-23 06:14:27 +00:00
Shubham Gupta
047e3210d7 layout: Consider iframe for first-paint (#42149)
`iframe` should be considered for `first-paint`. 

TODO of: #42975
Synced: https://github.com/web-platform-tests/wpt/pull/58243
Refer for some history: #42498

Testing: 

- `wpt/paint-timing/first-paint-only/child-painting-first-image.html`
- `wpt/paint-timing/first-paint-only/sibling-painting-first-image.html`

Fixes: #42455

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-23 06:07:09 +00:00
Jayanta Pradhan
ebfdaff63f script: Use encoding-parsing algorithm in XMLHttpRequest::Open (#43537)
Add a new method to components/script/dom/globalscope.rs which checks if
the global is a Window , then uses
window.Document().encoding_parse_a_url(..) if so. For non-Window
globals, just use the existing logic of getting the api_base_url() value
and calling join(..) on it.

Testing: Existing WPTs.
Fixes: #43509

---------

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-23 03:18:24 +00:00
Abubakar Abdulazeez Usman
6c7fcd41bd script: Pass &mut JSContext to CSSKeyframeRule::Style (#43549)
Move `CSSKeyframeRule::Style` from `CanGc` to `&mut JSContext`.

Testing: Just a refactor, Existing tests suffice.
Fixes: Part of #42638

Signed-off-by: arabson99 <arabiusman99@gmail.com>
2026-03-23 02:54:31 +00:00
dependabot[bot]
d44f2da4e2 build: bump arc-swap from 1.8.2 to 1.9.0 (#43548)
Bumps [arc-swap](https://github.com/vorner/arc-swap) from 1.8.2 to
1.9.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/vorner/arc-swap/blob/master/CHANGELOG.md">arc-swap's
changelog</a>.</em></p>
<blockquote>
<h1>1.9.0</h1>
<ul>
<li>Promote certain orderings to SeqCst. Original proofs based on wrong
reading of
standard :-(. Expect some performance degradation (<a
href="https://redirect.github.com/vorner/arc-swap/issues/198">#198</a>,
<a
href="https://redirect.github.com/vorner/arc-swap/issues/200">#200</a>).</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="873fbf2e72"><code>873fbf2</code></a>
Test file for the <a
href="https://redirect.github.com/vorner/arc-swap/issues/198">#198</a></li>
<li><a
href="ffb2808f59"><code>ffb2808</code></a>
Release of 1.9.0</li>
<li><a
href="9d87160c32"><code>9d87160</code></a>
Promote several Orderings to SeqCst</li>
<li>See full diff in <a
href="https://github.com/vorner/arc-swap/compare/v1.8.2...v1.9.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=arc-swap&package-manager=cargo&previous-version=1.8.2&new-version=1.9.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 00:52:32 +00:00
dependabot[bot]
86e60b744c build: bump the tungstenite-related group with 2 updates (#43546)
Bumps the tungstenite-related group with 2 updates:
[async-tungstenite](https://github.com/sdroege/async-tungstenite) and
[tungstenite](https://github.com/snapview/tungstenite-rs).

Updates `async-tungstenite` from 0.33.0 to 0.34.0
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/sdroege/async-tungstenite/blob/main/CHANGELOG.md">async-tungstenite's
changelog</a>.</em></p>
<blockquote>
<h2>[0.34.0] - 2026-03-20</h2>
<h3>Changed</h3>
<ul>
<li>Update to tungstenite 0.29.</li>
<li>Update to async-native-tls 0.6.</li>
</ul>
<h3>Added</h3>
<ul>
<li>smol runtime support including smol-native-tls.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f37ab0a072"><code>f37ab0a</code></a>
Update CHANGELOG.md for 0.34.0</li>
<li><a
href="b62b375515"><code>b62b375</code></a>
Update version to 0.34.0</li>
<li><a
href="e7612f41f5"><code>e7612f4</code></a>
Update to async-native-tls 0.6</li>
<li><a
href="2b81693011"><code>2b81693</code></a>
Update dev-dependencies.</li>
<li><a
href="c6bdd383f3"><code>c6bdd38</code></a>
Update tungstenite to 0.29.</li>
<li><a
href="f88c3ef099"><code>f88c3ef</code></a>
ci: Add smol-runtime tests</li>
<li><a
href="4e760cdd20"><code>4e760cd</code></a>
examples: Add smol echo example</li>
<li><a
href="da5e725dc9"><code>da5e725</code></a>
runtimes: Add smol runtime support</li>
<li>See full diff in <a
href="https://github.com/sdroege/async-tungstenite/compare/0.33.0...0.34.0">compare
view</a></li>
</ul>
</details>
<br />

Updates `tungstenite` from 0.28.0 to 0.29.0
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/snapview/tungstenite-rs/blob/master/CHANGELOG.md">tungstenite's
changelog</a>.</em></p>
<blockquote>
<h1>0.29.0</h1>
<ul>
<li>Update MSRV to <code>1.71</code> due to <code>syn</code> (the
dependency of <code>thiserror</code>) requiring it.</li>
<li>Allow users to send headers with non-visible ASCII values (as long
as they constitute a correct <code>HeaderValue</code>).</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="c2921718b7"><code>c292171</code></a>
Suppress clippy warnings in tests/</li>
<li><a
href="0938f1c79b"><code>0938f1c</code></a>
Bump version</li>
<li><a
href="4a457f65d9"><code>4a457f6</code></a>
Add missing word to the comment (<a
href="https://redirect.github.com/snapview/tungstenite-rs/issues/521">#521</a>)</li>
<li><a
href="aef32231f5"><code>aef3223</code></a>
Fix grammar in <code>WebSocketContext::from_partially_read</code> docs
(<a
href="https://redirect.github.com/snapview/tungstenite-rs/issues/534">#534</a>)</li>
<li><a
href="ad6539bcb9"><code>ad6539b</code></a>
Inline the utf-8 crate (<a
href="https://redirect.github.com/snapview/tungstenite-rs/issues/536">#536</a>)</li>
<li><a
href="df722bd668"><code>df722bd</code></a>
Update the CI to accomodate for the new MSRV</li>
<li><a
href="9833bdec33"><code>9833bde</code></a>
Bump MSRV</li>
<li><a
href="59bee6404f"><code>59bee64</code></a>
Fix formatting in CHANGELOG.md</li>
<li><a
href="3f2f222cd8"><code>3f2f222</code></a>
Update CHANGELOG.md</li>
<li><a
href="84eaba964d"><code>84eaba9</code></a>
Fixing issue with non-ASCII header values</li>
<li>Additional commits viewable in <a
href="https://github.com/snapview/tungstenite-rs/compare/v0.28.0...v0.29.0">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-23 00:23:01 +00:00
Charlie Tonneslan
f655eee527 Fix typo: occured -> occurred in error comments (#43545)
Two comment typos in indexeddb.rs and generic_channelset.rs. Skipped the
`independant` function name in layout.rs since renaming it would be
breaking.

Signed-off-by: Charlie Tonneslan <cst0520@gmail.com>
2026-03-22 22:36:55 +00:00
Philipp Albrecht
2f1b7f0f84 Pass &mut JSContext (#43543)
This is follow-up of #41459.

We replace some of these:

```rust
let mut cx = unsafe { script_bindings::script_runtime::temp_cx() };
```

..by passing a `cx: &mut JSContext` instead.

---

Testing: existing WPT tests  
Fixes: #43453

Signed-off-by: pylbrecht <pylbrecht@mailbox.org>
2026-03-22 20:58:05 +00:00
Domenico Rizzo
1e514bcfe9 webgl: Remove manual Drop implementation for WebGLQuery (#43544)
Moves the cleanup logic to a separate helper struct to comply with the
prohibition of manual `Drop` implementations for DOM types.

Testing: WebGL tests just cover its parts
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-22 20:33:35 +00:00
Kelechi Ebiri
a63a00936f remove referrer field from ScriptFetchOptions (#43532)
Remove `referrer` field from `ScriptFetchOptions` and pass it directly
to `script_fetch_request`.

This keeps ScriptFetchOptions aligned with the HTML 
fixes #42875

---------

Signed-off-by: Kelechi Ebiri <ebiritg@gmail.com>
2026-03-22 16:41:29 +00:00
Sharan Poojari
9cbdf9d8b1 Gate picker on trusted click (#43485)
Fixes: #43360 
This PR makes `<select>` behave like other browsers by only opening the
picker for trusted user clicks, and adds a regression test to ensure
synthetic `.click()/dispatchEvent('click')` won’t open it.

---------

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-22 12:18:20 +00:00
Euclid Ye
317e5ee7de cargo: Rename Workspace-local dependencies starting with b to servo-* (#43526)
Also reorders alphabetically for the corresponding user .toml.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-22 11:19:21 +00:00
Tim van der Lippe
7b9b75c545 script: Fix current URL for CSP requests (#43438)
The CSP crate was incorrectly using the request URL for both checking if
policies were matching, as well as reporting that URL. However, the CSP
specification uses the current URL to check for policies and the url for
reporting a violation.

Therefore, set the new current_url field for these requests, leaving the
ws scheme URLs as a special case. We also should take redirects into
account for navigations (which is only relevant for forms), but LoadData
currently has no notion of keeping track of that.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-22 11:12:22 +00:00
Gae24
5152632f04 script_bindings: Pass &mut JSContext to CustomElementReaction::invoke (#43535)
Pass `&mut JSContext` to `CustomElementReaction::invoke` and
`upgrade_element` algorithm.

Testing: A successful build is enough
Part of #40600

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-22 11:11:52 +00:00
Kingsley Yung
dcca7b2030 script: Rename length parameter of cSHAKE to outputLength (#43533)
Modern Algorithms in WebCrypto API specification was updated to rename
the `length` parameter of the `CShakeParams` dictionary to
`outputLength`. We update our implementation accordingly.

Specification update:
41434899e8
WPT update:
0acea989ac

The final step of the "digest" operation of cSHAKE was also updated to
clarify that it outputs a byte sequence, rather than a bit sequence.
This matches our current implementation. No change in our implementation
is needed. The specification text in our code is updated.

Specification update:
5dd19e3a9f

Testing: Pass updated WPT tests.

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-22 06:28:53 +00:00
Jayanta Pradhan
5ba6636555 script: add navigation and traversal task source (#43523)
script: Add navigation and traversal task source

Testing: This shouldn't be something that's observable through tests, so
a successful build is enough to verify the change.
Fixes: #43497

---------

Signed-off-by: Jayanta Pradhan <pradhanjayanta91@gmail.com>
2026-03-22 05:39:42 +00:00
Servo WPT Sync
3971ba4164 Sync WPT with upstream (22-03-2026) (#43531)
Automated downstream sync of changes from upstream as of 22-03-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
2026-03-22 01:33:18 +00:00
Gae24
1626450063 script: Propagate &mut JSContext from GlobalScope::start_message_port to stream code (#43525)
Pass `&mut JSContext` to more stream related code.

Testing: A successful build is enough.
Part of #42347

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-21 21:07:47 +00:00
Sharan Poojari
5af76f6a23 Use encoding-parse for form action (#43521)
Parse form action URLs using the document's encoding-aware URL parser.

Testing: Verified with the WPT form-action tests `./mach test-wpt
tests/wpt/tests/html/semantics/forms/the-form-element`, all relevant
tests passed.

Fixes: #43507

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-21 16:18:40 +00:00
Shubham Gupta
ea8d93d740 script: Remove unused LayoutDom from gpucanvascontext.rs (#43514)
Remove unused `LayoutDom`

Testing: Successful Compilation is enough to verify the change.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-21 15:47:00 +00:00
Josh Matthews
5f247392be script: Move navigation origin logic into a method with spec steps. (#43491)
This pulls one bit of navigation logic out into a method that is easier
to cross-reference against the spec, and drops a bunch of custom logic
that is better served by the existing LoadOrigin infrastructure.

Testing: Existing WPT coverage is sufficient.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-21 12:26:35 +00:00
Shubham Gupta
bcff95fd32 servo: No longer call show_webview_and_wait_for_rendering_to_be_ready in PerformancePaintTiming unit tests (#43495)
Instead of calling `show_webview_and_wait_for_rendering_to_be_ready`,
run `requestAnimationFrame` on JavaScript.

1. Because `show_webview_and_wait_for_rendering_to_be_ready` changes the
`backgroundColor` which deceives the whole purpose of verifying the
`first-paint`.
2. Running `requestAnimationFrame` requests browser to update an
animation before the next repaint.


Testing: `servo/tests/performance_paint_timing.rs`
Fixes: #43484

Test | Run Summary
-|-
test_default_pref_with_unset_background |<img width="1280" height="141"
alt="Screenshot 2026-03-21 at 5 33 13 PM"
src="https://github.com/user-attachments/assets/481b635d-aa4b-4f62-beb7-02f77a256a50"
/>
test_non_default_pref_with_unset_background | <img width="1280"
height="163" alt="Screenshot 2026-03-21 at 5 34 43 PM"
src="https://github.com/user-attachments/assets/2db5cd43-af54-4241-8fd5-ba781c73469c"
/>
test_default_pref_with_transparent_background | <img width="1280"
height="163" alt="Screenshot 2026-03-21 at 5 35 23 PM"
src="https://github.com/user-attachments/assets/6e7d9efb-352a-4d39-894d-37681b14eb11"
/>
test_non_default_pref_with_transparent_background | <img width="1280"
height="163" alt="Screenshot 2026-03-21 at 5 37 13 PM"
src="https://github.com/user-attachments/assets/64975e7b-8e67-4ce7-af3e-6977f4c123ac"
/>
test_default_pref_with_background | <img width="1280" height="137"
alt="Screenshot 2026-03-21 at 5 37 54 PM"
src="https://github.com/user-attachments/assets/8684a20d-6695-4977-adee-7f0c436dee2c"
/>
test_non_default_pref_with_background | <img width="1280" height="137"
alt="Screenshot 2026-03-21 at 5 38 30 PM"
src="https://github.com/user-attachments/assets/781f5f70-72a7-40a2-8ae6-11acf5eb8abf"
/>
test_non_default_pref_with_same_background | <img width="1280"
height="164" alt="Screenshot 2026-03-21 at 5 39 05 PM"
src="https://github.com/user-attachments/assets/07012ba4-c2a2-41fe-be04-1b625abbfb1e"
/>

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-21 12:22:22 +00:00
Martin Robinson
ce1d27337a layout: Improve the rendering of the <marquee> element (#43520)
The change makes it so that `<marquee>` elements render more like the do
in Chrome. The text will not animate, but likewise it does not wrap and
the element will stretch to fill the inline space in its containing
block.

Testing: This change adds a Servo-specific appearance test. This
essentially
just replicates the user agent style of `<marquee>`. It's quite
difficult to
write tests for appearance. Some WPT tests start to pass, but

`/html/obsolete/requirements-for-implementations/the-marquee-element-0/marquee-min-intrinsic-size.html`
starts to fail. This is due to the fact that though the `<marquee>`
style
is improved, we do not yet correctly handle the minimum intrinsic size
properly.
Fixes: #43517

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-21 12:07:20 +00:00
Luke Warlow
09b0cfce8e script: Add longdesc reflection to HTMLIFrameElement and HTMLFrameElement (#43518)
script: Add longdesc reflection to HTMLIFrameElement and
HTMLFrameElement

Also corrects the reflection for HTMLImageElement to use USVString.

Testing: Covered by WPTs

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-21 11:46:16 +00:00
Jerens Lensun
4199e050d9 script: add a check for a valid key path on idb object store (#42451)
Add a check for a valid key path when create index on idb object store

Testing: `./mach test-wpt
tests/wpt/tests/IndexedDB/keypath_invalid.any.js`
Fixes: #42434

---------

Signed-off-by: Jerens Lensun <jerensslensun@gmail.com>
2026-03-21 11:44:23 +00:00
Kingsley Yung
c23d888863 script: Rework on dictionary conversion in SubtleCrypto (#43519)
Our existing `SubtleCrypto::normalize_algorithm` implementation converts
the input dictionary from a JavaScript object to a Rust struct twice.
The first conversion (Step 2 to 4) under WebIDL dictionary `Algorithm`
is for retrieving the `name` property to determine the desired
dictionary type, and the second conversion (Step 9 to 10) is for
retrieving the whole dictionary of desired WebIDL dictionary type.

If the `name` property of the input dictionary is a JavaScript getter
method, the getter will be triggered twice and leads to some undesired
side effects. For example, WPT contains some tests that the `name`
property is a getter method which transfers a buffer source. Triggering
it twice leads to a TypeError of accessing detached buffer at the second
time. Those tests then fail.


5bb4f9f103/tests/wpt/tests/WebCryptoAPI/digest/cshake.tentative.https.any.js (L215-L219)

This patch includes two changes to fix this problem.

First, the algorithm name retrieved in Step 2 to 4 is now passed to
`Op::RegisteredAlgorithm::from_object` in Step 9 to 10 so that we don't
need to read the `name` property and trigger the getter method again.

Second, we no longer use `dictionary_from_jsval` for converting the
dictionary, since it reads the whole dictionary including the `name`
property, triggering the getter method again. Instead, we add some
custom helper functions (`get_optional_parameter`,
`get_required_parameter`, `get_optional_parameter_in_box`,
`get_required_parameter_in_box`, `get_optional_buffer_source`,
`get_required_buffer_source`) to manually read properties other the
`name` property one by one, in a way that matches the specification.

Hence, each property of the input dictionary will only be read once, to
avoid this issue.

Testing: Pass some WPT tests that were expected to fail.

---------

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-21 11:02:58 +00:00
Euclid Ye
e573557554 cargo: Use kebab case consistenly for those already starting with servo- (#43516)
Continues what @jschwe has been doing.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-21 10:57:22 +00:00
Luke Warlow
ac1c86fea7 script: Add usemap reflection to HTMLInputElement and HTMLObjectElement (#43502)
script: Add usemap reflection to HTMLInputElement and HTMLObjectElement

Testing: Covered by WPTs

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-21 09:54:32 +00:00
Luke Warlow
f06e67c031 script: Add hreflang, type and charset reflection to HTMLAnchorElement (#43499)
script: Add hreflang, type and charset reflection to HTMLAnchorElement

Testing: Covered by WPTs

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-21 08:23:54 +00:00
Luke Warlow
74640b7719 script: Add nohref reflection to HTMLAreaElement (#43500)
script: Add nohref reflection to HTMLAreaElement

Testing: Covered by WPTs

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-21 08:00:48 +00:00
Rogerkoranteng
cfaaad4b66 script: Fix panic in crypto.getRandomValues when random generation fails (#43501)
## Summary

Fixes #43328

When `OsRng.try_fill_bytes` fails in `crypto.getRandomValues`, the code
previously returned `Error::JSFailed`. This error type asserts that a
JavaScript exception is already pending on the context — but `OsRng` is
a Rust library that never sets a JS exception, causing Servo to panic
with `assertion failed: JS_IsExceptionPending(*cx)`.

This PR replaces `Error::JSFailed` with `Error::Operation`, which throws
a proper `OperationError` DOMException instead of crashing. This is
consistent with how Servo's SubtleCrypto handles the same scenario
(e.g., `ed25519_operation.rs`).

## Testing

Tested by unconditionally taking the error branch (`if true`):

**Before (panic):**

<img width="960" alt="Screenshot From 2026-03-20 23-42-35"
src="https://github.com/user-attachments/assets/f15150ce-aa26-46c9-a381-985e6d850904"
/>

---


**After (fix):**

<img width="960" alt="Screenshot From 2026-03-20 23-43-05"
src="https://github.com/user-attachments/assets/99490b06-aeaa-4dcc-b10a-56336efad87d"
/>

Signed-off-by: rogerkorantenng <rogerkorantenng@gmail.com>
2026-03-21 07:18:04 +00:00
Euclid Ye
f254841246 base: Move generic_channel.rs into subfolder; Micro-optimize format! (#43503)
Its siblings already live in that folder. Should not leave it alone.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-21 03:57:22 +00:00
Euclid Ye
096f90f1d3 ci: Unblock ci by upgrade rustls-webpki which fixes GHSA-pwjx-qhcg-rvj4 (#43504)
Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-21 03:03:09 +00:00
Shubham Gupta
5c4cc11172 script: Remove unused ImageKey from gpucanvascontext.rs (#43493)
Remove unused ImageKey

Testing: Successful Compilation is enough to verify the change.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-20 18:51:55 +00:00
Simon Wülker
3039f1a70b style: Don't skip animations that have no keyframes (#43454)
Companion PR for https://github.com/servo/stylo/pull/336

Testing: This fixes a bunch of timeouts

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-20 18:44:11 +00:00
Josh Matthews
c166fec94a script: Do not record associated memory for Promises, and release associated memory for WindowProxy. (#43487)
This fixes two assertions observed in Servo using debug mozjs builds:
* `Assertion failure: !IsInsideNursery(obj)` for every promise object
reflected into Rust code
* `Missing calls to JS::RemoveAssociatedMemory` when shutting down the
browser

Testing: Verified locally that WPT tests can run to completion in debug
mozjs builds, but we don't run those on CI.
Fixes: #43486

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-20 17:08:32 +00:00
Tim van der Lippe
8f699b1f17 script: Pass &mut JSContext to submit_timing_data (#43479)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-20 15:31:46 +00:00
Tim van der Lippe
0336c8084b script: Set correct referrer for CSP violations (#43483)
The spec has explicit steps for it, where we were calling a different
algorithm before. This passes more assertions in
`content-security-policy/securitypolicyviolation/securitypolicyviolation-block-image.sub.html`
but since line numbers aren't correct, the test isn't fully passing yet.

Testing: WPT

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-20 15:05:58 +00:00
Tim van der Lippe
1933769eb2 script: Pass &mut JSContext to devtools (#43480)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-20 13:53:27 +00:00
Abdelrahman Hossam
76e1a09082 script: Implement the scrollend event (#38773)
This change implements the `scrollend` event. Since there is no support
for asynchronous / smooth scrolling, with this change all `scroll`
events simply send a `scrollend` event in a way that looks a bit like
what the specification says. Note that there are currently some serious
issues (w3c/csswg-drafts#8396) with specification, so things are still a
bit weird overall.

In addition, this organizes and reduces duplication in some of the
existing scroll event code.

Testing: This causes some WPT tests to start passing or to stop timing
out.

---------

Signed-off-by: abdelrahman1234567 <abdelrahman.hossameldin.awadalla@huawei.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: abdelrahman1234567 <abdelrahman.hossameldin.awadalla@huawei.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-20 13:50:59 +00:00
Gae24
74ac696b69 config: add a preference to allow fetching modulepreload descendants (#43353)
As suggested
[here](https://github.com/servo/servo/pull/42964#issuecomment-4073998452),
adds a preference to enable fetching modulepreload descendants, turned
off by default.

Testing: A successful build is enough.

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-20 12:56:29 +00:00
Tim van der Lippe
dc9e442b17 script: Pass &mut JSContext to Location (#43481)
Part of #42638

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-20 12:54:38 +00:00
Narfinger
ffae45327c script: Use UnrootedSimpleNodeIterator in delete_cell_or_row (#43476)
This uses UnrootedSimpleNodeIterator in a couple of places, namely
- delete_cell_or_row
- children_changed
- move_fn

More importantly this implements upcast and downcast for `UnrootedDom`.
These methods work the same as the DomRoot methods except that they
carry the no_gc and, hence,
keep the lifetime.

Testing: WPT tests will see if this breaks something.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-20 12:52:17 +00:00
Narfinger
7f8f9834c8 script: Fix borrow hazard in script_modules (#43470)
Fix the borrow hazard by simply taking the option and inserting it
again.

Testing: This is a refactor and crown does not complain so it should be
fine.
Fixes: https://github.com/servo/servo/issues/43377

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
Co-authored-by: Josh Matthews <josh@joshmatthews.net>
2026-03-20 10:57:15 +00:00
Tim van der Lippe
3d4cfa4718 net: Remove process_request_eof (#43477)
This is no longer present in the spec. Instead, the
`process_request_body` is the new way. These two
methods were called right after each other and there was only 1
implementation in `htmlvideoelement`. That implementation is now moved
to `process_request_body` and hence we can remove the unnecessary
method.

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-20 10:51:33 +00:00
Gae24
e0fc0174fa script: Propagate &mut JSContext inside global_scope_script_execution.rs (#43473)
Pass `&mut JSContext` to `HTMLScriptElement::execute`, propagate it
inside `global_scope_script_execution.rs` and then switch to wrappers2
bindings.

Testing: A successful build is enough.
Part of #40600

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-20 10:51:33 +00:00
Nishant-k-sagar
2ca02dfa4c cleanup: Remove unused GlobalScope argument from call_pull_algorithm (#43471)
This PR involves cleaning up the unused GlobalScope argument in
UnderlyingSourceContainer::call_pull_algorithm. This PR involves changes
across three files. Only removing the unused GlobalScope and suppressed
reference with underscore prefix.

Testing: This PR involves cleanup of the unused GlobalScope argument in
UnderlyingSourceContainer::call_pull_algorithm. The argument was
suppressed using underscore earlier. Thus it was not involved in any
runtime instances. Thus this PR does not require additional testing. I
was able to successfully build the repo after changes. There is no other
dependency of removed variable, thus no impact outside.

Fixes: #43460

Signed-off-by: Nishant-k-sagar <147799872+Nishant-k-sagar@users.noreply.github.com>
2026-03-20 10:13:06 +00:00
atbrakhi
2d3900317a devtools: Implement initial support for ArrayPreviewer (#43456)
Previously arrays were falling back to Object previewer which was
showing indices as properties- which was not correct. This PR implements
dedicated `ArrayPreviewer` that follows Firefox's `ArrayLike` pattern.
Currently array preview support only length display, it does not
implement showing array items yet.

Now(Correct and follows Firefox pattern, Array items coming in a
follow-up PR):
<img width="510" height="167" alt="image"
src="https://github.com/user-attachments/assets/a51f04d4-333c-4d7c-8159-18121c967670"
/>


Before(We shouldn't see these values- it's incorrect):
<img width="1294" height="721" alt="image"
src="https://github.com/user-attachments/assets/2218a622-c791-4436-958e-1a5553de7864"
/>




Testing: Current tests are passing.
Fixes: Part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-20 08:10:37 +00:00
dependabot[bot]
eae2cd812b build: bump aws-lc-rs from 1.16.1 to 1.16.2 (#43467)
Bumps [aws-lc-rs](https://github.com/aws/aws-lc-rs) from 1.16.1 to
1.16.2.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/aws/aws-lc-rs/releases">aws-lc-rs's
releases</a>.</em></p>
<blockquote>
<h2>aws-lc-rs v1.16.2</h2>
<h2>What's Changed</h2>
<ul>
<li>Implement HMAC <code>sign_to_buffer</code> by <a
href="https://github.com/fabrice102"><code>@​fabrice102</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1058">aws/aws-lc-rs#1058</a></li>
<li>Fix <code>PublicEncryptingKey::from_der</code> to reject undersized
RSA keys by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1065">aws/aws-lc-rs#1065</a>
<ul>
<li><code>from_der()</code> now correctly enforces the 2048-bit minimum
key size, consistent with <code>PrivateDecryptingKey::from_pkcs8</code>.
Users loading &lt;2048-bit public keys for encryption will now receive
<code>KeyRejected</code>.</li>
</ul>
</li>
<li>Update licensing of <code>aws-lc-sys</code> to reflect third-party
component licenses by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1062">aws/aws-lc-rs#1062</a></li>
<li>Improved <code>dev-tests-only</code> documentation and <a
href="https://docs.rs/aws-lc-rs/latest/aws_lc_rs/">docs.rs</a> rendering
by <a href="https://github.com/justsmth"><code>@​justsmth</code></a> in
<a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1054">aws/aws-lc-rs#1054</a></li>
</ul>
<h3>Build Improvements</h3>
<ul>
<li>Fix jitterentropy build failure caused by <code>cc</code> crate
CFLAGS handling change by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1064">aws/aws-lc-rs#1064</a></li>
<li>Unify sys-crate build scripts by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/995">aws/aws-lc-rs#995</a></li>
</ul>
<h3>Issues Being Closed</h3>
<ul>
<li>sys: license of s2n-bignum and fiat-crypto not reflected &amp;
license texts partially missing -- <a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1044">aws/aws-lc-rs#1044</a></li>
<li>Deterministic key agreement for testing -- <a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1020">aws/aws-lc-rs#1020</a></li>
</ul>
<h2>Other Merged PRs</h2>
<ul>
<li>Prepare aws-lc-fips-sys v0.13.13 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1066">aws/aws-lc-rs#1066</a></li>
<li>Prepare aws-lc-sys v0.39.0 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1067">aws/aws-lc-rs#1067</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/fabrice102"><code>@​fabrice102</code></a> made
their first contribution in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1058">aws/aws-lc-rs#1058</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.1...v1.16.2">https://github.com/aws/aws-lc-rs/compare/v1.16.1...v1.16.2</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="1f8a0602f5"><code>1f8a060</code></a>
Prepare aws-lc-sys v0.39.0 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1067">#1067</a>)</li>
<li><a
href="0553c46a0e"><code>0553c46</code></a>
Prepare aws-lc-fips-sys v0.13.13 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1066">#1066</a>)</li>
<li><a
href="80dfe876a7"><code>80dfe87</code></a>
Validate RSA-key size (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1065">#1065</a>)</li>
<li><a
href="3f4dca4442"><code>3f4dca4</code></a>
Fix jitterentropy build failure caused by <code>cc</code> crate CFLAGS
handling change (...</li>
<li><a
href="b60cc41529"><code>b60cc41</code></a>
Implement HMAC <code>sign_to_buffer</code> (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1058">#1058</a>)</li>
<li><a
href="6996ba65a3"><code>6996ba6</code></a>
Update licensing (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1062">#1062</a>)</li>
<li><a
href="c0d4bcba38"><code>c0d4bcb</code></a>
Unify sys-crate build scripts (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/995">#995</a>)</li>
<li><a
href="ef19ea3832"><code>ef19ea3</code></a>
docs: improve dev-tests-only documentation and docs.rs rendering (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1054">#1054</a>)</li>
<li>See full diff in <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.1...v1.16.2">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=aws-lc-rs&package-manager=cargo&previous-version=1.16.1&new-version=1.16.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 07:43:23 +00:00
Narfinger
81c3bde86c script: Move easy IpcChannel usage to GenericChannel usage (#43309)
This moves some easy elements in Script from IpcChannel and related
methods to GenericChannel and related methods and some callbacks.

Testing: This will be covered by WPT if the channels behave differently.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-20 07:24:25 +00:00
Euclid Ye
e1433babbb webdriver: Remove TODO w.r.t. writing mode (#43468)
The width and height should be guaranteed to be non-negative according
to CSSOM regardless of the writing mode.

Testing: Existing tests.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-20 07:21:52 +00:00
Shubham Gupta
a7d8f542da layout: Fix first-paint detection (#42975)
This PR comprises
1. Segregate `paintable` and `contentful`.
2. Adds Checking of non-default background for eligibility to mark
`first-paint`.
3. Adds a bool `is_paintable` to `display_list` and use same for marking
`first-paint`.

TODO: This doesn't consider `iframes`. Will add PR after fixing WPT
tests.

Raised an issue for some incomplete definitions:
https://github.com/w3c/paint-timing/issues/122




Testing: 
- `wpt/tests/paint-timing/first-paint-only/first-paint-bg-color.html`
- Updated WPT tests expectations.
  - `wpt/paint-timing/first-image-child.html`
- `wpt/paint-timing/first-paint-only/sibling-painting-first-image.html`
- Unit Test: `servo/tests/performance_paint_timings.rs`. Following Tests
Cases are covered:

Background Pref |Root Background|FP|TC
--|--|--|--
|Default|Unset| | `test_default_pref_with_unset_background`
|Non-Default|Unset| | `test_non_default_pref_with_unset_background`
|Default|Transparent||`test_default_pref_with_transparent_background`

|Non-Default|Unset||`test_non_default_pref_with_transparent_background`
|Default|Set||`test_default_pref_with_background`

|Non-Default|Set||`test_non_default_pref_with_background`
|Non-Default|Set (same as
pref)||`test_non_default_pref_with_same_background`

Fixes: #42148

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-20 07:20:03 +00:00
Jonathan Schwender
e4eca03a7b servoshell: Fix function_casts_as_integer lint (#43469)
Found when building with Rust 1.94. The lint itself only complains about
the direct function ptr to usize cast and recommends an intermediate `as
*const ()` cast. We also don't need provenance here, so we can also use
the more explicit .addr() cast.

Testing: Covered by compilation in CI.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-20 07:06:01 +00:00
Jonathan Schwender
0149bc7f93 Fix media-gstreamer-render-android (#43463)
Fix compile error when compiling the crate (on macos). Discovered
because cargo-publish --dry-run failed.
The trait expects an `Option<>` for `to_vec`

Testing: Not tested in CI. Compiled the crate locally, but without
cross-compiling for android
Fixes: #43462

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-20 04:44:26 +00:00
Philipp Albrecht
15a400b42a Add basic support for handling module scripts in workers (#40365)
While we now pass a lot of worker tests, we still fail a bunch:
```
% fd '^worker-.*.html.ini'
tests/wpt/meta/content-security-policy/gen/top.http-rp/script-src-self/worker-import.http.html.ini
tests/wpt/meta/content-security-policy/gen/top.http-rp/script-src-self/worker-import.https.html.ini
tests/wpt/meta/content-security-policy/gen/top.http-rp/worker-src-self/worker-import.http.html.ini
tests/wpt/meta/content-security-policy/gen/top.http-rp/worker-src-self/worker-import.https.html.ini
tests/wpt/meta/content-security-policy/gen/top.meta/script-src-self/worker-import.http.html.ini
tests/wpt/meta/content-security-policy/gen/top.meta/script-src-self/worker-import.https.html.ini
tests/wpt/meta/content-security-policy/gen/top.meta/worker-src-self/worker-import.http.html.ini
tests/wpt/meta/content-security-policy/gen/top.meta/worker-src-self/worker-import.https.html.ini
tests/wpt/meta/content-security-policy/script-src/worker-data-set-timeout.sub.html.ini
tests/wpt/meta/content-security-policy/script-src/worker-importscripts.sub.html.ini
tests/wpt/meta/content-security-policy/script-src/worker-set-timeout.sub.html.ini
tests/wpt/meta/fetch/metadata/generated/worker-dedicated-constructor.sub.html.ini
tests/wpt/meta/fetch/metadata/generated/worker-dedicated-importscripts.https.sub.html.ini
tests/wpt/meta/fetch/metadata/generated/worker-dedicated-importscripts.sub.html.ini
tests/wpt/meta/mixed-content/gen/top.http-rp/opt-in/worker-import-data.https.html.ini
tests/wpt/meta/mixed-content/gen/top.http-rp/opt-in/worker-import.https.html.ini
tests/wpt/meta/referrer-policy/generic/subresource-test/worker-messaging.html.ini
tests/wpt/meta/service-workers/service-worker/worker-client-id.https.html.ini
tests/wpt/meta/service-workers/service-worker/worker-in-sandboxed-iframe-by-csp-fetch-event.https.html.ini
tests/wpt/meta/service-workers/service-worker/worker-interception-redirect.https.html.ini
tests/wpt/meta/service-workers/service-worker/worker-interception.https.html.ini
tests/wpt/meta/upgrade-insecure-requests/gen/worker-classic.http-rp/upgrade/worker-classic.https.html.ini
tests/wpt/meta/upgrade-insecure-requests/gen/worker-classic.http-rp/upgrade/worker-module.https.html.ini
tests/wpt/meta/upgrade-insecure-requests/gen/worker-module.http-rp/upgrade/worker-classic.https.html.ini
tests/wpt/meta/upgrade-insecure-requests/gen/worker-module.http-rp/upgrade/worker-module.https.html.ini
tests/wpt/meta/wasm/webapi/esm-integration/worker-import-source-phase.tentative.html.ini
tests/wpt/meta/wasm/webapi/esm-integration/worker-import.tentative.html.ini
tests/wpt/meta/workers/Worker-creation-happens-in-parallel.https.html.ini
tests/wpt/meta/workers/Worker-postMessage-happens-in-parallel.https.html.ini
tests/wpt/meta/workers/Worker-terminate-forever-during-evaluation.html.ini
tests/wpt/meta/workers/worker-request-animation-frame.html.ini
```

Also, we are passing `Option<PolicyContainer>` down the call stack
through `LoadState`, which is more of a workaround. However, since
maintaining this long-lived branch is becoming a bit painful (merge
conflicts) and I was starting to lose momentum because of that, I would
like get this merged rather sooner than later.

We will address the failing tests and find the right place for
`PolicyContainer` in follow-ups, including the added
`#[allow(clippy::too_many_arguments)]`.


# See also
* https://html.spec.whatwg.org/multipage/#worker-processing-model
*
https://html.spec.whatwg.org/multipage/#fetch-a-module-worker-script-tree

---

Fixes: #23308
Testing: WPT tests

Signed-off-by: pylbrecht <pylbrecht@mailbox.org>
Co-authored-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-20 00:58:16 +00:00
dependabot[bot]
243423cb95 build: bump tar from 0.4.44 to 0.4.45 (#43465)
Bumps [tar](https://github.com/alexcrichton/tar-rs) from 0.4.44 to
0.4.45.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="096e3d16d1"><code>096e3d1</code></a>
Bump to 0.4.45 (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/443">#443</a>)</li>
<li><a
href="17b1fd84e6"><code>17b1fd8</code></a>
archive: Prevent symlink-directory collision chmod attack (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/442">#442</a>)</li>
<li><a
href="de1a5870e6"><code>de1a587</code></a>
archive: Unconditionally honor PAX size (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/441">#441</a>)</li>
<li><a
href="6071cbe74a"><code>6071cbe</code></a>
ci: Consolidate workflows (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/439">#439</a>)</li>
<li><a
href="ad1fde9edf"><code>ad1fde9</code></a>
build-sys: Promote unused_code to an error</li>
<li><a
href="c8cb250e8b"><code>c8cb250</code></a>
tests: Squash a warning</li>
<li><a
href="638c495a48"><code>638c495</code></a>
ci: Add xtask infra + reverse dependency testing (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/435">#435</a>)</li>
<li><a
href="32a9bbb264"><code>32a9bbb</code></a>
tests: Add RandomReader to exercise partial-read resilience (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/436">#436</a>)</li>
<li><a
href="9c5df0bfd7"><code>9c5df0b</code></a>
Fix GNU long-name extension stream corruption on validation error (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/434">#434</a>)</li>
<li><a
href="88b1e3b0da"><code>88b1e3b</code></a>
Fix docs typo in header.rs (<a
href="https://redirect.github.com/alexcrichton/tar-rs/issues/431">#431</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/alexcrichton/tar-rs/compare/0.4.44...0.4.45">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tar&package-manager=cargo&previous-version=0.4.44&new-version=0.4.45)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-20 00:40:56 +00:00
Jonathan Schwender
edc575b37b script-bindings: Don't write bytecode during build.rs (#43459)
Fixes the following error:

```
error: failed to verify package tarball

Caused by:
  Source directory was modified by build.rs during cargo publish. Build scripts should not modify anything outside of OUT_DIR.
  Added: /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/codegen/__pycache__
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/codegen/__pycache__/codegen.cpython-311.pyc
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/codegen/__pycache__/configuration.cpython-311.pyc
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/WebIDL/__pycache__
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/WebIDL/__pycache__/WebIDL.cpython-311.pyc
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/ply/ply/__pycache__
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/ply/ply/__pycache__/__init__.cpython-311.pyc
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/ply/ply/__pycache__/lex.cpython-311.pyc
        /Users/jschwender/Dev/servo/target/package/servo-script-bindings-0.0.6/third_party/ply/ply/__pycache__/yacc.cpython-311.pyc
```

Testing: Manual testing. The same approach was already successfully
applied in `mozjs`.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-19 19:26:19 +00:00
Jonathan Schwender
310adce3cb servo-dom-struct: Enable required features (#43458)
Without these features, the crate does not build standalone. It worked
in servo because of feature unification.
It seems like we should be able to refactor this crate quite easily to
be able to disable some of the features again.

Testing: Manual build: `cargo build -p servo-dom-struct`

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-19 19:26:02 +00:00
Jonathan Schwender
a6b479d2cc Cargo.toml: More publish preparation (#43457)
Add further missing repository keys / descriptions, which I missed in
#43451 due to a suboptimal grep (assuming that rust-version.workspace is
always the last item).
Additionally fix crate self-references, which caused cargo-publish to
fail, due to it trying to fetch the crate from crates.io.
When specifying the current crate in `[dev-dependencies]` to enable a
test feature or similar, apparently one should not use `workspace =
true` and instead use `path`.
This requires extending the previously added `tidy` check, to allow
`path` dependencies in this specific case outside of the workspace
Cargo.toml.

Testing: Covered by existing tests

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-19 17:36:03 +00:00
Martin Robinson
56e79459f2 script: Modify and copy the contents of <textarea> placeholder less (#43452)
Instead of always doing the newline fixup on the `<textarea>`
placeholder, only do it when the placeholder attribute itself changes.
This avoids doing string replacements when they are not necessary (such
as when a `<textarea>` switches from having text to only having the
placeholder and viceversa).

In addition make it so that `DOMString::clear` preserves the string
allocation when called.

Testing: This is just a small optimization so testing should not be
necessary. Existing behavior is verified via WPT tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-19 15:57:28 +00:00
Oriol Brufau
e2aa1c8c06 Implement "tables inherit color from body quirk" (#43368)
Bumps Stylo to https://github.com/servo/stylo/pull/333

Spec:
https://quirks.spec.whatwg.org/#the-tables-inherit-color-from-body-quirk

Testing: Adding 7 new tests. They expose some bugs in other browsers:
- WebKit and Blink don't use the body color when the table appears
before the body
 - Firefox uses the body color even after removing the body

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-19 13:52:24 +00:00
Uiniel
730c827f67 script: Pass &mut JSContext to more functions in dom/stream (#43439)
Pass `&mut JsContext` to `TransformStreamDefaultController::enqueue`, in
preparation of porting the remaining BlobMethods.

Testing: Just a refactor, ./mach test-unit still passes.
Fixes: Part of #42638

---------

Signed-off-by: Uiniel <174327181+uiniel@users.noreply.github.com>
2026-03-19 12:40:11 +00:00
Steven Novaryo
c4cdcb7da8 script: Fire scroll event on visual viewport scroll (#42771)
On visual viewport scroll, fire the scroll event to the `VisualViewport`
instances. Incidentaly, fix a bug where the pinch zoom update should be
propagated to the script.

Testing: New unit test and manual WPT.

---------

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2026-03-19 10:51:38 +00:00
Steven Novaryo
def1ffa004 layout: Move resolved_sticky_offset to BoxFragmentRareData (#43056)
Wrap `BoxFragment` rare data with `AtomicRefCell` and move
`resolved_sticky_offset` to the `BoxFragmentRareData` since it is
relevant only for `position: sticky`. It reduce the size of
`BoxFragment` from 296 to 264. This allow us to add more rare data to
`BoxFragment` after the reflow, such as the calculation of scrollbar
that requires scrollable overflow to be calculated beforehand.

Testing: No WPT change.

---------

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2026-03-19 10:50:38 +00:00
Sharan Poojari
5bb4f9f103 devtools: add eval support for dedicated workers (#43361)
Added dedicated worker side handling, followed the same pattern used in
main script handling by wiring worker global scope to
`DebuggerGlobalScope` and invoking `fire_eval`

fixes: Part of #43317

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-19 09:41:54 +00:00
Martin Robinson
f641673dad script: Move by word in text fields on Windows and Linux with control (#43436)
On Windows and Linux the control key is expected to move the text caret
by word. In addition, it seems like the alt wasn't working properly on
Linux. This change makes the modifier key for word movement dependent on
the platform.

Testing: This change adds a Servo-specific keyboard motion test.
Keyboard motion events are not specified AFAIK.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-19 09:39:09 +00:00
Jonathan Schwender
eac6ff8509 Metadata: Add missing repository information (#43451)
This fixes a warning of `cargo publish`: 

```
warning: manifest has no description, documentation, homepage or repository
```

Testing: Compiling. Manual testing of `cargo publish --dry-run` (with
some additional patches, and until the next error, shows this warning
has been fixed)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-19 08:54:18 +00:00
shuppy
4dbc9f7af9 libservo: Per-webview accessibility activation (#43029)
in #42336, we added a
[Servo](https://doc.servo.org/servo/struct.Servo.html)-global API for
controlling whether accessibility is active. the idea was that when the
embedder activates accessibility, all webviews and documents activate
accessibility and start sending AccessKit tree updates, and vice versa
when they deactivate.

we found a problem with this approach in #42338. global activation of
accessibility makes it too easy to accidentally cause a panic in
AccessKit, and harder than it needs to be for embedders to learn that
they are responsible for grafting each webview’s subtree into their main
AccessKit tree as soon as accessibility is activated. this is due to an
invariant of the AccessKit subtree API: if a subtree starts sending
updates before the graft node is created, the program panics.

this patch reworks accessibility activation to make it per-webview. by
requiring embedders to explicitly activate accessibility for a webview,
we can communicate the AccessKit invariant via our API docs.

Testing: this patch includes an initial accessibility test in libservo
Fixes: part of #4344, extracted from our work in #42338

---------

Signed-off-by: Alice Boxhall <alice@igalia.com>
Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-03-19 08:44:24 +00:00
Javier Olaechea
eea60b8eb1 script: Pass &mut JSContext to FetchResponseListener::process_response (#43259)
Add the cx parameter to `fn process_response` in the
`FetchResponseListener` trait and the traits that that interface change
requires. Chose to add it as the first parameter, following the same
order that `FetchResponseListener::process_response_eof` uses.

Testing: Checked that servo builds locally as well as `./mach fmt` and
`./mach test-tidy`. I don't think more tests are needed as we are not
introducing new functionality
Fixes: #42840

---------

Signed-off-by: Javier Olaechea <pirata@gmail.com>
2026-03-19 06:22:00 +00:00
dependabot[bot]
8215118a12 build: bump euclid from 0.22.13 to 0.22.14 (#43445)
Bumps [euclid](https://github.com/servo/euclid) from 0.22.13 to 0.22.14.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/servo/euclid/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=euclid&package-manager=cargo&previous-version=0.22.13&new-version=0.22.14)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-19 00:46:00 +00:00
dependabot[bot]
c1cd2a9e7b build: bump quick_cache from 0.6.19 to 0.6.20 (#43444)
Bumps [quick_cache](https://github.com/arthurprs/quick-cache) from
0.6.19 to 0.6.20.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/arthurprs/quick-cache/releases">quick_cache's
releases</a>.</em></p>
<blockquote>
<h2>v0.6.20</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix typos and improve documentation clarity by <a
href="https://github.com/Enderlook"><code>@​Enderlook</code></a> in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/103">arthurprs/quick-cache#103</a></li>
<li>fix race in JoinFuture::poll when waker changes between notified
check and waiters list update by <a
href="https://github.com/morgangallant"><code>@​morgangallant</code></a>
in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/104">arthurprs/quick-cache#104</a></li>
<li>Add shuttle test coverage for switching wakers by <a
href="https://github.com/arthurprs"><code>@​arthurprs</code></a> in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/107">arthurprs/quick-cache#107</a></li>
<li>Add entry/entry_async API for atomic cache access by <a
href="https://github.com/arthurprs"><code>@​arthurprs</code></a> in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/109">arthurprs/quick-cache#109</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/Enderlook"><code>@​Enderlook</code></a>
made their first contribution in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/103">arthurprs/quick-cache#103</a></li>
<li><a
href="https://github.com/morgangallant"><code>@​morgangallant</code></a>
made their first contribution in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/104">arthurprs/quick-cache#104</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.19...v0.6.20">https://github.com/arthurprs/quick-cache/compare/v0.6.19...v0.6.20</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f3aa994418"><code>f3aa994</code></a>
0.6.20</li>
<li><a
href="0a5d3809e5"><code>0a5d380</code></a>
Add entry/entry_async API for atomic cache access (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/109">#109</a>)</li>
<li><a
href="81c5a84cf2"><code>81c5a84</code></a>
Add shuttle test coverage for switching wakers (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/107">#107</a>)</li>
<li><a
href="2635b64d15"><code>2635b64</code></a>
fix race in JoinFuture::poll when waker changes between notified check
and wa...</li>
<li><a
href="3c3c88b501"><code>3c3c88b</code></a>
Fix typos and improve documentation clarity (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/103">#103</a>)</li>
<li>See full diff in <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.19...v0.6.20">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quick_cache&package-manager=cargo&previous-version=0.6.19&new-version=0.6.20)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-19 00:41:50 +00:00
dependabot[bot]
8c2999a998 build: bump clap from 4.5.60 to 4.6.0 (#43442)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.60 to 4.6.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap's
changelog</a>.</em></p>
<blockquote>
<h2>[4.6.0] - 2026-03-12</h2>
<h3>Compatibility</h3>
<ul>
<li>Update MSRV to 1.85</li>
</ul>
<h2>[4.5.61] - 2026-03-12</h2>
<h3>Internal</h3>
<ul>
<li>Update dependencies</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="9ab6dee710"><code>9ab6dee</code></a>
chore: Release</li>
<li><a
href="374a30dac6"><code>374a30d</code></a>
docs: Update changelog</li>
<li><a
href="d0c8aabc00"><code>d0c8aab</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6306">#6306</a>
from epage/update</li>
<li><a
href="686ce2f665"><code>686ce2f</code></a>
chore: Upgrade compatible</li>
<li><a
href="8203238de6"><code>8203238</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6305">#6305</a>
from epage/msrv</li>
<li><a
href="c774a892ba"><code>c774a89</code></a>
docs: Reduce main's in doctests</li>
<li><a
href="73534f6ed3"><code>73534f6</code></a>
chore: Upgrade to 2025 edition</li>
<li><a
href="dfe05a9bfe"><code>dfe05a9</code></a>
chore: Bump MSRV to 1.85</li>
<li><a
href="8b41d0b849"><code>8b41d0b</code></a>
chore: Release</li>
<li><a
href="518220f102"><code>518220f</code></a>
docs: Update changelog</li>
<li>Additional commits viewable in <a
href="https://github.com/clap-rs/clap/compare/clap_complete-v4.5.60...clap_complete-v4.6.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=clap&package-manager=cargo&previous-version=4.5.60&new-version=4.6.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-19 00:29:06 +00:00
Tim van der Lippe
4723955af8 script: Move encoding interfaces into encoding/ (#43437)
Part of #38901

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-18 21:18:31 +00:00
Tim van der Lippe
6a788b1bf3 script: Strip blockedURI resource (#43367)
This was missed when implementing support for reporting CSP violations.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-18 21:03:16 +00:00
Martin Robinson
7904bf7040 script: Base accesskey on keyboard key codes (#43434)
Instead of using ASCII character to process the `accesskey` attribute
use the hardware key code that comes with the platform key event. This
aligns our implementation closer to the spec and allows `accesskey` to
work properly with lowercase letters on Linux machines (where shift is
part of the access key sequence). This might introduce some issues with
non-US keyboards, but those issues are inherent in the specification --
one reason why `accesskey` is not recommended for use.

Testing: A Servo-specific accesskey test is extended to cover this case.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-18 20:24:46 +00:00
Jacob Adam W.
e6d06b2cea script: Prevent invisible elements from being focusable (#43431)
Elements with `visibility: hidden` or `visibility: collapse` could
receive focus via both sequential navigation and the JS `focus()` API,
and already-focused elements did not lose focus when becoming invisible.
Per the CSS Display spec, invisible elements ”are removed from
navigation”, which we can interpret to mean sequential focus navigation.
In practical terms, all popular user agents also prevent elements with
`visibility: hidden` from being focusable via click/the JS API, so this
PR makes servo match that behaviour as well.

Specifically, this adds a visibility check to
`Element::focusable_area_kind()` so that invisible elements are excluded
from all focusable area kinds.

Fixes #41312.

---------

Signed-off-by: Jacob Adam <software@jacobadam.net>
2026-03-18 16:40:36 +00:00
Uiniel
475eeccc8a script: Pass &mut JSContext to ReadableStream::cancel (#43432)
Pass `&mut JSContext` to `ReadableStream::cancel`, in preparation of
porting the remaining `BlobMethods`.

Testing: Just a refactor, ./mach test-unit still passes.
Fixes: Part of #42638

Signed-off-by: Uiniel <174327181+uiniel@users.noreply.github.com>
2026-03-18 16:33:45 +00:00
Taym Haddadi
6e832c6d60 indexeddb: align getAll/getAllKeys and convert_value_to_key with IndexedDB spec (#43041)
indexeddb: align getAll/getAllKeys and convert_value_to_key with
IndexedDB spec and update WPT expectation

Testing: more IndexedDB test are passing.
part of https://github.com/servo/servo/issues/40983

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-18 16:09:41 +00:00
Martin Robinson
6150ea08c4 layout: Properly find text index when clicking to left of text fragments (#43238)
When clicking just to the left of a text fragment, we should return the
first index in that fragment. This means that when you click on the
border of a text input, the first fragment is selected. We do this by
improving the distance calculation logic to account for this situation.

Testing: This allows us to remove the "fudge factor" that we were adding
to
mouse handling input tests. In addition, the content rectangle
calculation
function is improved and made more general for these tests. In addition,
two new Servo-specific tests are added to verify the behavior when
clicking
in the padding of various text inputs.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-18 14:06:38 +00:00
Tim van der Lippe
479a9b6be3 script: Pass &mut JSContext to attribute_mutated (#43383)
It pushes the `temp_cx` 1 level up to `element.rs` where the calling
chain begins. Other than that this was purely a mechanical change where
I used regexes to replace all patterns with the new ones.

Part of #42812

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-18 11:03:54 +00:00
atbrakhi
d3ca63c514 devtools: Implement object and function property preview (#43356)
Implement property preview for the debugger popup. When hovering over
variables while paused at a breakpoint, users can now see object
properties and function metadata

Testing: Current tests are passing. Manual testing.
Fixes: Part of #36027 

<img width="1507" height="876" alt="image"
src="https://github.com/user-attachments/assets/31c95010-dab9-4b2c-a9b1-da6a29aa0de1"
/>

<img width="360" height="365" alt="image"
src="https://github.com/user-attachments/assets/50d19979-c0b2-4278-b19b-85c0c0318ab4"
/>
<img width="370" height="365" alt="image"
src="https://github.com/user-attachments/assets/3b74ef26-055b-4e49-848e-e7758f8d1de6"
/>

---------

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-18 09:23:26 +00:00
Tim van der Lippe
2dd5c38c8e script: Pass &mut JSContext in remaining parts of Trusted Types (#43365)
These are the remaining arguments of `CanGc`.

Part of #40600

Testing: it compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-18 09:15:31 +00:00
Shubham Gupta
1c35a33bec ci: Have full runs also trigger macos-arm-unit-tests (#43358)
Just organizes full run.

Testing: No change expected. Successful landing is sufficient.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-18 09:02:11 +00:00
Narfinger
8d153761f9 script: Content Event Handler Check switch to HashSet (#43337)
Previously CONTENT_EVENT_HANDLER_NAMES was a array of more than 100
elements where we were doing a linear search.

This replaces it with a FxHashSet and a O(1) search. In most cases this
should not improve performance as the first few elements seem to be the
most common event handler names. But even these were a couple of costly
string away.
In the case that somebody specifies a later event or an event that does
not exist, we increase the performance significantly.


Currently I do not have numbers as I am away from my workstation.

Testing: This does not change behavior, just speed.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-18 06:59:22 +00:00
Christian Duerr
3c9221c3b5 servo: Rename WebView::pinch_zoom to adjust_pinch_zoom and add pinch zoom getter (#43228)
Previously the `pinch_zoom` method on `WebView` would be used to update
the page's pinch zoom level, however there was no way for the embedder
to retrieve the current pinch zoom.

This patch renames the existing `pinch_zoom` method to
`adjust_pinch_zoom` and changes the `pinch_zoom` method to instead
return the current pinch zoom level.

---

Decided to go for the breaking change since I'd find `pinch_zoom`
combined with `get_pinch_zoom` to be confusing, however I'm happy to
change that if a non-breaking change is preferred.

Motivation for this patch is just that I'd like to display the zoom
level in my UI while rendering.

Testing: Since this change adds a simple getter to the API, we can
probably avoid a unit test in this case.

---------

Signed-off-by: Christian Duerr <contact@christianduerr.com>
2026-03-18 04:30:45 +00:00
Shubham Gupta
efe28fb99e layout: Do not consider broken images as LCP candidates (#42833)
Broken Image Icons are not worthy for LCP candidates.

Waiting for WPT Sync to update test from upstream and expectations as
well.

Testing:
`tests/wpt/tests/largest-contentful-paint/broken-image-icon.html`
Fixes: #42832
Fixes: #43030

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-18 03:57:57 +00:00
dependabot[bot]
17bc1daad7 build: bump bpaf from 0.9.23 to 0.9.24 (#43371)
Bumps [bpaf](https://github.com/pacak/bpaf) from 0.9.23 to 0.9.24.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pacak/bpaf/blob/master/Changelog.md">bpaf's
changelog</a>.</em></p>
<blockquote>
<h2>bpaf [0.9.24] - 2026-03-13</h2>
<ul>
<li>
<p>a less confusing error message when invalid user input mixes with
parsers that
can succeed with no input, see <a
href="https://redirect.github.com/pacak/bpaf/issues/442">#442</a>
thanks <a href="https://github.com/tonky"><code>@​tonky</code></a> for a
solution prototype</p>
</li>
<li>
<p>CI test for older rustc now uses 1.71, MSRV should still be 1.60 for
now</p>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/pacak/bpaf/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=bpaf&package-manager=cargo&previous-version=0.9.23&new-version=0.9.24)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-18 03:23:27 +00:00
dependabot[bot]
e61298ef69 build: bump num_enum from 0.7.5 to 0.7.6 (#43374)
Bumps [num_enum](https://github.com/illicitonion/num_enum) from 0.7.5 to
0.7.6.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="f11d81c6cb"><code>f11d81c</code></a>
Release 0.7.6 (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/183">#183</a>)</li>
<li><a
href="90c04cf20c"><code>90c04cf</code></a>
A little extra test coverage for byte literals (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/182">#182</a>)</li>
<li><a
href="40e822bb5d"><code>40e822b</code></a>
Allow byte literals in TryFromPrimitive alternatives (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/181">#181</a>)</li>
<li><a
href="699a7ee012"><code>699a7ee</code></a>
Fix up trybuilds (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/180">#180</a>)</li>
<li><a
href="8b99d23508"><code>8b99d23</code></a>
Fix trybuilds (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/179">#179</a>)</li>
<li><a
href="6603c8305e"><code>6603c83</code></a>
Update nightly expectations (<a
href="https://redirect.github.com/illicitonion/num_enum/issues/178">#178</a>)</li>
<li>See full diff in <a
href="https://github.com/illicitonion/num_enum/compare/0.7.5...0.7.6">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=num_enum&package-manager=cargo&previous-version=0.7.5&new-version=0.7.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-18 01:00:36 +00:00
dependabot[bot]
c322a1d062 build: bump colorchoice from 1.0.4 to 1.0.5 (#43372)
Bumps [colorchoice](https://github.com/rust-cli/anstyle) from 1.0.4 to
1.0.5.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="0fe6f0ff6d"><code>0fe6f0f</code></a>
chore: Release</li>
<li><a
href="332016ed16"><code>332016e</code></a>
docs: Update changelog</li>
<li><a
href="dd73f64cf6"><code>dd73f64</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-cli/anstyle/issues/301">#301</a>
from Muscraft/fix-some-escape-codes</li>
<li><a
href="e2d2fb53a7"><code>e2d2fb5</code></a>
fix: Make 4:0 removes all underline styles</li>
<li><a
href="d82d083aa0"><code>d82d083</code></a>
feat: Support SGR 59 (reset underline color to default)</li>
<li><a
href="85c9a86d4c"><code>85c9a86</code></a>
feat: Support SGR 22-29 (off codes)</li>
<li><a
href="ac5c23b732"><code>ac5c23b</code></a>
refactor: Reorder SGR match arms to follow numerical order</li>
<li><a
href="2234b680fb"><code>2234b68</code></a>
test: Add tests for SGR off codes, underline subparams, and underline
color r...</li>
<li><a
href="ffb555fe2b"><code>ffb555f</code></a>
chore: Release</li>
<li><a
href="55de8a6470"><code>55de8a6</code></a>
chore: Download libc to match cargo</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-cli/anstyle/compare/colorchoice-v1.0.4...colorchoice-v1.0.5">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=colorchoice&package-manager=cargo&previous-version=1.0.4&new-version=1.0.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-18 00:48:11 +00:00
dependabot[bot]
05c80489a3 build: bump pyasn1 from 0.6.2 to 0.6.3 (#43366)
Bumps [pyasn1](https://github.com/pyasn1/pyasn1) from 0.6.2 to 0.6.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/pyasn1/pyasn1/releases">pyasn1's
releases</a>.</em></p>
<blockquote>
<h2>Release 0.6.3</h2>
<p>It's a minor release.</p>
<ul>
<li>Added nesting depth limit to ASN.1 decoder to prevent stack overflow
from deeply nested structures (CVE-2026-30922).</li>
<li>Fixed OverflowError from oversized BER length field.</li>
<li>Fixed DeprecationWarning stacklevel for deprecated attributes.</li>
<li>Fixed asDateTime incorrect fractional seconds parsing.</li>
</ul>
<p>All changes are noted in the <a
href="https://github.com/pyasn1/pyasn1/blob/master/CHANGES.rst">CHANGELOG</a>.</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pyasn1/pyasn1/blob/main/CHANGES.rst">pyasn1's
changelog</a>.</em></p>
<blockquote>
<h2>Revision 0.6.3, released 16-03-2026</h2>
<ul>
<li>CVE-2026-30922 (GHSA-jr27-m4p2-rc6r): Added nesting depth
limit to ASN.1 decoder to prevent stack overflow from deeply
nested structures (thanks for reporting, romanticpragmatism)</li>
<li>Fixed OverflowError from oversized BER length field
[issue <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/54">#54</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/54">pyasn1/pyasn1#54</a>)
[pr <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/100">#100</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/pull/100">pyasn1/pyasn1#100</a>)</li>
<li>Fixed DeprecationWarning stacklevel for deprecated attributes
[issue <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/86">#86</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/86">pyasn1/pyasn1#86</a>)
[pr <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/101">#101</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/pull/101">pyasn1/pyasn1#101</a>)</li>
<li>Fixed asDateTime incorrect fractional seconds parsing
[issue <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/81">#81</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/81">pyasn1/pyasn1#81</a>)
[pr <a
href="https://redirect.github.com/pyasn1/pyasn1/issues/102">#102</a>](<a
href="https://redirect.github.com/pyasn1/pyasn1/pull/102">pyasn1/pyasn1#102</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="af65c3b92e"><code>af65c3b</code></a>
Prepare release 0.6.3</li>
<li><a
href="5a49bd1fe9"><code>5a49bd1</code></a>
Merge commit from fork</li>
<li><a
href="5494ba43f7"><code>5494ba4</code></a>
Fix asDateTime incorrect fractional seconds parsing (<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/102">#102</a>)</li>
<li><a
href="71f486e6c3"><code>71f486e</code></a>
Fix DeprecationWarning stacklevel for deprecated attributes (<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/101">#101</a>)</li>
<li><a
href="d7cb42dcaa"><code>d7cb42d</code></a>
Fix OverflowError from oversized BER length field (<a
href="https://redirect.github.com/pyasn1/pyasn1/issues/100">#100</a>)</li>
<li>See full diff in <a
href="https://github.com/pyasn1/pyasn1/compare/v0.6.2...v0.6.3">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pyasn1&package-manager=uv&previous-version=0.6.2&new-version=0.6.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 20:54:05 +00:00
Tim van der Lippe
48f1da9fe6 script: Pass &mut JSContext to TrustedScript::get_trusted_type_compliant_string (#43362)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-17 20:26:58 +00:00
Uiniel
fba95dcda9 script: Pass &mut JSContext to more functions in dom/stream (#43327)
Pass `&mut JSContext` and `&mut CurrentRealm` to more functions in
`dom/stream`, focusing on functions that need to be ported to finish
porting the remaining methods in `Blob`.

Testing: Just a refactor, ./mach test-unit still passes.
Fixes: Part of #42638

---------

Signed-off-by: Uiniel <174327181+uiniel@users.noreply.github.com>
2026-03-17 20:07:27 +00:00
dyegoaurelio
be58c968de script: Implement duplicate attribute check for CSP nonce validation (#43216)
Propagate the had_duplicate_attributes flag from html5ever's
ElementFlags through to the Element struct, enabling step 3 of the
CSP "is element nonceable" algorithm. Elements with duplicate
attributes are now correctly marked as "Not Nonceable", preventing
scripts with duplicate attributes from bypassing CSP nonce checks.

Testing: We still need https://github.com/servo/html5ever/issues/118 to
fully pass the
`content-security-policy/script-src/nonce-enforce-blocked.html` wpt
test. But I was able to uncomment some of the remaining tests on
`mozilla/csp/nonce-external-script-malformed-blocked.html`

---------

Signed-off-by: Dyego Aurélio <dyegoaurelio@gmail.com>
2026-03-17 19:37:40 +00:00
Shubham Gupta
ba7ad0d8aa wpt: Add a delay to load to valid image to overcome false positive PASS (#43357)
This adds a delay of 2 seconds for loading a valid image. This is added
to potentially overcome the race condition happening while reporting
LCP, to save from false positive result.

Testing: WPT tests is `TIMED OUT` as expected.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-17 16:03:33 +00:00
Jonathan Schwender
fc2152e4c6 ci: Fix try-label failure of media-examples (#43347)
Testing: Not tested, it's difficult to test try-label related changes.
The fix is trivial though.
Fixes: #43345

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-17 14:17:20 +00:00
Jonathan Schwender
f5d4847e85 everywhere: Remove unused deps (#43344)
RustRover flags unused dependencies gray in Cargo.toml, which works well
except for macro / derive related crates (false-positives). Based on
that I removed the flagged crates (after double checking with grep based
search).
There is one weird case in `storage`, where `tokio` was added as a
dependency with multiple feature flags enabled, without tokio actually
being used. Since the same feature combination is present in `net`,
probably this is a remnant of migrating storage from net.

Testing: If CI passes, this is fine. I additionally also searched for
references of the packages I removed in the respective crate (I hope I
didn't forget any, but should be 90% good).

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-17 13:26:01 +00:00
Gae24
026d679783 script: Pass &mut JSContext to Element::create (#43348)
Pass `&mut JSContext` to `Element::create` and `create_html_element`

Testing: No functionality changes, covered by existing tests.
Part of #40600

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-17 13:03:33 +00:00
Martin Robinson
3b216f8b99 paint: Remove the scroll event averaging workaround (#43350)
This workaround was added in 2016
(90e970a6d2) when the architecture of
Servo, macOS, and Apple hardware was very different. It has been
highlighted as causing issues on Linux machines (#42065). I've confirmed
that removing it does not seem degrade behavior when scrolling with a
Macbook touchpad. I think we should just remove it for now as it seems
like a workaround rather than a real fix for the original problem.

Testing: There isn't a very good way to test this unfortunately.
Closes #42065.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Christian Duerr <contact@christianduerr.com>
2026-03-17 12:24:49 +00:00
Martin Robinson
3cd221993b script: Allow keyboard scrolling with the spacebar (#43322)
This change allows pressing the spacebar to cause a page down or page up
scroll. This matches the behavior of other browsers. In addition,
keyboard
scrolling tests are moved to the same directory as other input method
tests.

Testing: This change adds some additional testing to Servo-specific
keyboard scrolling tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-17 12:24:15 +00:00
Martin Robinson
8555464648 script: Do not fire simulated click on spacebar/enter in non-state-changing elements (#43343)
Servo has for years implemented a behavior where spacebar or enter click
on a focused element will trigger a click. That behavior used to be
unspecified, but now it is. The specification says that this should only
happen on state-changing elements. This change makes this happen using
activatable elements as a heuristic (as state-changing elements are not
defined in the specification). In addition, the behavior is integrated
into the default keyboard event handler code.

Testing: This change adds a Servo-specific test due to the ambiguities
in the specification.
Fixes: #39028.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-17 10:13:49 +00:00
atbrakhi
3ca83edb56 devtools: Implement PropertyIteratorActor boilerplate (#43319)
Implement `PropertyIteratorActor` boilerplate

This is prerequisite for implementing object property enumeration in the
debugger. It is part of popup preview work in debugger.

Testing: Should not change behavior 
Fixes: part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-17 10:05:41 +00:00
Shubham Gupta
89a4a4e24c script: Correct data type of poster in HTMLVideoElement.webidl (#43341)
Correct data type of poster in `HTMLVideoElement` interface
Successful compilation is enough to verify the change.

Testing:  `tests/wpt/meta/html/dom/reflection-embedded.html`

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-17 10:04:30 +00:00
Gae24
9a8571efcc script: Add support for modulepreload link elements (#42964)
Add support to modulepreload link elements. Currently we only fetch the
root module, as I think it is needs to be discussed whether we should
always fetch module dependencies, or if it should be limited due to
network constraints.
Inside `bind_to_tree` I ended up calling
`fetch_and_process_modulepreload` inside a delayed task, since it would
cause a crash due to DOM not being in a stable state when firing an
event (queueing the event seems to also do the trick).

Remaining tests failures are due to not supporting CSS modules and
performance entries's `transfer_size` being 0.

Testing: Covered by existing tests

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-17 09:28:05 +00:00
Jonathan Schwender
b491d6ddbb ci: Fix mitmproxy script (#43342)
Latest ohos CI scenario tests are failing, due to a type error (int
instead of str).
This was presumably broken by #42509, where the type change. I'm a bit
confused why my try run succeeded, and the failure only recently started
happening (on an unrelated commit). This might be an effect of caching
hiding / avoiding the failure.

Testing: Tested in CI. Apparently this file is not covered by the python
type checker yet.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-17 08:41:16 +00:00
Simon Wülker
4409f81720 script: Log unhandled promise rejections to the console (#43323)
I've also refactored the relevant function a bit, because it was
unnecessarily nested and inside a huge `unsafe` block.

Testing: Regressions are covered by existing tests, but we can't test
for the presence of `log::error!` statements
Fixes (the most relevant) part of
https://github.com/servo/servo/issues/26667

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-17 08:02:49 +00:00
Simon Wülker
4d1dc6db4d net: Allow opaque origins in parse_blob_url (#43329)
Blob URLs created with opaque origins (like those in
https://github.com/servo/servo/issues/43326) were rejected when parsed
during `fetch`.

Testing: This doesn't have an impact on WPT but I've added a unit test

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-17 06:35:30 +00:00
dependabot[bot]
7f09e34386 build: bump tracing-subscriber from 0.3.22 to 0.3.23 (#43336)
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from
0.3.22 to 0.3.23.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tracing/releases">tracing-subscriber's
releases</a>.</em></p>
<blockquote>
<h2>tracing-subscriber 0.3.23</h2>
<h3>Fixed</h3>
<ul>
<li>Allow ansi sanitization to be disabled (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3484">#3484</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/tokio-rs/tracing/issues/3484">#3484</a>:
<a
href="https://redirect.github.com/tokio-rs/tracing/pull/3484">tokio-rs/tracing#3484</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="54ede4d5d8"><code>54ede4d</code></a>
chore: prepare tracing-subscriber 0.3.23 (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3490">#3490</a>)</li>
<li><a
href="37558d5f26"><code>37558d5</code></a>
subscriber: allow ansi sanitization to be disabled (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3484">#3484</a>)</li>
<li><a
href="efc690fa6b"><code>efc690f</code></a>
core: add missing const (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3449">#3449</a>)</li>
<li><a
href="0c32367cf9"><code>0c32367</code></a>
core: Use const initializers instead of <code>once_cell</code></li>
<li><a
href="9feb241133"><code>9feb241</code></a>
docs: add arcswap reload crate to related (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3442">#3442</a>)</li>
<li><a
href="2d55f6faf9"><code>2d55f6f</code></a>
chore: prepare tracing 0.1.44 (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3439">#3439</a>)</li>
<li><a
href="10a9e838a3"><code>10a9e83</code></a>
chore: prepare tracing-core 0.1.36 (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3440">#3440</a>)</li>
<li><a
href="ee82cf92a8"><code>ee82cf9</code></a>
tracing: fix record_all panic (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3432">#3432</a>)</li>
<li><a
href="9978c3663b"><code>9978c36</code></a>
chore: prepare tracing-mock 0.1.0-beta.3 (<a
href="https://redirect.github.com/tokio-rs/tracing/issues/3429">#3429</a>)</li>
<li>See full diff in <a
href="https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.22...tracing-subscriber-0.3.23">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tracing-subscriber&package-manager=cargo&previous-version=0.3.22&new-version=0.3.23)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 00:54:29 +00:00
dependabot[bot]
bdcf5a7c3c build: bump anstyle from 1.0.13 to 1.0.14 (#43333)
Bumps [anstyle](https://github.com/rust-cli/anstyle) from 1.0.13 to
1.0.14.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="0fe6f0ff6d"><code>0fe6f0f</code></a>
chore: Release</li>
<li><a
href="332016ed16"><code>332016e</code></a>
docs: Update changelog</li>
<li><a
href="dd73f64cf6"><code>dd73f64</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-cli/anstyle/issues/301">#301</a>
from Muscraft/fix-some-escape-codes</li>
<li><a
href="e2d2fb53a7"><code>e2d2fb5</code></a>
fix: Make 4:0 removes all underline styles</li>
<li><a
href="d82d083aa0"><code>d82d083</code></a>
feat: Support SGR 59 (reset underline color to default)</li>
<li><a
href="85c9a86d4c"><code>85c9a86</code></a>
feat: Support SGR 22-29 (off codes)</li>
<li><a
href="ac5c23b732"><code>ac5c23b</code></a>
refactor: Reorder SGR match arms to follow numerical order</li>
<li><a
href="2234b680fb"><code>2234b68</code></a>
test: Add tests for SGR off codes, underline subparams, and underline
color r...</li>
<li><a
href="ffb555fe2b"><code>ffb555f</code></a>
chore: Release</li>
<li><a
href="55de8a6470"><code>55de8a6</code></a>
chore: Download libc to match cargo</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-cli/anstyle/compare/v1.0.13...v1.0.14">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=anstyle&package-manager=cargo&previous-version=1.0.13&new-version=1.0.14)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 00:37:28 +00:00
dependabot[bot]
f8d673a8e8 build: bump the wayland-related group with 5 updates (#43331)
Bumps the wayland-related group with 5 updates:

| Package | From | To |
| --- | --- | --- |
| [wayland-client](https://github.com/smithay/wayland-rs) | `0.31.12` |
`0.31.13` |
| [wayland-cursor](https://github.com/smithay/wayland-rs) | `0.31.12` |
`0.31.13` |
| [wayland-protocols](https://github.com/smithay/wayland-rs) | `0.32.10`
| `0.32.11` |
| [wayland-protocols-plasma](https://github.com/smithay/wayland-rs) |
`0.3.10` | `0.3.11` |
| [wayland-protocols-wlr](https://github.com/smithay/wayland-rs) |
`0.3.10` | `0.3.11` |

Updates `wayland-client` from 0.31.12 to 0.31.13
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-cursor` from 0.31.12 to 0.31.13
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols` from 0.32.10 to 0.32.11
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols-plasma` from 0.3.10 to 0.3.11
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />

Updates `wayland-protocols-wlr` from 0.3.10 to 0.3.11
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/smithay/wayland-rs/commits">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-17 00:25:45 +00:00
dependabot[bot]
9fd7477cbb build: bump pyopenssl from 25.3.0 to 26.0.0 (#43321)
Bumps [pyopenssl](https://github.com/pyca/pyopenssl) from 25.3.0 to
26.0.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/pyca/pyopenssl/blob/main/CHANGELOG.rst">pyopenssl's
changelog</a>.</em></p>
<blockquote>
<h2>26.0.0 (2026-03-15)</h2>
<p>Backward-incompatible changes:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^</p>
<ul>
<li>Dropped support for Python 3.7.</li>
<li>The minimum <code>cryptography</code> version is now 46.0.0.</li>
</ul>
<p>Deprecations:
^^^^^^^^^^^^^</p>
<p>Changes:
^^^^^^^^</p>
<ul>
<li>Added support for using aws-lc instead of OpenSSL.</li>
<li>Properly raise an error if a DTLS cookie callback returned a cookie
longer than <code>DTLS1_COOKIE_LENGTH</code> bytes. Previously this
would result in a buffer-overflow. Credit to <strong>dark_haxor</strong>
for reporting the issue. <strong>CVE-2026-27459</strong></li>
<li>Added <code>OpenSSL.SSL.Connection.get_group_name</code> to
determine which group name was negotiated.</li>
<li><code>Context.set_tlsext_servername_callback</code> now handles
exceptions raised in the callback by calling <code>sys.excepthook</code>
and returning a fatal TLS alert. Previously, exceptions were silently
swallowed and the handshake would proceed as if the callback had
succeeded. Credit to <strong>Leury Castillo</strong> for reporting this
issue. <strong>CVE-2026-27448</strong></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="358cbf29c4"><code>358cbf2</code></a>
Prepare for 26.0.0 release (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1487">#1487</a>)</li>
<li><a
href="a8d28e7069"><code>a8d28e7</code></a>
Bump actions/cache from 4 to 5 (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1486">#1486</a>)</li>
<li><a
href="6fefff0556"><code>6fefff0</code></a>
Add aws-lc compatibility to tests and CI (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1476">#1476</a>)</li>
<li><a
href="a739f9661d"><code>a739f96</code></a>
Bump actions/download-artifact from 8.0.0 to 8.0.1 (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1485">#1485</a>)</li>
<li><a
href="8b4c66b1b5"><code>8b4c66b</code></a>
Bump actions/upload-artifact in /.github/actions/upload-coverage (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1484">#1484</a>)</li>
<li><a
href="02a5c78435"><code>02a5c78</code></a>
Bump actions/upload-artifact from 6.0.0 to 7.0.0 (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1483">#1483</a>)</li>
<li><a
href="d9733878d6"><code>d973387</code></a>
Bump actions/download-artifact from 7.0.0 to 8.0.0 (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1482">#1482</a>)</li>
<li><a
href="57f09bb4bb"><code>57f09bb</code></a>
Fix buffer overflow in DTLS cookie generation callback (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1479">#1479</a>)</li>
<li><a
href="d41a814759"><code>d41a814</code></a>
Handle exceptions in set_tlsext_servername_callback callbacks (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1478">#1478</a>)</li>
<li><a
href="7b29beba77"><code>7b29beb</code></a>
Fix not using a cryptography wheel on uv (<a
href="https://redirect.github.com/pyca/pyopenssl/issues/1475">#1475</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/pyca/pyopenssl/compare/25.3.0...26.0.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pyopenssl&package-manager=uv&previous-version=25.3.0&new-version=26.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts page](https://github.com/servo/servo/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 17:00:11 +00:00
Jonathan Schwender
d9238efbb8 Version releases with the workspace version (#43263)
In preparation for a release to crates.io, bump the workspace version to
match the current servoshell version, and let the servoshell version use
the workspace version again. This makes versioning for us easier, and
makes more sense since servoshell is considered to be just a demo for
servo.

The `./mach release` command is updated to support bumping the workspace
version, and patch the version requirement of all workspace-versioned
workspace dependencies.

Testing: Can be manually verified by running `./mach release
<new_version>`. Note that this just bumps the version numbers, and
doesn't release anything, so it's perfectly safe to run.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-16 16:44:36 +00:00
Simon Martin
f8fe8ce82c servoshell: fix display of tooltip showing link target URL (#43320)
I noticed while investigating #42636 that whenever servoshell displays a
link target URL, the associated tooltip is sometimes shown with some
kind of transparency, that is usually - but not always - "fixed" after a
bit of time.

The first problem is that we create the tooltip in the background, while
we should put it on top of everything else. This is however not
sufficient to fix the "flickering", hence the explicit call to
set_needs_repaint, like was done for dialogs in 6d4937b5d6.

Testing: manual (servoshell's visual aspects not covered by any test)
Fixes: https://github.com/servo/servo/issues/42636

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-03-16 14:45:45 +00:00
Kingsley Yung
ab6a42c8cd script: ML-KEM/ML-DSA PKCS8 keys in non-seed-only formats (#43315)
The specification of Modern Algorithms in WebCrypto API has updated to
specify how to handle ML-KEM/DSA PKCS8 keys in non-seed-only formats.

In the updated specification:

- When importing a key in the `expandedKey` format, throw a
`NotSupportedError`.
- When importing a key in the `both` format, *optionally* throw a
`NotSupportedError`.
- Alternatively, when importing a key in the `both` format, require
checking that the seed and expanded key match.

Our implementation matches the updated specification, with support of
the `both` format. Therefore, this patch only updates the specification
text, without changing the code.

Related commit in specification repository:
6543db893e

Testing: Only changes in spec text. No code change.

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-16 14:02:33 +00:00
atbrakhi
821db2c2fc devtools: Implement initial support for showing scope variables (#43232)
This change implements showing scope variable in Debugger tab. This is
still early and we have more work to do.

Next step is building correct data structure and showing different types
of variables.

Testing: Manual as well as current tests are passing.
Fixes: part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-16 13:02:09 +00:00
atbrakhi
a27ab5ae55 devtools: Remove EvaluateJS in favor of Eval (#43316)
The console actor sends `Eval` via debugger.js, not `EvaluateJS`.
Workers only handled `EvaluateJS` which was never sent. We would want to
use `Eval` for workers as well. The worker evaluation was already
non-functional.

One more motivation behind not keeping this legacy path is because it
requires passing `None` for all new fields added to
`EvaluateJSReplyValue`, that is extra burden.

Testing: All existing tests are passing.

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-16 12:45:32 +00:00
Euclid Ye
41ad1b63a6 script: Port TreeWalker & NodeIterator to &mut JSContext (#43312)
Testing: It compiles.
Part of #40600
TODO: #43311

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-16 09:55:46 +00:00
Narfinger
c49433e94f Script: Do not convert to and from DOMString multiple times (#43304)
Previously we called queue_dialog_toggle_break_event_task with
DOMStrings which converted them to strings to then convert them back to
DOMStrings.

Because DOMString is !Send we cannot use the DOMString directly so we
just change queue_dialog_toggle_break_event_task to get &str.


Testiing: Compilation is the test.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-16 07:27:15 +00:00
Euclid Ye
709e8d5548 script: Skip RAII guard and early return when input event queue is empty (#43301)
This is a hot path:
- there is a lot of processing in `handle_pending_input_events`: JS
realm entry, temporary variable creation, value assignment etc.
- we acquire a RAII guard before calling the function.

If the event queue is empty, this would result in unnecessary overhead
on the hot path.
We skip all above work in this case.

Testing: This is an optimization that should not change visible
behaviour,
thus covered by all the testdriver tests.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-16 07:15:20 +00:00
Euclid Ye
fc76797034 script: Port Notification to mozjs JSContext (#43302)
Mission No.2

Divided into three parts
- Import `js::context::JSContext;` and use it. This is fine as we
already renamed the traditional one.
- Major mission of porting
- Add space between functions

Testing: It compiles

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-16 06:21:27 +00:00
Josh Matthews
3d25895caf Update wayland crates. (#43299)
Updates the wayland crates and adds a new exemption for the quick-xml
duplication. This prevents dependabot opening a PR every day for these
crates which can never be merged.

Closes: #43294

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-16 03:30:36 +00:00
dependabot[bot]
259a6db621 build: bump cc from 1.2.56 to 1.2.57 (#43296)
Bumps [cc](https://github.com/rust-lang/cc-rs) from 1.2.56 to 1.2.57.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/releases">cc's
releases</a>.</em></p>
<blockquote>
<h2>cc-v1.2.57</h2>
<h3>Other</h3>
<ul>
<li>Size archiver batches according to argument length not argument
count (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1689">#1689</a>)</li>
<li>Added <code>Build::env</code> for setting environment variables of
compiler invocations and other child processes (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1656">#1656</a>
<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1682">#1682</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md">cc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.56...cc-v1.2.57">1.2.57</a>
- 2026-03-13</h2>
<h3>Other</h3>
<ul>
<li>Size archiver batches according to argument length not argument
count (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1689">#1689</a>)</li>
<li>Added <code>Build::env</code> for setting environment variables of
compiler invocations and other child processes (<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1656">#1656</a>
<a
href="https://redirect.github.com/rust-lang/cc-rs/pull/1682">#1682</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="77f88665c6"><code>77f8866</code></a>
chore(cc): release v1.2.57 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1681">#1681</a>)</li>
<li><a
href="c541d9b3cf"><code>c541d9b</code></a>
Size archiver batches according to argument length not argument count
(<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1689">#1689</a>)</li>
<li><a
href="1654cb904b"><code>1654cb9</code></a>
Improve the semantics of <code>Build::env</code> (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1682">#1682</a>)</li>
<li><a
href="5868a0f0e4"><code>5868a0f</code></a>
Use cargo-nextest in main.yml (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1686">#1686</a>)</li>
<li><a
href="c5610e1071"><code>c5610e1</code></a>
Update which requirement from ^4.0 to ^8.0 (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1683">#1683</a>)</li>
<li><a
href="d41559b130"><code>d41559b</code></a>
Serialize tests that need environment variables (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1685">#1685</a>)</li>
<li><a
href="e35ca93f30"><code>e35ca93</code></a>
Rename job 'regenerate' to 'rustc_target_test' (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1687">#1687</a>)</li>
<li><a
href="41965a999f"><code>41965a9</code></a>
Don't run CI twice on every PR (<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1684">#1684</a>)</li>
<li><a
href="9c4720bca5"><code>9c4720b</code></a>
rename <code>__set_env</code> to <code>env</code> and make it un-hidden
(<a
href="https://redirect.github.com/rust-lang/cc-rs/issues/1656">#1656</a>)</li>
<li>See full diff in <a
href="https://github.com/rust-lang/cc-rs/compare/cc-v1.2.56...cc-v1.2.57">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=cc&package-manager=cargo&previous-version=1.2.56&new-version=1.2.57)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 01:57:18 +00:00
dependabot[bot]
42786f9ea5 build: bump portable-atomic-util from 0.2.5 to 0.2.6 (#43298)
Bumps
[portable-atomic-util](https://github.com/taiki-e/portable-atomic-util)
from 0.2.5 to 0.2.6.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/portable-atomic-util/releases">portable-atomic-util's
releases</a>.</em></p>
<blockquote>
<h2>0.2.6</h2>
<p>portable-atomic-util has been extracted from the portable-atomic
repository into its own repository: <a
href="https://github.com/taiki-e/portable-atomic-util">https://github.com/taiki-e/portable-atomic-util</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/portable-atomic-util/blob/main/CHANGELOG.md">portable-atomic-util's
changelog</a>.</em></p>
<blockquote>
<h2>[0.2.6] - 2026-03-14</h2>
<p>portable-atomic-util has been extracted from the portable-atomic
repository into its own repository: <a
href="https://github.com/taiki-e/portable-atomic-util">https://github.com/taiki-e/portable-atomic-util</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="08e9d6c3e9"><code>08e9d6c</code></a>
Release 0.2.6</li>
<li><a
href="01bc732b19"><code>01bc732</code></a>
Update changelog</li>
<li><a
href="0a4125322f"><code>0a41253</code></a>
Apply clippy to doctest</li>
<li><a
href="7f3d9e0a16"><code>7f3d9e0</code></a>
Extract portable-atomic-util from portable-atomic repository</li>
<li><a
href="d1465ffa69"><code>d1465ff</code></a>
Add comment about rust-version field to Cargo.toml</li>
<li><a
href="0708e89053"><code>0708e89</code></a>
Update allowed lint list</li>
<li><a
href="e49c8894f1"><code>e49c889</code></a>
Adjust strict_provenance polyfill used on old rustc</li>
<li>See full diff in <a
href="https://github.com/taiki-e/portable-atomic-util/compare/v0.2.5...v0.2.6">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=portable-atomic-util&package-manager=cargo&previous-version=0.2.5&new-version=0.2.6)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 00:52:11 +00:00
dependabot[bot]
b1b1c1f4e3 build: bump tinyvec from 1.10.0 to 1.11.0 (#43297)
Bumps [tinyvec](https://github.com/Lokathor/tinyvec) from 1.10.0 to
1.11.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/Lokathor/tinyvec/blob/main/CHANGELOG.md">tinyvec's
changelog</a>.</em></p>
<blockquote>
<h1>Changelog</h1>
<h2>1.11</h2>
<ul>
<li>switched from <code>serde</code> dep to <code>serde_core</code> dep,
which should allow more
parallelization in builds for downstream users.</li>
<li>add <code>as_mut_inner</code> method when the
<code>latest_stable_rust</code> feature is enabled</li>
<li>add <code>is_full</code> method to check if the size is equal to the
capacity</li>
<li>add <code>defmt</code> support</li>
</ul>
<h2>1.10</h2>
<ul>
<li>Minimum rust version is now 1.55, and the non-const-generic impls
are removed.
This reduces build times by over a second on average, which is
significant enough for a library crate.</li>
</ul>
<h2>1.9</h2>
<ul>
<li>Adds a <code>latest_stable_rust</code> cargo feature, which will
automatically pull in
other cargo features related to the latest Stable version of rust.</li>
<li>Adds <code>ArrayVec::try_from_array_len</code></li>
<li>Adds <code>TinyVec::into_vec</code> and
<code>TinyVec::into_boxed_slice</code></li>
<li>Adds support for <code>generic-array</code> crate</li>
<li>Adds support for the <code>borsh</code> crate</li>
</ul>
<h2>1.8.1</h2>
<ul>
<li><a href="https://github.com/e00E">e00E</a> updated the rustc
features so that they all
correctly depend on the lower version feature.
<a href="https://redirect.github.com/Lokathor/tinyvec/pull/199">pr
199</a></li>
</ul>
<h2>1.8</h2>
<ul>
<li><a href="https://github.com/Fuuzetsu">Fuuzetsu</a> added the
<code>ArrayVec::as_inner</code> method.
<a href="https://redirect.github.com/Lokathor/tinyvec/pull/197">pr
197</a></li>
</ul>
<h2>1.7</h2>
<ul>
<li><a href="https://github.com/Fuuzetsu">Fuuzetsu</a> added the
<code>rustc_1_61</code> cargo feature, which adds the
<code>retain_mut</code> method.
<a href="https://redirect.github.com/Lokathor/tinyvec/pull/198">pr
198</a></li>
</ul>
<h2>1.6.1</h2>
<ul>
<li><a href="https://github.com/e00E">e00E</a> fixed the Arbitrary impl
to work on Stable
without using a feature gate.
<a href="https://redirect.github.com/Lokathor/tinyvec/pull/180">pr
180</a></li>
</ul>
<h2>1.6.0</h2>
<ul>
<li><a href="https://github.com/i509VCB">i509VCB</a> added the
<code>try_</code> functions for fallable reallocation.</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d6c8a5f222"><code>d6c8a5f</code></a>
chore: Release</li>
<li><a
href="4348329ebe"><code>4348329</code></a>
changelog</li>
<li><a
href="834172bbcd"><code>834172b</code></a>
changelog</li>
<li><a
href="01b7a9fe9d"><code>01b7a9f</code></a>
Add defmt support (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/216">#216</a>)</li>
<li><a
href="bb18ff1618"><code>bb18ff1</code></a>
Add is_full method (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/217">#217</a>)</li>
<li><a
href="219f2874bd"><code>219f287</code></a>
Add as_mut_inner method (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/215">#215</a>)</li>
<li><a
href="5809985ddf"><code>5809985</code></a>
chore: switch to serde_core (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/213">#213</a>)</li>
<li><a
href="10f783e57a"><code>10f783e</code></a>
Remove leftover comment from before the const generic days (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/214">#214</a>)</li>
<li><a
href="842e1692b3"><code>842e169</code></a>
chore: improve code comments clarity (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/212">#212</a>)</li>
<li><a
href="a6db082130"><code>a6db082</code></a>
Make Debug instances behave like those for slices (<a
href="https://redirect.github.com/Lokathor/tinyvec/issues/211">#211</a>)</li>
<li>See full diff in <a
href="https://github.com/Lokathor/tinyvec/compare/v1.10.0...v1.11.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tinyvec&package-manager=cargo&previous-version=1.10.0&new-version=1.11.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 00:44:10 +00:00
dependabot[bot]
0f8531d6a9 build: bump once_cell from 1.21.3 to 1.21.4 (#43295)
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.21.3 to
1.21.4.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/matklad/once_cell/blob/master/CHANGELOG.md">once_cell's
changelog</a>.</em></p>
<blockquote>
<h2>1.21.4</h2>
<ul>
<li>
<p>Fix unsoundness in <code>OnceCell::wait</code> under
<code>--features=parking_lot</code>, <a
href="https://redirect.github.com/matklad/once_cell/pull/295">#295</a>.</p>
<p>If thread A calls <code>wait</code>, while thread B calls
<code>get_or_try_init(f)</code>, and, furthermore, <code>f</code>
panics,
the <code>wait</code> incorrectly returns and thread A observes
uninitialized memory.</p>
<p>Kudos to <a
href="https://github.com/meng-xu-cs"><code>@​meng-xu-cs</code></a> for a
nice find!</p>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="80fe900b21"><code>80fe900</code></a>
Merge pull request <a
href="https://redirect.github.com/matklad/once_cell/issues/296">#296</a>
from matklad/matklad/plfix</li>
<li><a
href="a5e09c971c"><code>a5e09c9</code></a>
release 1.21.4</li>
<li><a
href="2426d45d85"><code>2426d45</code></a>
Merge pull request <a
href="https://redirect.github.com/matklad/once_cell/issues/295">#295</a>
from matklad/matklad/plfix</li>
<li><a
href="a1441215db"><code>a144121</code></a>
Merge pull request <a
href="https://redirect.github.com/matklad/once_cell/issues/290">#290</a>
from alexanderkjall/run-tests-with-no-default-features</li>
<li><a
href="232a1a49b5"><code>232a1a4</code></a>
Merge pull request <a
href="https://redirect.github.com/matklad/once_cell/issues/292">#292</a>
from phil-opp/doc-fix</li>
<li><a
href="d31767bbcd"><code>d31767b</code></a>
fix OnceCell::wait with features=parking_lot</li>
<li><a
href="28d29ae1c1"><code>28d29ae</code></a>
Fix: <code>sync::OnceCell::try_insert</code> docs should import
<code>sync</code> variant</li>
<li><a
href="0f78fb0d6d"><code>0f78fb0</code></a>
make the command 'cargo test --no-default-features' work</li>
<li><a
href="fda60a6c70"><code>fda60a6</code></a>
Merge pull request <a
href="https://redirect.github.com/matklad/once_cell/issues/287">#287</a>
from AbeZbm/add-tests</li>
<li><a
href="b5b98c09eb"><code>b5b98c0</code></a>
Add tests for OnceRef</li>
<li>See full diff in <a
href="https://github.com/matklad/once_cell/compare/v1.21.3...v1.21.4">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=once_cell&package-manager=cargo&previous-version=1.21.3&new-version=1.21.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 00:33:52 +00:00
dependabot[bot]
0032c92453 build: bump the gstreamer-related group with 2 updates (#43291)
Bumps the gstreamer-related group with 2 updates:
[glib](https://github.com/gtk-rs/gtk-rs-core) and
[glib-sys](https://github.com/gtk-rs/gtk-rs-core).

Updates `glib` from 0.22.2 to 0.22.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gtk-rs/gtk-rs-core/releases">glib's
releases</a>.</em></p>
<blockquote>
<h2>0.22.3</h2>
<pre><code>Carlos Martín Nieto:
      glib: use `pointer::addr()` to resolve strict provenance lint
      glib: use exposed provenance when we cannot copy one
      glib: make use of `mem::offset_of!()`
<p>Sebastian Dröge:<br />
Update gir-files<br />
Regenerate with latest gir-files<br />
Update versions to 0.22.3<br />
</code></pre></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="90288b72a8"><code>90288b7</code></a>
Update versions to 0.22.3</li>
<li><a
href="14f0216940"><code>14f0216</code></a>
glib: make use of <code>mem::offset_of!()</code></li>
<li><a
href="cc3db0cc9e"><code>cc3db0c</code></a>
glib: use exposed provenance when we cannot copy one</li>
<li><a
href="9f43fe528f"><code>9f43fe5</code></a>
glib: use <code>pointer::addr()</code> to resolve strict provenance
lint</li>
<li><a
href="2762c59973"><code>2762c59</code></a>
Regenerate with latest gir-files</li>
<li><a
href="685bf1beef"><code>685bf1b</code></a>
Update gir-files</li>
<li>See full diff in <a
href="https://github.com/gtk-rs/gtk-rs-core/compare/0.22.2...0.22.3">compare
view</a></li>
</ul>
</details>
<br />

Updates `glib-sys` from 0.22.0 to 0.22.3
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gtk-rs/gtk-rs-core/releases">glib-sys's
releases</a>.</em></p>
<blockquote>
<h2>0.22.3</h2>
<pre><code>Carlos Martín Nieto:
      glib: use `pointer::addr()` to resolve strict provenance lint
      glib: use exposed provenance when we cannot copy one
      glib: make use of `mem::offset_of!()`
<p>Sebastian Dröge:<br />
Update gir-files<br />
Regenerate with latest gir-files<br />
Update versions to 0.22.3<br />
</code></pre></p>
<h2>0.22.2</h2>
<pre><code>Julian Sparber:
      glib: Implement From&lt;PtrSlice&lt;GStringPtr&gt; for StrV
      glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;
<p>Sebastian Dröge:<br />
gio: Mark <code>Socket::from_raw_socket()</code> as unsafe</p>
<p>Wladimir Palant:<br />
glib-macros: Silence “redundant closure” clippy warning in
closure!/closure_local!<br />
</code></pre></p>
<h2>0.22.1</h2>
<pre><code>Sebastian Dröge:
gio: Re-add accidentally removed UNIX APIs that are still part of gio
itself
      gio: Remove non-existing UNIX functions from Gir.toml
</code></pre>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="90288b72a8"><code>90288b7</code></a>
Update versions to 0.22.3</li>
<li><a
href="14f0216940"><code>14f0216</code></a>
glib: make use of <code>mem::offset_of!()</code></li>
<li><a
href="cc3db0cc9e"><code>cc3db0c</code></a>
glib: use exposed provenance when we cannot copy one</li>
<li><a
href="9f43fe528f"><code>9f43fe5</code></a>
glib: use <code>pointer::addr()</code> to resolve strict provenance
lint</li>
<li><a
href="2762c59973"><code>2762c59</code></a>
Regenerate with latest gir-files</li>
<li><a
href="685bf1beef"><code>685bf1b</code></a>
Update gir-files</li>
<li><a
href="484fbe01e7"><code>484fbe0</code></a>
Update Cargo.lock</li>
<li><a
href="77ce5c64ea"><code>77ce5c6</code></a>
Update versions to 0.22.2</li>
<li><a
href="a5a6b9f659"><code>a5a6b9f</code></a>
glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;</li>
<li><a
href="1870acb44c"><code>1870acb</code></a>
glib: Implement From&lt;PtrSlice<!-- raw HTML omitted --> for StrV</li>
<li>Additional commits viewable in <a
href="https://github.com/gtk-rs/gtk-rs-core/compare/0.22.0...0.22.3">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-16 00:17:40 +00:00
Simon Wülker
708f5de35b script: Support constructing FontFaces from ArrayBuffers (#43281)
Testing: This change adds new tests
Fixes https://github.com/servo/servo/issues/39657
Part of https://github.com/servo/servo/issues/6098

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-15 22:13:56 +00:00
Simon Wülker
16a6494db5 script: Let FontFaceSet be setlike<FontFace> (#43286)
Testing: New tests start to pass.

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-15 21:59:54 +00:00
Domenico Rizzo
b3c8c50af8 script: Move drop logic for several WebGPU types to helper structs (#43288)
Implementing `Drop` for DOM types is being forbidden. This moves the
resource cleanup logic for `GPUShaderModule`, `GPUTexture`, and
`GPUTextureView` to separate helper structs and removes the
`allowDropImpl` flag from the bindings configuration.

Testing: WebGpu tests just cover their cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-15 20:33:07 +00:00
Sharan Poojari
ae08945a54 script: inline dispatch_load_event and dispatch_error_event (#43285)
fixes #43280 
This PR in lines the dispatch_load_event and dispatch_error_event
wrappers directly into their call sites and removes the unused function
definitions

Signed-off-by: SharanRP <z8903830@gmail.com>
2026-03-15 16:38:18 +00:00
Euclid Ye
c9c8e22abd script: Use &mut JSContext in HTMLMapElement&HTMLImageElement (#43284)
I just want to be part of the campaign.

Testing: It compiles.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
Co-authored-by: Sam <16504129+sagudev@users.noreply.github.com>
2026-03-15 16:02:40 +00:00
Tim van der Lippe
15b74e04b6 script: Record state for nodes prior to executing commands (#43177)
There is a chicken and egg problem here: to be able to restore the state
of nodes, we need the implementation of several other commands. However,
those commands then need some of the algorithms that are implemented for
storing the state.

Therefore, this PR has no behavioral changes, but includes preparations
to be able to first implement the functionality of the relevant
commands.

To that end, several changes were necessary:
1. Remove BaseCommand and instead use CommandName enum to define
behavior. The majority of the action part of the commands still exists
in separate files for readability (turn off whitespace changes in the
diff to make things readable)
2. Change the usages of a DOMString to the new CommandName enum in the
methods of execCommand. Both to make the enum work, but also as an
improvement to avoid operating on strings.
3. The {value,state}_override values in document need to be a map, not a
single boolean. I didn't understand these when I first implemented it,
but now it's clearer to me what their structure is.

In the end, the relevant recording and restoring state is implemented,
to the extent that it is possible. It does some light-weight
interaction, but most of the code doesn't do anything yet since the
relevant commands aren't implemented.

Part of #25005 

Testing: no behavioral changes, only preparations for future work

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-15 12:57:19 +00:00
Euclid Ye
0d764f0d20 script_bindings: Remove non-existent entries (#43282)
These methods do not exist in DOM.

Testing: It compiles.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-15 12:44:26 +00:00
Tim van der Lippe
058759bf06 script: Move debugger interfaces into debugger/ (#43279)
Part of #38901

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-15 10:19:33 +00:00
Tim van der Lippe
d952864be0 script: Pass &mut JSContext to set_timeout_or_interval (#43278)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-15 10:10:21 +00:00
Tim van der Lippe
36d70a1e5f script: Pass &mut JSContext to TrustedScript::can_compile_string_with_trusted_type (#43277)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-15 09:30:46 +00:00
Tim van der Lippe
f8b06d7291 script: Move reporting interfaces (#43270)
Also moves some relevant methods from GlobalScope that were only used
within ReportingObserver.

Part of #38901

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-15 09:01:23 +00:00
Simon Martin
23a23f41ae script: remove redundant ScriptWindowProxies method (#43276)
ScriptWindowProxies's find_window_proxy and get methods are exactly the
same; remove the latter.

Testing:  Existing WPT tests should cover the script_thread.rs change
Fixes: https://github.com/servo/servo/issues/43251

Signed-off-by: Simon Martin <simon@nasilyan.com>
2026-03-15 08:53:29 +00:00
Martin Robinson
3335d3df58 script: Add support for the "sequential focus navigation starting point" (#43267)
Add support for the "sequential focus navigation starting point" which
allows clicking on an unfocuable part of the part and then having
sequential focus start from that part when it is triggered later. In
addition:

1. Start moving the sequential focus code match the specification more
   more closely.
2. Generalize the
   `Element::find_click_focusable_shadow_host_if_necessary` method to be
   able to find the appropriate focuable area after a click and
   correctly handle clicking on children of focusable elements.

Testing: This adds two Servo-specific tests as sequential focus
navigation
behavior is so lightly specified. In addition, on WPT subtest starts to
fail
for `<label>`s in `<summary>`, but this just exposes existing issues we
have
with two unimplemented features:
1. Clicking on activable elements in `<summary>` should not expand the
    `<details>`.
2. Clicking on a `<label>` should activate its target.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-15 08:11:04 +00:00
Christian Duerr
cf908a8d6c servo: Fix minor documentation issues (#43229)
Signed-off-by: Christian Duerr <contact@christianduerr.com>
2026-03-15 06:00:15 +00:00
Euclid Ye
71907ee9fd webdriver: Wait for ImeEvent::Composition (#43275)
This continues #43262. Also added TODO.

Testing: Existing tests:
[Try](https://github.com/servo/servo/actions/runs/23089599333)

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-15 05:52:49 +00:00
Servo WPT Sync
2442ef7dc4 Sync WPT with upstream (15-03-2026) (#43274)
Automated downstream sync of changes from upstream as of 15-03-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
2026-03-15 01:33:03 +00:00
Tim van der Lippe
3c852261b9 script: Pass &mut JSContext in CSP code (#43184)
Part of #40600

Testing: it compiles

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-03-14 21:42:02 +00:00
webbeef
e56651ef7d chore: remove abbreviated crate names (#43272)
This remove `sm-player` and `sm-gst-render` that point to the same
crates as `servo-media-player` and `servo-media-gstreamer-render`

Testing: a successful build is enough

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-03-14 21:28:15 +00:00
Tim van der Lippe
d0d84f40c7 script: Move CSPViolationReportTask (#43269)
This was the only struct leftover in security_manager. Therefore, this
both moves and renames the files.

Part of #38901

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-14 19:43:24 +00:00
Tim van der Lippe
f660fd6d91 script: Pass &mut JSContext to TrustedHTML::get_trusted_type_compliant_string (#43268)
Part of #40600

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-14 19:40:49 +00:00
webbeef
1be2b7ad8d chore: replace references to servo_url by servo-url (#43273)
It was decided to keep the kebab-case version.

Testing: Successful compilation is enough

Signed-off-by: webbeef <me@webbeef.org>
2026-03-14 19:29:05 +00:00
Tim van der Lippe
7b73462755 ci: Resolve yanked crate violation (#43271)
Example:
https://github.com/servo/servo/actions/runs/23093323608/job/67081527566

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-14 18:37:41 +00:00
Christian Duerr
279a53e598 servo: Force embedders to implement EventLoopWaker::wake (#43250)
Currently it is possible to define an `EventLoopWaker` which does
nothing on `wake`, however there's no reason for a consumer to define a
waker that does nothing on wake, since that is its only purpose. To make
it a little bit harder to use the `EventLoopWaker` incorrectly, this
makes the `wake` function on the trait mandatory for downstream to
implement.

Testing: This just removes a default implementation for an exposed trait
and updates documentation so new tests are not necessary.

---------

Signed-off-by: Christian Duerr <contact@christianduerr.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-14 14:31:28 +00:00
Jonathan Schwender
fa899420c7 blurmac: Disable publishing (#43264)
`cargo publish --workspace` should ignore this crate, we currently don't
plan to release it.

Testing: Not tested

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-14 10:05:32 +00:00
Gae24
e8b581aaf0 script: Pass &mut JSContext in more places (#43252)
Continuation of #43220, removes many `temp_cx` calls introduced by that.

Testing: No behaviour change, a successful build is enough.
Fixes: #43241 #43240

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-14 10:03:48 +00:00
Euclid Ye
9cf33b773d webdriver: Always wait for mousemove/wheel in a blocking manner (#43262)
This is now possible since #43202. We remove the workaround introduced
long ago.

Testing: Before #43202, this would deadlock in many tests, and is
therefore covered by existing tests.
[Try](https://github.com/servo/servo/actions/runs/23080857516)

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-14 08:00:10 +00:00
Christian Duerr
58e7d14963 libservo: Expose StringRequest in public API (#43261)
This is a follow-up to 69d4353, which attempted to make the
`ClipboardDelegate` trait implementable, but missed that the
`StringRequest` type required by this trait was still private.

*Describe the changes that this pull request makes here. This will be
the commit message.*

Testing: I ran this against my browser to make sure this time pasting
works end-to-end, which it did. So hopefully this should be all.

Signed-off-by: Christian Duerr <contact@christianduerr.com>
2026-03-14 07:41:14 +00:00
Gae24
ef97d7e199 script: Pass &mut JSContext to VirtualMethods::bind_to_tree (#43220)
Testing: No behaviour change, a successful build is enough.
Fixes: #42838 #43239

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-14 07:37:47 +00:00
Jonathan Schwender
363ba0ccd1 Use workspace deps consistently and add version requirement (#43243)
In order to prepare for publishing this PR does the following steps (see
commits):

- Move all `path` dependencies to the workspace Cargo.toml, and
reference that.
- Move all path dependencies in the workspace Cargo.toml into a
dedicated section, to make bumping version numbers easier later.
- Add the version requirement. Note that we currently only version bump
servoshell. There was agreement to version everything with the same
version as servoshell, but that be done in a follow-up. The diff is
already large enough as is.
- Add a tidy lint to catch `path` usages outside the root Cargo.toml. I
switched to [`tomllib`] (which was added to the python stdlib in 3.11),
since the third-party `toml` library failed to parse Cargo.toml files
with `workspace.version` (did not like the `.` in a `key`).


[`tomllib`]: https://docs.python.org/3/library/tomllib.html

Testing: Should be covered by regular CI testing.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-14 06:51:33 +00:00
Euclid Ye
a10434cef4 ci: Bump ci-runners to f0b81b9 and upgrade remaining deprecated Actions (#43244)
This continues #43173, https://github.com/servo/ci-runners/pull/118

There are several warnings that cannot be solved here, and requires
original Action maintainers to take action:
- nick-fields
- KyleMayes/install-llvm
- bencher

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-14 02:08:56 +00:00
Martin Robinson
1a88675636 layout: Add a little padding to textual inputs (#43132)
This change adds a little bit of padding to textual inputs, so that it
is easier to see the text cursor and also to read the text contents.
The values here match what Gecko uses.

### Before

<img width="611" height="520" alt="Screenshot 2026-03-10 at 11 23 47"
src="https://github.com/user-attachments/assets/e2303fea-9060-45cd-a055-7d2081ea38fc"
/>

<img width="611" height="520" alt="Screenshot 2026-03-10 at 11 23 53"
src="https://github.com/user-attachments/assets/1ae58448-e198-4d24-941d-1d8c5f45e894"
/>

### After 

<img width="633" height="519" alt="Screenshot 2026-03-10 at 11 22 39"
src="https://github.com/user-attachments/assets/f4c38299-a222-40d1-96a1-85ee745ff7bd"
/>

<img width="616" height="518" alt="Screenshot 2026-03-10 at 11 37 20"
src="https://github.com/user-attachments/assets/45a295a9-5665-439d-bff4-eb7aaf51f994"
/>

Testing: This was manually tested via `form-control-visuals.html`. We do
not
really have a way to test this kind of styling.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 18:21:39 +00:00
Christian Duerr
e0e07f14ba embedder_traits: Add missing Debug impl to PixelFormat (#43249)
Testing: This just implements `Debug` on an API exposed type, so tests
are not necessary.

---------

Signed-off-by: Christian Duerr <contact@christianduerr.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 17:22:37 +00:00
Martin Robinson
eb249afac8 script: Scroll targets into view during sequential tab navigation (#43246)
Instead of just focusing elements that are the target of tab navigation,
also scroll them into view. Though this is unspecified, this is what all
other browsers do.

Testing: This change adds a new Servo-specific test. The behavior isn't
really specified.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 17:19:52 +00:00
Martin Robinson
4c6dbd59cb script: Only trigger one default event handler for form controls (#43247)
There is a `handle_event` virtual method on `Node` that triggers the
default event handler. Typically the "superclass" virtual method is
called and then the specific type runs its default event handler. This
isn't good for form controls, because typically the event handler should
prevent further event handlers from running. This badness can be
observed by pressing down in a text input, which will both move the
cursor as well as scroll the page. 🙃

This change makes it so that the default form control event handler
consistently calls the `Event::mark_as_handled` method and triggers the
"superclass" event handler *after* running its own. In addition, the
scrolling default event handler on `Node` now doesn't run if the `Event`
was already handled.

Finally, a little bit of dead event handling code is removed.

Testing: This change adds a Servo-specific test for this behavior.
Fixes: #40785

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 16:27:22 +00:00
Christian Duerr
9186a7efab servo: Add id method to InputMethodControl (#43248)
While it is possible to acquire the embedder ID through
`EmbedderControl::id`, it is no longer possible once the type is
destructured into `InputMethodControl`.

Since `InputMethodControl` stores the `id` field internally anyway, it
seems consistent with the other embedder controls to have a method to
return this ID.

Testing: This is a simple addition to the API, so tests are probably not
necessary.

Signed-off-by: Christian Duerr <contact@christianduerr.com>
2026-03-13 15:57:10 +00:00
eri
5c30339efc devtools: Remove reply_unchecked in favour of mark_handled (#43236)
`reply_unchecked` was added in #42007 since `getEnvironment` from the
frame actor has a `type` field but it already counts as a final reply,
unlike every other message like it. Since it is only used there, we can
revert the `reply_unchecked` change and use the new `mark_handled`
instead.

Depends on: #43230
Testing: DevTools tests

Signed-off-by: eri <eri@igalia.com>
2026-03-13 14:05:18 +00:00
Tim van der Lippe
b6ba612a54 script: Pass &mut JSContext to TrustedScriptURL::get_trusted_type_compliant_string (#43245)
Also rename the method and consolidate the sink to be consistent with
both `TrustedHTML` and `TrustedScript`

Part of #42638

Testing: It compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-13 13:56:46 +00:00
Gae24
048612fe84 script: Pass &mut JSContext to children_changed and adopting_steps (#43219)
Switch `VirtualMethods::children_changed` and
`VirtualMethods::adopting_steps` to `&mut JSContext`.

Testing: No behaviour change, a successful build is enough.
Part of #40600

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-13 13:40:40 +00:00
Jonathan Schwender
cd2c51bb3c config: Remove unused servo_url dependency (#43237)
Doesn't seem to be used in the crate anymore.

Testing: If it builds it works.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-13 12:20:28 +00:00
Tim van der Lippe
7a383bcc43 script: Pass &mut JSContext in trusted types interfaces (#43183)
Part of #40600

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-13 11:04:34 +00:00
Brent Schroeter
69a1f99bd2 devtools: Add support for one-way protocol messages (#43230)
Some Remote Debugging Protocol message types are specified as `oneway`,
meaning that they expect no reply. Sending anything—including an
error—in response to these messages throws the devtools client and actor
out of sync.

As noted in the `ClientRequest` docstring, most client messages expect
exactly one reply, so `ClientRequest::handle()` includes a fail-safe
that automatically sends an error message if none of the `reply()`,
`reply_unchecked()`, or `reply_final()` methods have been called.

This change introduces an additional method,
`ClientRequest::mark_handled()`, which allows the actor handling the
request to disarm the fail-safe without sending a reply over the wire,
and it adds handling logic for 3 one-way message types that are
frequently emitted by the Firefox Toolbox.

Testing: This change introduces no new tests. Unless we take the unusual
step of enumerating all supported one-way message types and validating
each, automated tests provide little assurance of correctness.
Meaningfully testing this feature would be cumbersome, and it would
likely hamper future development more than it would help.

Signed-off-by: Brent Schroeter <contact@brentsch.com>
2026-03-13 10:45:15 +00:00
Asset Malik
44a151f925 ohos: Add script to run blink perf tests on device (#42509)
CI: ohos blink_perf_test scenario

Background:
There are so called blink_perf_tests in the `tests/blink_perf_tests/`
that can be used to bench servo. Those are 100+ unitary test .html pages
that result in either "ms" or "runs/s".
There is also a python script that is currently used to run those tests
`etc/blink-perf-test-runner/main.py`, but it runs the tests on the host
(tested on linux).

Goal of this PR:
I want to also be able to run the tests on ohos. So I created a .py
script in etc/ci/scenario/ that is very similar to the script that is
already on servo. The script produces `results.json` and it can be
included into the bencher.dev ci and run on the ci ohos devices.

~~Testing: within `etc/ci/scenatio` directory do `uv run
blink_perf_test.py`~~
Testing: within servo project root do `UV_PROJECT=etc/ci/scenario uv run
etc/ci/scenario/blink_perf_test.py -vem`
For `help` use `-h`

---------

Signed-off-by: jane <5373400+janeoa@users.noreply.github.com>
Signed-off-by: Asset Malik <5373400+janeoa@users.noreply.github.com>
Co-authored-by: Narfinger <Narfinger@users.noreply.github.com>
Co-authored-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
2026-03-13 10:18:37 +00:00
Martin Robinson
ce952368f8 servo: Rename GamepadProvider to GamepadDelegate (#43233)
This makes the name of the `GamepadDelegate` consistent with the other
delegates.

Testing: No tests necessary as this is just renaming some structs and
members. Compilation should be enough.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 10:16:30 +00:00
Brent Schroeter
890ef58052 devtools: Use active pipeline and script channel in inspector actors (#43153)
The `InspectorActor` and its children now query the
`BrowsingContextActor` for the active pipeline ID and script sender
instead of storing their own copies, which become outdated on
navigation. Previously, the inspector remained permanently stuck to the
pipeline that was active upon launch. Now, connecting a fresh devtools
client session after navigation allows inspection of each
`BrowsingContext`'s active DOM.

Navigation within a continuous remote debugging session still breaks the
Firefox inspector panel. This is due to multiple compatibility issues
with the protocol implementation, which will be addressed in separate
PRs.

This PR does not touch `TimelineActor` or `FramerateActor`. These are
theoretically affected by the same issue as the `InspectorActor`, but in
practice neither is ever instantiated. It seems both have been
effectively unreachable code since 1aab10f2 and will require more
extensive work and testing that is beyond the scope of this change.

Testing: Updates to the `WalkerActor` and `BrowsingContextActor` are
unit tested via the new `test_walker_observes_new_dom_after_nav` case in
`devtools_tests.py`. There are no existing unit tests to reference for
the highlighter and style actors; these have been tested manually but
this PR does not introduce further automated tests. This PR also
improves handling of `tabNavigated` messages to simplify the unit test
written for 4c69d85.

---------

Signed-off-by: Brent Schroeter <contact@brentsch.com>
2026-03-13 10:13:55 +00:00
Taym Haddadi
628c9c1170 storage: construct and shut down public/private thread groups independently (#43147)
This PR makes public and private storage thread groups independent.

previously, `new_storage_threads()` returned two `StorageThreads`
handles, but both handles were backed by the same underlying storage
worker group. this meant Servo carried a public/private distinction
through the API and wiring layers, while both sides still talked to the
same storage backend threads.


Testing: Added shutdown_storage_group test, and should not effect WTP
test.

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-13 10:03:30 +00:00
Tim van der Lippe
af256bd6e5 script: Check for render-blocking documents before continuing (#43150)
The spec expects us to check for render blocking (among some other
state) before we start procesing a document. Therefore, add those checks
and also check in the
stylesheet loader that we should only do so when we are allowed to do
so.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-13 09:54:03 +00:00
Martin Robinson
5fec1395c9 prefs: Move Opts::print_pwm to DiagnosticsLogging::progressive_web_metrics (#43209)
This option controls whether progressive web metrics are printed to the
system console, which is essentially the purpose of
`DiagnosticsLogging`. This makes the API a bit more uniform.

Testing: We do not really have automated testing for this kind of
feature of the API.
Fixes: This is part of #34967.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 09:45:39 +00:00
Martin Robinson
6a20de06f4 servo: Set all delegates and GamepadProvider in WebViewBuilder (#43205)
This change makes it so that all of these things are set on the
`WebView` via the `WebViewBuilder`. This does make it impossible to
change the delegate after the `WebView` is constructed, but that does
mean that we can now count on that fact internally in Servo. This change
just seeks to standardize the way that these kind of structs are given
to Servo to make the API easier to understand.

Testing: There aren't currently tests for the clipboard delegate, but
this
change should work as the corresponding parts in servoshell still
compile.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-13 08:34:45 +00:00
Domenico Rizzo
b2ac181091 script: Move GPUSampler drop logic to a helper struct (#43222)
Implementing `Drop` for DOM types is being forbidden. This moves the
resource cleanup logic for `GPUSampler` to a separate
`DroppableGPUSampler` struct and removes the `allowDropImpl` flag from
the bindings configuration.

Testing: WebGpu tests just cover its cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-13 05:36:23 +00:00
Euclid Ye
97225f5537 script: Free memory earlier in hot path of input handling (#43226)
This is a hot path. This way we free the unused memory earlier.
Didn't realize the difference in #43202.

Testing: This is a memory optimization that does not change visible
behaviour.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-13 04:33:15 +00:00
dependabot[bot]
85eb3297f4 build: bump clap_lex from 1.0.0 to 1.1.0 (#43225)
Bumps [clap_lex](https://github.com/clap-rs/clap) from 1.0.0 to 1.1.0.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap_lex's
changelog</a>.</em></p>
<blockquote>
<h2>v1.1.0 (2015-07-16)</h2>
<h4>Features</h4>
<ul>
<li>allows creating unified help messages, a la docopt or getopts (<a
href="52bcd892ea">52bcd892</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/158">#158</a>)</li>
<li>allows stating all subcommands should <em>not</em> have --version
flags (<a
href="336c476f63">336c476f</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/156">#156</a>)</li>
<li>allows setting version number to auto-propagate through subcommands
(<a
href="bc66d3c6de">bc66d3c6</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/157">#157</a>)</li>
</ul>
<h4>Improvements</h4>
<ul>
<li><strong>Help Strings</strong> properly aligns and handles newlines
in long help strings (<a
href="f9800a2969">f9800a29</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/145">#145</a>)</li>
</ul>
<h4>Performance</h4>
<ul>
<li><strong>Help Messages</strong> big performance improvements when
printing help messages (<a
href="52bcd892ea">52bcd892</a>)</li>
</ul>
<h4>Documentation</h4>
<ul>
<li>updates readme with new features (<a
href="8232f7bb52">8232f7bb</a>)</li>
<li>fix incorrect code example for <code>App::subcommand_required</code>
(<a
href="8889689dc6">8889689d</a>)</li>
</ul>
<h2>v1.0.3 (2015-07-11)</h2>
<h4>Improvements</h4>
<ul>
<li><strong>Errors</strong> writes errors to stderr (<a
href="cc76ab8c2b">cc76ab8c</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/154">#154</a>)</li>
</ul>
<h4>Documentation</h4>
<ul>
<li><strong>README.md</strong> updates example help message to new
format (<a
href="0aca29bd5d">0aca29bd</a>)</li>
</ul>
<h2>v1.0.2 (2015-07-09)</h2>
<h4>Improvements</h4>
<ul>
<li><strong>Usage</strong> re-orders optional arguments and required to
natural standard (<a
href="dc7e1fcea5">dc7e1fce</a>,
closes <a
href="https://redirect.github.com/clap-rs/clap/issues/147">#147</a>)</li>
</ul>
<h2>v1.0.1 (2015-07-08)</h2>
<h4>Bug Fixes</h4>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="9ab6dee710"><code>9ab6dee</code></a>
chore: Release</li>
<li><a
href="374a30dac6"><code>374a30d</code></a>
docs: Update changelog</li>
<li><a
href="d0c8aabc00"><code>d0c8aab</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6306">#6306</a>
from epage/update</li>
<li><a
href="686ce2f665"><code>686ce2f</code></a>
chore: Upgrade compatible</li>
<li><a
href="8203238de6"><code>8203238</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/6305">#6305</a>
from epage/msrv</li>
<li><a
href="c774a892ba"><code>c774a89</code></a>
docs: Reduce main's in doctests</li>
<li><a
href="73534f6ed3"><code>73534f6</code></a>
chore: Upgrade to 2025 edition</li>
<li><a
href="dfe05a9bfe"><code>dfe05a9</code></a>
chore: Bump MSRV to 1.85</li>
<li><a
href="8b41d0b849"><code>8b41d0b</code></a>
chore: Release</li>
<li><a
href="518220f102"><code>518220f</code></a>
docs: Update changelog</li>
<li>Additional commits viewable in <a
href="https://github.com/clap-rs/clap/compare/clap_lex-v1.0.0...clap_lex-v1.1.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=clap_lex&package-manager=cargo&previous-version=1.0.0&new-version=1.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-13 00:45:28 +00:00
dependabot[bot]
b3fb348fa5 build: bump orbclient from 0.3.50 to 0.3.51 (#43224)
Bumps orbclient from 0.3.50 to 0.3.51.


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=orbclient&package-manager=cargo&previous-version=0.3.50&new-version=0.3.51)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-13 00:42:44 +00:00
Uiniel
0f5e02099b script: Move BlobMethods to &mut JSContext (#43215)
Move from CanGc to &mut js::context:JSContext. `ArrayBuffer` and `Bytes`
require many changes in `dom/stream` for which I'm going to create a
seperate pull request before porting the two methods.

Testing: Just a refactor, `./mach test-unit` still passes.
Fixes: Part of #42638

---------

Signed-off-by: Uiniel <174327181+uiniel@users.noreply.github.com>
2026-03-12 21:58:56 +00:00
Simon Wülker
020c651f21 script: Mark canvas as dirty after updating image data (#43218)
This makes https://theintraclinic.com/archive/minecraft4k-js/ work
correctly in servo.

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-12 20:04:21 +00:00
Jonathan Schwender
e7cac92e24 mach: Document -- interaction for clippy (#43221)
The same issue also affects check and other commands that support `--`,
but I'm not sure if it makes sense to document it everywhere.

Testing: Changes the help message, manual testing required.
Fixes: #43214

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-12 20:00:59 +00:00
Martin Robinson
c80bdd9c92 prefs: Remove Opts::nonincremental_layout (#43207)
This setting is used to control whether or not incremental legacy layout
was enabled. Nowadays incremental layout is always enabled as it is a
fundamental feature of how layout works. The setting also controls
whether or not nodes are traversed in Style, but that's also something
that's much less interesting today. This change just removes this
setting as it just controls the Stylo setting. A corresponding change in
Stylo will also remove the setting there.

Testing: This just removes a setting so existing tests should suffice.
Fixes: This is part of #34967.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-12 16:03:43 +00:00
Taym Haddadi
eabf3c70bb constellation(storage): validate storage event source and scope session fanout by webview (#43096)
Follow the spec and tightenings storage event routing in Constellation
by validating that a BroadcastStorageEvent comes from the same origin as
its source pipeline, while preserving existing localStorage fanout
behavior.

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-12 15:14:55 +00:00
Simon Wülker
c0ff7c1fc9 Everywhere: Remove instances of clippy::redundant-clone (#43212)
This change fixes all instances where
[`clippy::redundant-clone`](https://rust-lang.github.io/rust-clippy/master/index.html?groups=complexity%2Ccorrectness%2Cnursery%2Csuspicious&levels=allow#redundant_clone)
would trigger. It's allowed by default

I've also changed the lint to warn-by-default for servo.

Testing: Covered by WPT

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-12 13:28:21 +00:00
Oriol Brufau
3c86026ef1 layout: Set text-indent: 0 in UA styles for ::marker (#43201)
Authors can't set `text-indent` directly to a `::marker`, but it was
inheriting from the list item. This was causing undesirable behaviors on
markers with an outside position and a different `direction` than the
list item.

This matches other browsers:
 - Gecko: https://hg.mozilla.org/mozilla-central/rev/4366cfed8144
 - Blink: https://crrev.com/803126
 - WebKit: https://commits.webkit.org/296253@main

Testing: Improves WPT

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-12 13:20:08 +00:00
Bruno Nicoletti
3a680c5389 script: Use the shared task canceller in DedicatedWorkerGlobalScope::run_worker_scope (#43213)
Replaces the default task canceler with the shared task canceler found
in the global scope.

Testing: #42536 specifies that building is enough.
Fixes: #42536

Signed-off-by: Bruno Nicoletti <1868608+bruno-j-nicoletti@users.noreply.github.com>
2026-03-12 13:20:00 +00:00
eri
f53a259216 devtools: Handle getEnvironment message (#43167)
Initial work to support scopes in the debugger. They don't show at the
moment since we are not processing variables yet. Depends on #43166.

Testing: Ran `mach test-devtools` and manual testing.
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-12 13:13:03 +00:00
Euclid Ye
e88c5dd752 script: Notify embedder coalesced events to resolve potential WebDriver deadlock (#43202)
Notify embedder the coalesced wheel/mousemove event.

We also stop cloning every single entry in `pending_input_event`.

Testing: This should unblock the potential WebDriver thread deadlock
when receiving simultaneous wheel or pointer inputs from multiple
sources.
We added a new test that stably deadlock on
74c16ffd8a.
Firefox/Safari/Chrome all pass the new test.
Fixes:
https://github.com/servo/servo/issues/43136#issuecomment-4031702204

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-12 12:40:04 +00:00
Martin Robinson
ea995155f8 paint: Add support for a blinking text caret (#43128)
This change adds support for a blinking text caret using WebRender
`DynamicProperties` updates. This ensures that text caret updates are as
lightweight as possible. As part of this change, the initial framework
for paint-side animations is added. Though this is driven by a timer for
now (in order to not have to run full speed animations for text carets),
the idea is that more animations can be driven by `Paint` in the future
(in order to avoid doing layouts during animations).

In addition, a preference is added which controls the caret blink speed.
This is used to disable caret blinking during WPT testing.

Testing: There are no tests for this change. We do not currently have a
good
way to test caret blinking as the caret is render only and fully testing
blinking would require well timed screenshot creation.
Fixes: #33237.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-12 11:47:46 +00:00
Euclid Ye
a30bdc1870 embedder_traits: Specify clearly what the sign of WheelDelta means (#43210)
Right now this is not documented and really confusing. I believe these
decisions
are made to align with
[winit](e9809ef54b/src/event.rs (L957-L958)):
> /// Positive values indicate that the content that is being scrolled
should move
> /// right and down (revealing more content left and up).

I don't know about other people emebedding Servo, but I have always been
thinking reversely.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-12 10:46:03 +00:00
Martin Robinson
8432a21d63 prefs: Move Opts::user_stylesheets to ServoShellPreferences (#43206)
This concept does not need to be exposed to `Opts` any longer as it just
controls how servoshell uses the `WebView` API.

Testing: A successful compilation is enough here as this is just moving
an option.
Fixes: This is part of #34967.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-12 10:28:02 +00:00
Jonathan Schwender
961b618a98 libservo: Remove dependency on gstreamer.py (#43165)
A published or vendored package will not have access to gstreamer.py.
Hence, we move the package list into libservo, and modify the remaining
usage of gstreamer.py (in mach) to read the same list.


Testing: Covered by CI testing, which involves building servo and the
macos dmg and windows installer.

Fixes: Part of #43145

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-12 06:31:03 +00:00
Josh Matthews
69d4353eca libservo: Expose ClipboardDelegate in public API. (#43203)
Per [#embedding > Miscellaneous Embedding
Questions](https://servo.zulipchat.com/#narrow/channel/437943-embedding/topic/Miscellaneous.20Embedding.20Questions/with/578835363),
it is impossible to call `WebView::set_clipboard_delegate` because the
ClipboardDelegate trait is not exposed in the public embedding API.

Testing: Compile-only, and doesn't feel worth implementing additional
functionality in servoshell to verify this.

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-12 06:06:27 +00:00
Luke Warlow
a27bd9dde7 prefs: Remove dom_command_invokers_enabled (#43190)
Remove command invokers preference

This now passes most of the relevant tests. Most of the remaining
failures are due to missing functionality such as the popover API,
element reflection properties (see
https://github.com/servo/servo/issues/42884), and issues with the event
retargeting code that doesn't handle shadow dom correctly.

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-12 06:03:26 +00:00
Jonathan Schwender
9069043477 Move ply and WebIDL into script_bindings (#43180)
This is required to publish script_bindings, since all files used during
codegen need to be there.
It might also be possible to generate the bindings ahead of time and
vendor them in-tree, but this seems painful to setup from a CI
perspective.
Since there don't seem to be any other users in-tree we can just vendor
into the script-bindings directory.

`ply` is licensed under the BSD 3 clause, and WebIDL under MPL-2.0, with
the licenses available in our cargo package. Both tools won't end up in
`servo` since they are build-time dependencies, so I believe we don't
need to adjust the crate license, or configure `about.toml`.

Testing: Should be covered by existing tests. We don't test if this
allows vendored builds or published builds.
Fixes: Partial fix for #43145

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-12 05:44:46 +00:00
dependabot[bot]
74c16ffd8a build: bump quick_cache from 0.6.18 to 0.6.19 (#43200)
Bumps [quick_cache](https://github.com/arthurprs/quick-cache) from
0.6.18 to 0.6.19.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/arthurprs/quick-cache/releases">quick_cache's
releases</a>.</em></p>
<blockquote>
<h2>v0.6.19</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix cache with weight_capacity=1 silently storing nothing by <a
href="https://github.com/arthurprs"><code>@​arthurprs</code></a> in <a
href="https://redirect.github.com/arthurprs/quick-cache/pull/106">arthurprs/quick-cache#106</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.18...v0.6.19">https://github.com/arthurprs/quick-cache/compare/v0.6.18...v0.6.19</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="90fcb726b6"><code>90fcb72</code></a>
0.6.19</li>
<li><a
href="6cdf3fbadd"><code>6cdf3fb</code></a>
Fix cache with weight_capacity=1 silently storing nothing (<a
href="https://redirect.github.com/arthurprs/quick-cache/issues/106">#106</a>)</li>
<li>See full diff in <a
href="https://github.com/arthurprs/quick-cache/compare/v0.6.18...v0.6.19">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quick_cache&package-manager=cargo&previous-version=0.6.18&new-version=0.6.19)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-12 00:51:25 +00:00
dependabot[bot]
c0a62e10be build: bump libz-sys from 1.1.24 to 1.1.25 (#43199)
Bumps [libz-sys](https://github.com/rust-lang/libz-sys) from 1.1.24 to
1.1.25.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libz-sys/releases">libz-sys's
releases</a>.</em></p>
<blockquote>
<h2>1.1.25</h2>
<h2>What's Changed</h2>
<ul>
<li>Bump the github-actions group across 1 directory with 2 updates by
<a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/238">rust-lang/libz-sys#238</a></li>
<li>Bump the github-actions group with 2 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/239">rust-lang/libz-sys#239</a></li>
<li>Bump actions/download-artifact from 4.2.1 to 4.3.0 in the
github-actions group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/240">rust-lang/libz-sys#240</a></li>
<li>fix: Remove forcing static builds when cross-compiling by <a
href="https://github.com/polarathene"><code>@​polarathene</code></a> in
<a
href="https://redirect.github.com/rust-lang/libz-sys/pull/244">rust-lang/libz-sys#244</a></li>
<li>update to <code>zlib-ng</code> version <code>2.2.5</code> by <a
href="https://github.com/folkertdev"><code>@​folkertdev</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/251">rust-lang/libz-sys#251</a></li>
<li>Bump the github-actions group across 1 directory with 3 updates by
<a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/250">rust-lang/libz-sys#250</a></li>
<li>fix: Support opt-out of static linking via
<code>LIBZ_SYS_STATIC=0</code> by <a
href="https://github.com/polarathene"><code>@​polarathene</code></a> in
<a
href="https://redirect.github.com/rust-lang/libz-sys/pull/252">rust-lang/libz-sys#252</a></li>
<li>Bump actions/checkout from 5.0.0 to 6.0.0 in the github-actions
group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/253">rust-lang/libz-sys#253</a></li>
<li>Bump actions/checkout from 6.0.0 to 6.0.1 in the github-actions
group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/254">rust-lang/libz-sys#254</a></li>
<li>Bump the github-actions group with 2 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/255">rust-lang/libz-sys#255</a></li>
<li>Bump actions/checkout from 6.0.1 to 6.0.2 in the github-actions
group by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/256">rust-lang/libz-sys#256</a></li>
<li>upgrade to zlib-ng 2.3.3 by <a
href="https://github.com/folkertdev"><code>@​folkertdev</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/257">rust-lang/libz-sys#257</a></li>
<li>release using zlib-ng version 2.3.3 by <a
href="https://github.com/folkertdev"><code>@​folkertdev</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/258">rust-lang/libz-sys#258</a></li>
<li>Bump the github-actions group with 2 updates by <a
href="https://github.com/dependabot"><code>@​dependabot</code></a>[bot]
in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/261">rust-lang/libz-sys#261</a></li>
<li>Bump zlib submodule to 1.3.2 by <a
href="https://github.com/dalvescb"><code>@​dalvescb</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/259">rust-lang/libz-sys#259</a></li>
<li>Bump version to 1.1.25 by <a
href="https://github.com/dalvescb"><code>@​dalvescb</code></a> in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/262">rust-lang/libz-sys#262</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/polarathene"><code>@​polarathene</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/244">rust-lang/libz-sys#244</a></li>
<li><a href="https://github.com/dalvescb"><code>@​dalvescb</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/libz-sys/pull/259">rust-lang/libz-sys#259</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/libz-sys/compare/1.1.22...1.1.25">https://github.com/rust-lang/libz-sys/compare/1.1.22...1.1.25</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="34bbe0ce68"><code>34bbe0c</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/libz-sys/issues/262">#262</a>
from dalvescb/version-bump</li>
<li><a
href="c0563739c6"><code>c056373</code></a>
bump version to 1.1.25</li>
<li><a
href="b19d27891e"><code>b19d278</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/libz-sys/issues/259">#259</a>
from dalvescb/curtisd/bump_zlib</li>
<li><a
href="a6d9cc1b59"><code>a6d9cc1</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/libz-sys/issues/261">#261</a>
from rust-lang/dependabot/github_actions/github-actio...</li>
<li><a
href="b123c95cd6"><code>b123c95</code></a>
Fix build after most recent <code>ZLIB</code> update to 1.3.2</li>
<li><a
href="18c87003c9"><code>18c8700</code></a>
Bump the github-actions group with 2 updates</li>
<li><a
href="f7636041e9"><code>f763604</code></a>
retrigger CI</li>
<li><a
href="6a12c357f8"><code>6a12c35</code></a>
bump zlib submodule to 1.3.2</li>
<li>See full diff in <a
href="https://github.com/rust-lang/libz-sys/compare/1.1.24...1.1.25">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libz-sys&package-manager=cargo&previous-version=1.1.24&new-version=1.1.25)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-12 00:41:37 +00:00
Simon Wülker
333e195845 script: Log uncaught JS exceptions to the console (#43191)
The script execution code has changed a bit in the last months so some
things that used to work don't anymore.

This change ensures that when an exception is thrown it is logged to the
console.

Testing: Regressions are covered by wpt, but we can't run tests for the
presence of `log::error!` calls

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-11 21:40:54 +00:00
Martin Robinson
f0c5b37c24 wpt: Use the default Servo user agent for WPT tests (#43185)
Some WPT tests [^1] rely on the user agent reflecting that of a real
browser or platform. This change makes it so that the user agent that
Servo uses when running the WPT is the default one, which includes the
platform.

[^1]:
aae5c4cd97/tests/wpt/tests/resources/accesskey.js (L16)

Testing: This causes some access key tests to pass on macOS.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-11 19:16:38 +00:00
Luke Warlow
e752359bbd script: Account for multiple in <input type=file> text (#43186)
File input button and description text now accounts for multiple file
support.

Testing: Manual test via https://demo.lukewarlow.dev/css-forms.html

<img width="214" height="131" alt="image"
src="https://github.com/user-attachments/assets/4894bca6-2d56-4d48-ac10-96f23fd70f2c"
/>

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-11 19:03:51 +00:00
Martin Robinson
4659dacf64 script: Simplify the KeyboardEvent constructor (#43187)
Simplify the `KeyboardEvent` constructor by taking the actual
`keyboard_types` `KeyboardEvetnt` as an argument. This means that we do
not have to repeat the logic for extracting all the data from the
platform event.

Testing: This should not change behavior and is thus covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-11 19:01:52 +00:00
Jonathan Schwender
04ca254f84 devcontainer: Use new prebuilt devcontainer image. (#43139)
Follow-up to #43131.

Testing: Tested locally. Note: This only works for x86_64 based systems.
Arm Linux users will need to build from source, but building in the
devcontainer on arm linux is anyway not working currently.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-11 17:27:32 +00:00
Tim van der Lippe
aae5c4cd97 script: Move Trusted Types interfaces to script/dom/trustedtypes (#43181)
Part of #38901 

Testing: it compiles

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-11 16:26:56 +00:00
Simon Wülker
c84edc0403 script: Fire an error event when event handler fails to compile (#43178)
For the longest time we've had a `dispatch_event` boolean flag in our
error reporting code that determines whether or not to fire an `error`
event. It was only set to `false` in the event handler code due to a
double borrow that would occur otherwise. It seems that this is no
longer a problem, so we can remove the flag and correctly fire the event
in that case too.

Testing: A new test starts to pass and
`html/webappapis/scripting/processing-model-2/runtime-error-in-body-onerror.html`
does not crash
Fixes: https://github.com/servo/servo/issues/13152

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-11 15:52:38 +00:00
eri
948859b2fe devtools: Allow registering environment actor from debugger.js (#43166)
This functionality will be used in a follow up patch to implement the
getEnvironment message.

Testing: Check `mach test-devtools` and manual test
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-11 15:45:35 +00:00
minghuaw
3a50ff1c10 layout: Add initial support for first-letter pseudo element (#43027)
This and the accompanying stylo PR
(https://github.com/servo/stylo/pull/320) is a partial implementation of
the `first-letter` pseudo element.

Testing: Existing WPT tests. There is one WPT test
(fcp-typographic-pseudo.html) that servo currently fails would timeout
with this PR because opacity of `TextFragment` is taken from the
`InlineFormattingContext` instead of the pseudo element.
Fixes: #43008 
Part of: #15413

---------

Signed-off-by: Minghua Wu <michael.wu1107@gmail.com>
Signed-off-by: minghuaw <michael.wu1107@gmail.com>
Signed-off-by: Oriol Brufau <obrufau@igalia.com>
Co-authored-by: Xiaocheng Hu <xiaochengh.work@gmail.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-11 15:30:15 +00:00
Luke Warlow
307ee6a1c5 layout: Paint the <select> chevon using an SVG (#43175)
Previously there were two issues:

1. The select chevron had a 4px margin which should have just applied to
the inline axis.
2. The chevron character had odd font metrics, so even once the margin
is fixed the select is still too tall.

This is fixed by using an SVG as a background-image instead of using the
▾ character.

Testing: Tested with https://demo.lukewarlow.dev/css-forms.html (and the
test case added in https://github.com/servo/servo/pull/42085).

| Before | After |
| ------|------|
| <img width="522" height="267" alt="image"
src="https://github.com/user-attachments/assets/7cc2d840-3384-4a6c-8945-0277cfb4096d"
/> | <img width="509" height="250" alt="image"
src="https://github.com/user-attachments/assets/99742dca-3ce6-4964-98bd-0cdbf3e14937"
/> |

---------

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-11 13:56:32 +00:00
Oriol Brufau
a8142546ca Improve list-style-type and counter styles (#43111)
Bumps Stylo to https://github.com/servo/stylo/pull/329, and modifies the
code accordingly:
- Implements basic `counter()` and `counters()`, instead of treating
them as empty string.
- For `list-style-type`, uses normal space instead of non-breaking space
in the suffix, since `::marker` has `white-space: pre` anyways.
`counter()` and `counters()` don't get a suffix.
- Changes `disclosure-closed` to use ▸ (U+25B8 Black Right-Pointing
Small Triangle) instead of ‣ (U+2023 Triangular Bullet).
- Implements `list-style-type: <string>`.
- Implements basic `<counter-style-name> | <symbols()>` for both
counters and `list-style-type`.

However, since `@counter-style` and `counter-*` properties are still
unsupported, non-predefined keywords just default to decimal, and
counters are assumed to have a value of 0.

The UA stylesheet is tweaked to avoid a problem when `list-style-type`
is set to a string with multiple lines.

Testing: 63 tests improve, 17 tests worsen (they were falsely passing
beforehand)
- #43117
-
`tests/wpt/tests/css/css-lists/content-property/marker-text-matches-circle.html`
-
`tests/wpt/tests/css/css-lists/content-property/marker-text-matches-disc.html`
-
`tests/wpt/tests/css/css-lists/content-property/marker-text-matches-square.html`
- #43118
  - `tests/wpt/tests/css/css-lists/nested-marker-dynamic.html`
  - `tests/wpt/tests/css/css-lists/nested-marker.html`
- #43036
-
`tests/wpt/tests/css/css-lists/list-style-type-decimal-line-height.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-002.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-003.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-003b.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-004.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-005.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-015.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-016.html`
  - `tests/wpt/tests/css/css-pseudo/marker-content-018.html`
- #30365
-
`tests/wpt/tests/css/css-pseudo/marker-font-variant-numeric-default.html`
  - `tests/wpt/tests/css/css-pseudo/marker-line-height.html`
- #43119
  - `tests/wpt/tests/css/css-pseudo/marker-tab-size.html`

Fixes: #43037

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-11 13:21:19 +00:00
Euclid Ye
c242860f0e ci: Upgrade soon deprecated GitHub Actions (#43173)
I got so many warnings about [Node 20
EOL](https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/)
in the [try](https://github.com/servo/servo/actions/runs/22945103342):

> The following actions are running on Node.js 20 and may not work as
expected...

We avoid touching those actions forked from web-platform-tests.

Testing: If this can merge, it is successful.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-11 11:02:42 +00:00
Euclid Ye
0153f2ff0a embedder_traits: Upgrade InputEventHandled to InputEventsHandled to batch IPC response (#43169)
We send back input events handling results in batch. This reduces IPC,
and make the following **TODO** possible in a follow-up.

Testing: I hope existing tests results won't change.
Part of
https://github.com/servo/servo/issues/43136#issuecomment-4031915873
**TODO**: We have not done 
> collect ids and send back a reply for each of them once the coalesced
event has been handled.

yet.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-11 10:14:25 +00:00
Jonathan Schwender
fca0a2555e deny.toml: Clarify time-rs CVE. (#43148)
The CVE doesn't impact us, so we can ignore it safely. This improves the
comment above the ignored entry in deny.toml. We test our own code via
`clippy` and we aren't using the vulnerable type. Our dependencies could
in theory use it, but that seems rather unlikely.

Testing: test-tidy is tested in CI.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-11 09:42:41 +00:00
shuppy
f9fd3968e5 Fix -p servo lib target build (and fix CI check accordingly) (#43170)
the `-p servo` (formerly libservo) lib target was busted for anyone
genuinely consuming it as a library, but we didn’t catch it because the
CI job designed to check it built `-p servo` with --all-targets, which
unlike library consumers pulls in [dev-dependencies].

this patch fixes the compile error, and fixes the CI check to build `-p
servo` in a more realistic configuration.

Testing: tested in CI, and locally with `cargo build -p servo --locked`
Fixes: #43168

Signed-off-by: delan azabani <dazabani@igalia.com>
2026-03-11 09:21:59 +00:00
Jonathan Schwender
26e724bd83 ci: Upload ohos nightly with correct path (#43164)
#43114 made the action error if the artifact is not found, which exposed
an issue with uploading the wrong path. We don't really care about
uploading the x86_64 version of the ohos library, since it is not used
in the release (not now at least), but it's better to fix the condition
anyway.
Fixes nightly upload failures like in
https://github.com/servo/servo/actions/runs/22927035640/job/66539862051

Testing: Not tested

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-11 06:45:47 +00:00
Tim van der Lippe
c1c5e9373c script: Complete basic implementation of delete command (#43082)
While we are not there yet, this is the majority of the implementation
of the delete command.

What's missing:
1. Handling of style attributes (most of the test failures)
2. Handling of lists

Since these are quite complicated on their own, deferring that to their
own PR.

Also added more assertions regarding parent nodes, which should always
exist in the spec. By adding those, discovered that the logic for
`is_visible` was wrong where its display value wasn't checked for
`"none"`.

Part of #25005

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-11 06:06:51 +00:00
Euclid Ye
605291b7e0 webdriver: Support interspersed scroll actions via event queue (#43126)
Scroll and PointerMove is quite similar. We did so for `PointeMove` in
https://github.com/servo/servo/pull/42289 +
https://github.com/servo/servo/pull/42946.

Imagine having 3 non-zero duration scroll actions with origin at
different Elements.
Previously we would wait for one to be fully dispatched before moving to
next action,
instead of interspersed.

We also consolidate `PendingPointerMove` and
newly added `PendingScroll` into `enum PendingActions`.

Testing: 
[Existing tests behaviour not
changing.](https://github.com/servo/servo/actions/runs/22887005716).
Added a wdspec test.
Previously: `['wheel', 'wheel', 'wheel', 'wheel', 'wheel', 'wheel',
'wheel', 'wheel', 'wheel', 'move']`
Now: `['wheel', 'move', 'wheel', 'move', 'wheel', 'move', 'move',
'wheel', 'wheel', 'move', 'move', 'wheel', 'wheel', 'move', 'move',
'wheel']`

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-11 03:43:39 +00:00
dependabot[bot]
72cab0da23 build: bump schannel from 0.1.28 to 0.1.29 (#43156)
Bumps [schannel](https://github.com/steffengy/schannel-rs) from 0.1.28
to 0.1.29.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="ff7ffd3061"><code>ff7ffd3</code></a>
Release v0.1.29</li>
<li><a
href="3530cff984"><code>3530cff</code></a>
Merge pull request <a
href="https://redirect.github.com/steffengy/schannel-rs/issues/121">#121</a>
from nateprewitt/fix_tls13_data_corruption</li>
<li><a
href="a13669743d"><code>a136697</code></a>
add test for tls renegotiation (TLS1.3, <a
href="https://redirect.github.com/steffengy/schannel-rs/issues/121">#121</a>)</li>
<li><a
href="6e817dbd9c"><code>6e817db</code></a>
Fix TLS 1.3 data corruption from double-send during renegotiation</li>
<li><a
href="f75095d87c"><code>f75095d</code></a>
Merge pull request <a
href="https://redirect.github.com/steffengy/schannel-rs/issues/120">#120</a>
from steffengy/feature/119-wrong-ncrypt-check</li>
<li><a
href="42692500ff"><code>4269250</code></a>
Fix condition <a
href="https://redirect.github.com/steffengy/schannel-rs/issues/119">#119</a>
for CERT_NCRYPT_KEY_SPEC check</li>
<li><a
href="6cc5637214"><code>6cc5637</code></a>
Merge pull request <a
href="https://redirect.github.com/steffengy/schannel-rs/issues/117">#117</a>
from 42triangles/master</li>
<li><a
href="ed24fe264b"><code>ed24fe2</code></a>
Use <code>package.include</code> to only include necessary data for
using the crate</li>
<li>See full diff in <a
href="https://github.com/steffengy/schannel-rs/compare/v0.1.28...v0.1.29">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=schannel&package-manager=cargo&previous-version=0.1.28&new-version=0.1.29)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-11 03:38:56 +00:00
Shubham Gupta
8d46c1b449 paint: Clamp initial-scale while processing ViewportDescription (#42922)
We can clamp the `initial-scale` while processing `ViewportDescription`.
No need to have a long route to clamp it and removes circular
dependency.

Testing: This is just a minor refactoring. No change in behavior
expected.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-11 01:57:17 +00:00
Martin Robinson
f6aa72146d script: Correct equality check when detecting whether element has access key assigned (#43144)
The equality check used to detect whether an element has an access key
assigned was reversed. This meant that access keys did not work on
non-form control elements. This change fixes the equality sign and adds
a test for this behavior.

Testing: A new Servo-specific test is added. Access key behavior
activation
behavior is very lightly specified so the way we deal with it is
Servo-specific at the moment.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-11 01:19:29 +00:00
dependabot[bot]
7a9e3a7bbc build: bump inotify from 0.11.0 to 0.11.1 (#43157)
Bumps [inotify](https://github.com/hannobraun/inotify) from 0.11.0 to
0.11.1.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/hannobraun/inotify-rs/blob/main/CHANGELOG.md">inotify's
changelog</a>.</em></p>
<blockquote>
<h2>v0.11.1 (2026-03-06)</h2>
<ul>
<li>Make improvements to documentation (<a
href="https://redirect.github.com/hannobraun/inotify/issues/224">#224</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/226">#226</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/228">#228</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/239">#239</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/240">#240</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/244">#244</a>)</li>
<li>Add <code>EventMask::parse</code> and <code>ParsedEventMask</code>
(<a
href="https://redirect.github.com/hannobraun/inotify/issues/236">#236</a>,
<a
href="https://redirect.github.com/hannobraun/inotify/issues/238">#238</a>)</li>
</ul>
<p><a
href="https://redirect.github.com/hannobraun/inotify/issues/224">#224</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/224">hannobraun/inotify-rs#224</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/226">#226</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/226">hannobraun/inotify-rs#226</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/228">#228</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/228">hannobraun/inotify-rs#228</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/236">#236</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/236">hannobraun/inotify-rs#236</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/238">#238</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/238">hannobraun/inotify-rs#238</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/239">#239</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/239">hannobraun/inotify-rs#239</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/240">#240</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/240">hannobraun/inotify-rs#240</a>
<a
href="https://redirect.github.com/hannobraun/inotify/issues/244">#244</a>:
<a
href="https://redirect.github.com/hannobraun/inotify-rs/pull/244">hannobraun/inotify-rs#244</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="425d4e130c"><code>425d4e1</code></a>
Update version</li>
<li><a
href="c388f0a447"><code>c388f0a</code></a>
Update changelog</li>
<li><a
href="9df4910a7b"><code>9df4910</code></a>
Auto-format <code>CHANGELOG.md</code></li>
<li><a
href="24c6e4809d"><code>24c6e48</code></a>
Merge pull request <a
href="https://redirect.github.com/hannobraun/inotify/issues/248">#248</a>
from WhyNotHugo/now_or_never</li>
<li><a
href="34ca041657"><code>34ca041</code></a>
Test draining without blocking</li>
<li><a
href="0c57af978f"><code>0c57af9</code></a>
Merge pull request <a
href="https://redirect.github.com/hannobraun/inotify/issues/243">#243</a>
from WhyNotHugo/test-delete</li>
<li><a
href="c5617bddcb"><code>c5617bd</code></a>
Add test for DELETE and DELETE_SELF events</li>
<li><a
href="5aae461996"><code>5aae461</code></a>
Merge pull request <a
href="https://redirect.github.com/hannobraun/inotify/issues/244">#244</a>
from WhyNotHugo/warn-vec</li>
<li><a
href="fb88cce94c"><code>fb88cce</code></a>
Warn about using Vec::with_capacity(4096) as buffer</li>
<li><a
href="7ef750bfc7"><code>7ef750b</code></a>
Merge pull request <a
href="https://redirect.github.com/hannobraun/inotify/issues/240">#240</a>
from JackDyre/event-into-stream-docs</li>
<li>Additional commits viewable in <a
href="https://github.com/hannobraun/inotify/compare/v0.11.0...v0.11.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=inotify&package-manager=cargo&previous-version=0.11.0&new-version=0.11.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-11 01:00:14 +00:00
Oriol Brufau
517262fb34 deps: Bump Stylo to "Share Device logic among Gecko and Servo" (#43146)
Stylo PR: https://github.com/servo/stylo/pull/330

Testing: Not needed, no behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-10 21:08:29 +00:00
Simon Wülker
2697f3a91a script: Accurately measure timing of DOMContentLoaded event (#43151)
We should measure the time it takes to fire the `DOMContentLoaded`
event, but we were including the time it takes for the task on the
relevant task source to be run.

Testing: The timing should be slightly more accurate but that is hard to
measure or test for. Therefore this PR does not include a test.

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-10 20:58:10 +00:00
Jonathan Schwender
e23f052412 Rename libservo to servo (#43141)
As discussed on zulip we would like to rename `libservo` to `servo`
(again) before a future crates.io release.
Servo is a library, so the `lib` prefix is somewhat redundant. We
already renamed the binary of ServoShell to `servoshell`, to reduce
confusion of users of what servo is.

Note: This PR does not touch all occurrences of `libservo`. Specifically
CI job names remain untouched, since the risk of breaking something is
higher here, harder to test for and the name not user facing.

Testing: CI testing of this change should give us good confidence.
Manual testing of `./mach doc` and `./mach build` showed no issues on
macos. [Full try
run](https://github.com/jschwe/servo/actions/runs/22909562747)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-10 20:55:14 +00:00
Gae24
4ef22ed227 script: Pass &mut JSContext to VirtualMethods::cloning_steps and Node::clone (#43130)
Continuation of #43108, two new `temp_cx()` calls were required:
- inside `maybe_clone_an_option_into_selectedcontent` since it's part of
a markup5ever trait
- inside `serialize_and_cache_subtree` replacing a `CanGc::note()` call,
propagating it inside reflow code will require even more effort.

Testing: No behaviour change, a successful build is enough.
Part of #40600

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-10 17:05:34 +00:00
Gae24
bc1cd2ceeb script: bump mozjs to use SpiderMonkey 140.8 and set more compile options (#43020)
Set `mutedErrors_`, `noScriptRval`, `isRunOnce` compile options.

Testing: A test now passes
Part of #38378

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-10 17:02:19 +00:00
atbrakhi
ed3e63d054 devtools: create helper functions to reduce duplication in tests (#43140)
Create helper functions to reduce boilerplate in some tests

Testing: All tests are passing
Fixes: See comment
https://github.com/servo/servo/pull/43135#pullrequestreview-3921936566

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-10 15:43:22 +00:00
Jonathan Schwender
08e6bad428 ci: No longer upload legacy GitHub release assets (#43137)
We previously changed the asset name format in
84d0919a7f.
We kept the old asset name to support bisection scripts. It's been 5
months since that change, so remove the old asset names.

Note: We never changed the asset names for our S3 upload, and this PR
doesn't touch S3.

Testing: Not tested, trivial change.
Fixes: #42101

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-10 15:43:16 +00:00
Simon Wülker
c37ae57a0d script: Only send objects with ESClass::Object to devtools (#43133)
We should only send previews of ordinary objects[^1] (i think that's the
correct term) objects to the devtools. The code is not designed to
handle other objects, which currently causes crashes.

Testing: This change adds a devtools test that crashes without this
change.

[^1]: https://tc39.es/ecma262/#ordinary-object

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-10 15:19:03 +00:00
Euclid Ye
67e54cc61d script: Replace the InputEventId of existing_constellation_wheel_event when coalescing wheel events (#43138)
Basically, any testdriver tests with scroll duration 
more than `16ms` can be intermittent due to this.

Fixes: #43136
Fixes: #43110
Testing: This fixes the issue where newly added test 
in #43126 randomly TIMEOUT with very high probability: 
https://github.com/servo/servo/actions/runs/22906496902

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-10 14:41:58 +00:00
Martin Robinson
66c7f81b6c deps: Update Stylo to include "Restore Servo's original form control theme colors" (#43107)
This change just updates the version of Stylo to a version which
restores the original Servo theme colors.

Stylo PR: servo/stylo#327
Testing: This just restore the original form control theme colors, so
should
not change test results. Manual testing was performed with the
`form-controls-visual.html` test. One form tests starts to fail due to
subpixel differences. This test was failing originally (before form
control style was inadvertently changed). This likely happens due to
the rounded grey borders of buttons. This PR changes them back to
gray from black.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-10 13:48:41 +00:00
Jonathan Schwender
6f15489be6 devcontainer: Add workflow to build and publish Ubuntu amd64 devcontainer (#43131)
This adds a simple workflow to build and push the devcontainer to our
github container registry.
This would allow us (in a follow-up PR) to use the prebuild devcontainer
image from ghcr, instead of needing to first build the image from
scratch, which can save quite a bit of time.
This a part of #40656.

Testing: workflow run in my fork:
https://github.com/jschwe/servo/actions/runs/22897536246/job/66435358111
-> created the following image:
https://github.com/jschwe/servo/pkgs/container/servo%2Fdevcontainer-ubuntu

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Sam <16504129+sagudev@users.noreply.github.com>
2026-03-10 12:56:29 +00:00
atbrakhi
3adc252612 devtools: Add test for StepIn, StepOut and StepOver hooks (#43135)
This PR adds a test for `StepIn`, `StepOut` and `StepOver` hooks.

This test is intentionally designed to include all three `StepIn`,
`StepOut` and `StepOver` hooks in one test. This could be tested
separately but in a real use case one is mostly using these hooks
together in a single debugging session, not in isolation.

It is important we mirror that workflow. Also considering this area is
actively under development, it would be easier to catch regressions with
this flow test.

Testing: Added a new test
Fixes: Part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-10 12:41:00 +00:00
Sam
764ef29de5 chore: Bump mozangle to 0.5.5 (#43134)
For https://github.com/servo/servo/pull/43116

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2026-03-10 11:46:45 +00:00
Shubham Gupta
66e1350dab layout: Support svg in border-image-source (#42566)
Extends the SVG support for `border-image-source`

> The logic is almost identical to `build_background_image`

Testing: Following WPT Tests Passed
- `tests/wpt/tests/css/css-backgrounds/border-image-image-type-002.htm`
- `tests/wpt/tests/css/css-backgrounds/border-image-image-type-004.htm` 
- `tests/wpt/tests/css/css-backgrounds/border-image-image-type-005.htm`
- `tests/wpt/tests/css/css-backgrounds/border-image-repeat-1.html`
- `tests/wpt/tests/paint-timing/fcp-only/fcp-border-image-with-svg.html`

Fixes: #42098

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-10 10:16:33 +00:00
atbrakhi
6ca286d6cd devtools: Update firefox version (#43129)
Update Firefox to 146 version

Testing: Existing tests are passing

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-10 09:58:38 +00:00
Jonathan Schwender
4fa57ff0ff devcontainer: Add a dockerignore (#43127)
Rename the dockerfile and add a dockerignore. This reduces the size of
the build-context greatly.
Renaming is a preparation for later adding more possible dockerfiles
(e.g. fedora based etc).
We choose the filename based `.dockerignore` files over a
`.dockerignore` in the root folder mainly to reduce clutter in the root
folder.
This addresses the problem of large build context raised on zulip by
@glyn.

Testing: Manually tested by building the image locally.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-10 09:20:40 +00:00
Shubham Gupta
b9b95e34a2 fonts: Fix font-weight matching behavior for "simple" font families (#43125)
This aligns with behavior with spec, by selecting `BOLD` for the weights
greater than 500.

- W3C Specs:
[font-style-matching](https://www.w3.org/TR/css-fonts-4/#font-style-matching)

> If the desired weight is greater than 500, weights greater than or
equal to the desired weight are checked in ascending order followed by
weights below the desired weight in descending order until a match is
found.

- Firefox: https://phabricator.services.mozilla.com/D274775

Testing: This causes a WPT test to start passing.

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-10 07:49:23 +00:00
dependabot[bot]
e98336150b build: bump zerocopy from 0.8.40 to 0.8.42 (#43122)
Bumps [zerocopy](https://github.com/google/zerocopy) from 0.8.40 to
0.8.42.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/google/zerocopy/releases">zerocopy's
releases</a>.</em></p>
<blockquote>
<h2>v0.8.41</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>Add code generation tests by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3042">google/zerocopy#3042</a></li>
<li>Introduce 'Code Generation' documentation by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3078">google/zerocopy#3078</a></li>
<li>[codegen] Track unanalyzed assembly and include it in docs. by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3081">google/zerocopy#3081</a></li>
<li>[codegen] Use descriptive benchmark target fn name. by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3082">google/zerocopy#3082</a></li>
<li>[codegen] Make codegen tests even more stressful. by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3083">google/zerocopy#3083</a></li>
<li>[codegen] Test and document codegen under different layouts by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3085">google/zerocopy#3085</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.40...v0.8.41">https://github.com/google/zerocopy/compare/v0.8.40...v0.8.41</a></p>
<h2>v0.8.41-alpha</h2>
<!-- raw HTML omitted -->
<h2>What's Changed</h2>
<ul>
<li>Add code generation tests by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3042">google/zerocopy#3042</a></li>
<li>Introduce 'Code Generation' documentation by <a
href="https://github.com/jswrenn"><code>@​jswrenn</code></a> in <a
href="https://redirect.github.com/google/zerocopy/pull/3078">google/zerocopy#3078</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/google/zerocopy/compare/v0.8.40...v0.8.41-alpha">https://github.com/google/zerocopy/compare/v0.8.40...v0.8.41-alpha</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="90600f141f"><code>90600f1</code></a>
[docs] Remove superfluous heading (<a
href="https://redirect.github.com/google/zerocopy/issues/3099">#3099</a>)</li>
<li><a
href="fc7362493d"><code>fc73624</code></a>
[codegen] Test and document codegen under different layouts (<a
href="https://redirect.github.com/google/zerocopy/issues/3085">#3085</a>)</li>
<li><a
href="098b966fa6"><code>098b966</code></a>
[codegen] Make codegen tests even more stressful. (<a
href="https://redirect.github.com/google/zerocopy/issues/3083">#3083</a>)</li>
<li><a
href="daa19713c0"><code>daa1971</code></a>
[codegen] Use descriptive benchmark target fn name. (<a
href="https://redirect.github.com/google/zerocopy/issues/3082">#3082</a>)</li>
<li><a
href="aa1bbf4cae"><code>aa1bbf4</code></a>
[codegen] Track unanalyzed assembly and include it in docs. (<a
href="https://redirect.github.com/google/zerocopy/issues/3081">#3081</a>)</li>
<li><a
href="dbef2724b5"><code>dbef272</code></a>
Release 0.8.41-alpha (<a
href="https://redirect.github.com/google/zerocopy/issues/3080">#3080</a>)</li>
<li><a
href="128f030013"><code>128f030</code></a>
Introduce 'Code Generation' documentation (<a
href="https://redirect.github.com/google/zerocopy/issues/3078">#3078</a>)</li>
<li><a
href="2694453fef"><code>2694453</code></a>
Add code generation tests (<a
href="https://redirect.github.com/google/zerocopy/issues/3042">#3042</a>)</li>
<li>See full diff in <a
href="https://github.com/google/zerocopy/compare/v0.8.40...v0.8.42">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=zerocopy&package-manager=cargo&previous-version=0.8.40&new-version=0.8.42)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-10 00:49:21 +00:00
Taym Haddadi
877502e86f WebCryptoAPI: implement Ed25519 and split Handle::Ed25519 into Ed25519PrivateKey and Ed25519PublicKey (#43115)
Testing: Ed25519 test passed.
Fixes: Part of https://github.com/servo/servo/issues/43072

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-09 17:51:52 +00:00
Euclid Ye
819b3533c3 ci: Fail the action if artifact not found when uploading; Update actions/upload-artifact to v7 (#43114)
- Rename instead of copy the `cargo-timings` folder
- Fail the action if artifact not found in upload-artifact. This should
prevent things like #43102
- Update `actions/upload-artifact` to v7

Testing: If this can merge, it is successful.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-09 17:24:52 +00:00
Luke Warlow
62e72b027f script: Implement node.moveBefore() (#41238)
Implement node.moveBefore()

This implements the atomic move method for DOM nodes. This allows moving
elements within the DOM without running the full remove and insertion
steps, allowing more seamless behaviour such as CSS transitions
continuing from where they are rather than restarting.

Spec: https://dom.spec.whatwg.org/#dom-parentnode-movebefore

Testing: Existing WPTs

---------

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-09 16:39:56 +00:00
Martin Robinson
19da10cb0f script_bindings: Remove EncodedBytesView and simplify StringView (#43083)
This change simplifies some of the internals of `DOMString` by doing two
things:

1. Removing `EncodedBytesView`. This was almost always used to get
   `EncodedBytes` so its functionality is merged into `EncodedBytes`
   and `DOMString::encoded_bytes` returns it directly.
2. Have `StringView` hold a reference to a `&str` instead of a
   `DOMString`. This type is used to represent a Rust `&str` anyway, so
   it doesn't make sense to hold a `DOMString`.

These changes simplify the code.

Testing: These changes should not modify behavior and are thus covered
by existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-09 13:40:22 +00:00
Narfinger
9062952bf9 script: Add UnrootedSimpleNodeIterator (#42978)
In the same vein as https://github.com/servo/servo/pull/42781 we
implement a UnrootedSimpleNodeIterator that takes a no_gc and does not
root the required nodes.

We include an example usage in 'dom/text.rs' WholeText.

This requires https://github.com/servo/servo/pull/42781 to be merged
first.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-09 12:28:07 +00:00
Kingsley Yung
c3060385bc script: Implement "getPublicKey" operations of ECDSA and ECDH (#43106)
Implement "getPublicKey" operations of ECDSA and ECDH. The steps are
implemented at the new submodule `ec_common` shared by ECDSA and ECDH.

To make the operations functioning, they are also registered at
`GetPublicKeyAlgorithm`.

Specification:
https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-getPublicKey
Testing: Pass WPT tests that were expected to fail.
Fixes: Part of #43072

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-09 12:01:27 +00:00
Martin Robinson
f0fc893561 script_bindings: Reduce the amount of borrowing inside DOMString (#43088)
For many operations, `DOMString` needs to convert the internal string
storage to a Rust `String` and then borrow again to actually do the
operation in question. This change makes it so that this borrow can be
done once, by transforming `DOMString::make_rust` into
`DOMString::ensure_rust_string` which returns a reference to the inner
`String` which can then be use directly. In many cases this eliminates
an entire mutable borrow of the inner `RefCell`.

Testing: This is just a minor optimization, so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-09 11:22:21 +00:00
Euclid Ye
c1aaaaf18c css: Enable jump-start, jump-both, jump-end, jump-none step-position (#43061)
Bumps stylo to https://github.com/servo/stylo/pull/323
As tested with examples, all step-position keywords now work:
https://drafts.csswg.org/css-easing-2/#typedef-step-position

Testing: New passing WPT. Several in `moveBefore` goes from TIMEOUT to
`FAIL`, as the API is not enabled in Servo. Added 4 new tests to test
the proper rendering.
Fixes: #43060

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-09 10:55:06 +00:00
Jonathan Schwender
6c648cea61 Sync mach bootstrap package list to the book automatically. (#42063)
Follow-up to https://github.com/servo/servo/pull/41775
This allows syncing our package list to the book automatically, keeping
the documented required packages in sync with what bootstrap installs.

We use two personal access token of the `servo-bot` account. One PAT
with the Resource-owner `servo-bot` for the repository `servo-bot/book`,
to push the branch to the bots fork. This PAT should be created with the
following permissions:
Choose "Only select repositories", select the forked book repo and give
the token Contents: Read and write permissions.
The second PAT must have the resource owner `servo`, and access to the
repository `servo/servo` as well as the permissions "Pull-Request: Read
and Write".

This split has the advantag of limiting the PAT permissions for the
upstream repo, avoiding `Content: Write` permissions for the
`servo/book` repository.

Testing: Manually tested by letting the action run on this branch.
[successfull
run](https://github.com/servo/servo/actions/runs/22387422307/job/64800999782?pr=42063),
[created upstream PR](https://github.com/servo/book/pull/207)

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: shuppy <dazabani@igalia.com>
2026-03-09 10:53:39 +00:00
Gae24
fa86bbedbe script: Pass &mut JSContext to DOM apis that call Element::create (#43108)
Testing: No behaviour change, a successful build is enough.
Part of #40600

---------

Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
2026-03-09 10:07:13 +00:00
Shubham Gupta
c32d9f51af script: Add missing steps for parsing a legacy font size (#43103)
In this change clamps legacy font size value of the `<font>` element to
the range [1,7] according to steps 10, 11 of
[rules-for-parsing-a-legacy-font-size](https://html.spec.whatwg.org/multipage/rendering.html#rules-for-parsing-a-legacy-font-size).

Testing: This causes a WPT test to start passing.

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-09 09:40:54 +00:00
Martin Robinson
204ededfbd layout: Revert changes from #42529 to button control style (#43105)
I believe that these changes (part of #42529) were likely made in error.
Servo
button controls do not follow the system theme, so system colors should
not be
used. These changes degraded the look of the buttons, so this change
reverts to the previous state.

### Before (with unintended change):

<img width="520" height="115" alt="Screenshot 2026-03-09 at 08 47 15"
src="https://github.com/user-attachments/assets/cff5fc1a-bfd0-4785-8326-91e735390176"
/>

### After (restored style):

<img width="499" height="113" alt="Screenshot 2026-03-09 at 08 46 02"
src="https://github.com/user-attachments/assets/99660c7f-9eb6-4ee8-905e-f7a594bd363d"
/>


Testing: These changes are really only testable via the manual test
`tests/html/form-control-visuals.html`.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-09 09:27:41 +00:00
Euclid Ye
1d0b3f1418 ci: Update WiX files and Windows workflow to reflect ServoShell name (#43104)
`candle` generates the object file based on the name of WiX source file,
which is used by linker later.
This PR effectively changes:
- `Servo.exe` to `ServoShell.exe` for the windows installer
- `Servo.zip` to `ServoShell.zip`

We already generates `servoshell.exe` from build, it is weird that we
keep the name `Servo.exe` for the MSI.

Testing: The problem is fixed, for both executable and zip, see
[this](https://github.com/servo/servo/actions/runs/22841763218/job/66249263625).
Bencher [works
too](https://github.com/servo/servo/actions/runs/22843667165/job/66256020144).
Fixes: #43102, where the windows artifact keeps missing.

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-09 08:17:56 +00:00
Freya Arbjerg
4ec46aaadc layout: Support text carets on empty lines in <textarea> (#42218)
This PR modifies the text layout in such a way that text carets can
render on empty lines (other than the first if the textarea is empty).
Zero-length segments are added to support caret rendering. The last
line, if it is without content, does not currently render a caret
correctly

This corresponds to cases 0, 1, and 3 in #41338

Testing: WPT subset `tests/wpt/tests/css/css-text/` ran as expected, one
internal WPT test was added
Fixes: Partially addresses https://github.com/servo/servo/issues/41338

---------

Signed-off-by: Freya Arbjerg <git@arbjerg.dev>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-09 07:06:27 +00:00
Zain
2cc8ae3897 script: Add error messages in HTMLDialogElement (#43101)
Adds specific InvalidStateError messages in HTMLDialogElement for
`show()` and `showModal()` error paths.

A fix part of #40756.

---------

Signed-off-by: xzaisk <zkhalid99v@gmail.com>
Signed-off-by: Zain <39714482+xZaisk@users.noreply.github.com>
Co-authored-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-09 06:47:32 +00:00
dependabot[bot]
522e8523bf build: bump uds_windows from 1.1.0 to 1.2.0 (#43100)
Bumps [uds_windows](https://github.com/haraldh/rust_uds_windows) from
1.1.0 to 1.2.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/haraldh/rust_uds_windows/releases">uds_windows's
releases</a>.</em></p>
<blockquote>
<h2>v1.2.0</h2>
<ul>
<li>Migrate from unmaintained <code>winapi</code> crate to official
Microsoft <code>windows-sys</code> crate</li>
<li>Set minimum Rust version (MSRV) to 1.85</li>
<li>Update to Rust edition 2021</li>
<li>Remove unused <code>NetInt</code> trait</li>
<li>Fix clippy warnings and use explicit lifetime syntax</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/haraldh/rust_uds_windows/blob/master/CHANGELOG.md">uds_windows's
changelog</a>.</em></p>
<blockquote>
<h2>[1.2.0] - 2026-03-04</h2>
<ul>
<li>Migrate from unmaintained <code>winapi</code> crate to official
Microsoft <code>windows-sys</code> crate</li>
<li>Set minimum Rust version (MSRV) to 1.85</li>
<li>Update to Rust edition 2021</li>
<li>Remove unused <code>NetInt</code> trait</li>
<li>Fix clippy warnings and use explicit lifetime syntax</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="d47604cdab"><code>d47604c</code></a>
chore: bump version to 1.2.0 and add CHANGELOG.md</li>
<li><a
href="6edc47a997"><code>6edc47a</code></a>
fix: resolve clippy warnings for Rust 1.85</li>
<li><a
href="6fcd095d20"><code>6fcd095</code></a>
chore: set minimum Rust version to 1.85 and add rust-toolchain.toml</li>
<li><a
href="16db1c9451"><code>16db1c9</code></a>
chore: migrate from winapi to windows-sys</li>
<li><a
href="1c57469aea"><code>1c57469</code></a>
fix: use explicit lifetime syntax to fix mismatched_lifetime_syntaxes
warnings</li>
<li><a
href="b90d51b297"><code>b90d51b</code></a>
chore: remove unused NetInt trait</li>
<li><a
href="f02fd0762c"><code>f02fd07</code></a>
chore: remove extern in lib.rs</li>
<li><a
href="c13ffb38bf"><code>c13ffb3</code></a>
chore: set edition to 2021</li>
<li>See full diff in <a
href="https://github.com/haraldh/rust_uds_windows/compare/v1.1.0...v1.2.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=uds_windows&package-manager=cargo&previous-version=1.1.0&new-version=1.2.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 01:05:46 +00:00
dependabot[bot]
c7495f6e48 build: bump winnow from 0.7.14 to 0.7.15 (#43099)
Bumps [winnow](https://github.com/winnow-rs/winnow) from 0.7.14 to
0.7.15.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/winnow-rs/winnow/blob/main/CHANGELOG.md">winnow's
changelog</a>.</em></p>
<blockquote>
<h2>[0.7.15] - 2026-03-05</h2>
<h3>Compatibility</h3>
<ul>
<li>Deprecate <code>combinator::permutation</code> in favor of
<code>combinator::unordered_seq!</code></li>
</ul>
<h3>Features</h3>
<ul>
<li>Add <code>combinator::unordered_seq!</code>, like <code>seq!</code>
but where the order of values does not matter</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="eae4d4a23c"><code>eae4d4a</code></a>
chore: Release</li>
<li><a
href="5769b89038"><code>5769b89</code></a>
docs: Update changelog</li>
<li><a
href="329c13b6d2"><code>329c13b</code></a>
Merge pull request <a
href="https://redirect.github.com/winnow-rs/winnow/issues/876">#876</a>
from epage/unordered_seq</li>
<li><a
href="c169964b33"><code>c169964</code></a>
fix(comb): Deprecate permutation</li>
<li><a
href="2f972799f8"><code>2f97279</code></a>
fix(macros): Preserve original failure location</li>
<li><a
href="5926ad3527"><code>5926ad3</code></a>
feat(comb): Add unordered support to unordered_seq</li>
<li><a
href="6d7e8d4f98"><code>6d7e8d4</code></a>
feat(comb): Add baseline for unordered_seq</li>
<li><a
href="cfcd411cff"><code>cfcd411</code></a>
refactor(macros): Be consistent on indentation</li>
<li><a
href="716f2a7f6b"><code>716f2a7</code></a>
Merge pull request <a
href="https://redirect.github.com/winnow-rs/winnow/issues/869">#869</a>
from winnow-rs/renovate/crate-ci-committed-1.x</li>
<li><a
href="7cc73432d4"><code>7cc7343</code></a>
Merge pull request <a
href="https://redirect.github.com/winnow-rs/winnow/issues/870">#870</a>
from winnow-rs/renovate/crate-ci-typos-1.x</li>
<li>Additional commits viewable in <a
href="https://github.com/winnow-rs/winnow/compare/v0.7.14...v0.7.15">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=winnow&package-manager=cargo&previous-version=0.7.14&new-version=0.7.15)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 00:58:17 +00:00
dependabot[bot]
8869394200 build: bump libc from 0.2.182 to 0.2.183 (#43098)
Bumps [libc](https://github.com/rust-lang/libc) from 0.2.182 to 0.2.183.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/releases">libc's
releases</a>.</em></p>
<blockquote>
<h2>0.2.183</h2>
<h3>Added</h3>
<ul>
<li>ESP-IDF: Add <code>SOMAXCONN</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4993">#4993</a>)</li>
<li>Linux: Add <code>name_to_handle_at</code> and
<code>open_by_handle_at</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4988">#4988</a>)</li>
<li>NetBSD: Add <code>kinfo_file</code>, <code>kinfo_pcb</code>, and
related constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/4985">#4985</a>)</li>
<li>OpenBSD: Add <code>kinfo_file</code> and related constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/4991">#4991</a>)</li>
<li>VxWorks: Add additional structs and defines (<a
href="https://redirect.github.com/rust-lang/libc/pull/5003">#5003</a>)</li>
<li>Various: Implement <code>Default</code> for <code>timeval</code> and
<code>timespec</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4976">#4976</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Hexagon musl: Enable unstable 64-bit <code>time_t</code> support and
<code>musl_v1_2_3</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4992">#4992</a>)</li>
<li>Nintendo Switch: Fix target support (<a
href="https://redirect.github.com/rust-lang/libc/pull/4982">#4982</a>)</li>
<li>OpenBSD: Wrap an unused field in <code>Padding</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4997">#4997</a>)</li>
<li>Redox: Change <code>sigaction.sa_flags</code> to <code>c_int</code>
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4986">#4986</a>)</li>
<li>Redox: Fix <code>blkcnt_t</code> type (<a
href="https://redirect.github.com/rust-lang/libc/pull/4994">#4994</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/libc/blob/0.2.183/CHANGELOG.md">libc's
changelog</a>.</em></p>
<blockquote>
<h2><a
href="https://github.com/rust-lang/libc/compare/0.2.182...0.2.183">0.2.183</a>
- 2026-03-08</h2>
<h3>Added</h3>
<ul>
<li>ESP-IDF: Add <code>SOMAXCONN</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4993">#4993</a>)</li>
<li>Linux: Add <code>name_to_handle_at</code> and
<code>open_by_handle_at</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4988">#4988</a>)</li>
<li>NetBSD: Add <code>kinfo_file</code>, <code>kinfo_pcb</code>, and
related constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/4985">#4985</a>)</li>
<li>OpenBSD: Add <code>kinfo_file</code> and related constants (<a
href="https://redirect.github.com/rust-lang/libc/pull/4991">#4991</a>)</li>
<li>VxWorks: Add additional structs and defines (<a
href="https://redirect.github.com/rust-lang/libc/pull/5003">#5003</a>)</li>
<li>Various: Implement <code>Default</code> for <code>timeval</code> and
<code>timespec</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4976">#4976</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Hexagon musl: Enable unstable 64-bit <code>time_t</code> support and
<code>musl_v1_2_3</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4992">#4992</a>)</li>
<li>Nintendo Switch: Fix target support (<a
href="https://redirect.github.com/rust-lang/libc/pull/4982">#4982</a>)</li>
<li>OpenBSD: Wrap an unused field in <code>Padding</code> (<a
href="https://redirect.github.com/rust-lang/libc/pull/4997">#4997</a>)</li>
<li>Redox: Change <code>sigaction.sa_flags</code> to <code>c_int</code>
(<a
href="https://redirect.github.com/rust-lang/libc/pull/4986">#4986</a>)</li>
<li>Redox: Fix <code>blkcnt_t</code> type (<a
href="https://redirect.github.com/rust-lang/libc/pull/4994">#4994</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="5660e6fc05"><code>5660e6f</code></a>
chore: Release libc 0.2.183</li>
<li><a
href="8b439b7678"><code>8b439b7</code></a>
allow unused link_cfg feature in rustc-dep-of-std</li>
<li><a
href="e6436dcf4a"><code>e6436dc</code></a>
Adding structs and defines for vxworks</li>
<li><a
href="e9cca04dff"><code>e9cca04</code></a>
Linux: add <code>name_to_handle_at</code> and
<code>open_by_handle_at</code></li>
<li><a
href="af8b8127bc"><code>af8b812</code></a>
linux: relocate PIDFD definitions to src/new</li>
<li><a
href="d0bd7e2f2f"><code>d0bd7e2</code></a>
NetBSD: add kinfo_file, kinfo_pcb structures and related constants</li>
<li><a
href="17f5cce00d"><code>17f5cce</code></a>
build(deps): bump actions/upload-artifact from 6 to 7</li>
<li><a
href="62c89e800a"><code>62c89e8</code></a>
OpenBSD: Wrap an unused field in <code>Padding</code></li>
<li><a
href="82cb126e16"><code>82cb126</code></a>
enable musl32_time64 and musl_v1_2_3 for hexagon</li>
<li><a
href="e7f99026dc"><code>e7f9902</code></a>
redox: fix blkcnt_t type</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/libc/compare/0.2.182...0.2.183">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libc&package-manager=cargo&previous-version=0.2.182&new-version=0.2.183)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-09 00:54:38 +00:00
Steven Novaryo
ab83e6e448 layout: Make ::placeholder public and add property restriction for ::placeholder and ::marker (#43053)
Servo side of https://github.com/servo/stylo/pull/322.

Update the WPT expectation following the changes to make `::placeholder`
public and adding property restriction to `::placeholder` and
`::marker`. Additionally ensure that `getComputedStyle` works for
`::placeholder`.

Testing: Existing WPTs
Fixes: #43034 
Fixes: #43035 
Fixes: #19808

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
2026-03-08 23:22:36 +00:00
Oriol Brufau
a2ca667041 script,layout: Use Stylo's logic for registering custom properties from script (#43085)
Stylo PR: https://github.com/servo/stylo/pull/325

Testing: Not needed, no behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-08 22:06:19 +00:00
Kingsley Yung
d472788f10 script: Implement "getPublicKey" operations of RSA algorithms (#43093)
Implement "getPublicKey" operations of RSASSA-PKCS1-v1_5, RSA-PSS and
RSA-OAEP. The steps are implemented at `rsa_common.rs` shared by the
three RSA algorithms.

To make the operations functioning, they are also registered at
`GetPublicKeyAlgorithm`.

Specification:
https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-getPublicKey
Testing: Pass WPT tests that were expected to fail.
Fixes: Part of #43072

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-08 17:36:02 +00:00
Martin Robinson
568f2ef158 script_bindings: Implement Default for DOMString using derive (#43090)
This is just a minor cleanup that uses the `derive` macro to implement
more of the `Default` functionality of `DOMString`.

Testing: This does not change functionality, so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-08 12:55:01 +00:00
Martin Robinson
01a3b60bf6 Update comment showing how to override WebRender dependency in Cargo.toml (#43092)
WebRender is now a crates.io dependency so the previous lines need to
be updated to be like the ones for other crates.io. dependnecies.

Testing: This just updates a comment, so includes no behavior changes.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-08 11:50:26 +00:00
Martin Robinson
e725fdbfdf script_bindings: Eliminate DOMString::from_string (#43089)
This method is the same as `DOMString::from` with a `String` argument
and `From` and `Into` are preferred when writing modern Rust.

Testing: This should not change behavior and is thus covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-08 11:46:42 +00:00
webbeef
cea658e2c0 script: Coalesce wheel input events (#43074)
This follows the same principle used for mouse move events, but we have
to update the event parameters since we receive the delta from the
previous event.

Testing: Load
https://docs.rs/iced-x86/1.21.0/iced_x86/code_asm/struct.CodeAssembler.html
and try to scroll with the trackpad with and without this patch.
Fixes: Partial fix for https://github.com/servo/servo/discussions/43062

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-03-07 16:56:13 +00:00
Martin Robinson
a25f8c7945 script_bindings: Remove some code duplication in DOMString (#43079)
The conversion to atoms types uses a lot of copy and pasted code that
can be put into a generic function. This PR does that.

Testing: This should not change behavior so is covered by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-07 13:55:44 +00:00
Jonathan Schwender
9377c9e879 Explicitly set publish = false for test crates (#43078)
The workspace `publish` key is currently also set to false, but we will
probably start publishing in the future. To prepare for that we
explicitly prevent publishing in these crates, instead of following the
workspace setting.

Testing: No functional changes, covered by cargo build still working.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-07 10:40:39 +00:00
Sam
9394cdfa4c CI: Force lld in MSRV Linux build (#43075)
when using rust-toolchain rust this is already default

Testing: None
Fixes: #43070

---------

Signed-off-by: Sam <16504129+sagudev@users.noreply.github.com>
2026-03-07 09:33:09 +00:00
Euclid Ye
f31a436e63 webdriver: Use globally shared tick_start per tick (#43076)
We used to create a `tick_start` timestamp at each
`dispatch_scroll_action` and `dispatch_pointermove_action`.
This is really bad, as the variable should represent the start of
current tick,
but we may end up with distinct values for different actions, since we
can sleep for some pointers:

d6fdd30c19/components/webdriver_server/actions.rs (L535-L537)

Testing: 
This makes all actions in the current tick share the same `tick_start`,
and changes the number of actions dispatched.
A test for this would be really contrived.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-07 09:15:50 +00:00
Kingsley Yung
1c449ed53b script: Implement SubtleCrypto.getPublicKey method with X25519 support (#43073)
Implement the `getPublicKey` method of the `SubtleCrypto` interface.

This patch includes:

- Implementing the steps of the `getPublicKey` method.
- Adding the new "getPublicKey" operation to the internal object
`supportedAlgorithms`, for registering cryptographic algorithms that
support "getPublicKey" operation, and used by the `getPublicKey` method
to check whether the cryptographic algorithm supports "getPublicKey"
operation and perform the operation if it is supported.
- Implementing the "getPublicKey" operation of X25519 for demonstrating
and testing the functionality of the `getPublicKey` method.

Specification:
<https://wicg.github.io/webcrypto-modern-algos/#SubtleCrypto-method-getPublicKey>
Testing: Pass WPT tests that were expected to fail.
Fixes: Part of #43072

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-07 09:13:40 +00:00
Jonathan Schwender
1632e61ed6 servoshell: Rename executable to servoshell. (#42958)
This should help clarify the difference between servo the library /
engine and servoshell the browser (demo).

Other changes: 

- Removed etc/servo.sb ( [apple sandbox profile
format](https://angelica.gitbook.io/hacktricks/macos-hardening/macos-security-and-privilege-escalation/macos-security-protections/macos-sandbox#sandbox-profiles))
since it is not needed anymore. See [this
comment](https://github.com/servo/servo/pull/42958#discussion_r2876253489)
for more details.

Testing: This is a very invasive change, and there are bound to be
scripts / places I have overlooked. Searching for usages of `servo` is
very hard, since it's also the name of the library.
Try run: https://github.com/servo/servo/actions/runs/22637676818

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
Signed-off-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-07 08:08:38 +00:00
Domenico Rizzo
229d89042f script: Refactor GPURenderPipeline's drop implementation (#43071)
Moves the `Drop` logic for `GPURenderPipeline` into a dedicated helper
struct, `DroppableGPURenderPipeline`.
The associated `Bindings.conf` entry is
removed as direct `Drop` is no longer needed for this type.

Testing: WebGpu tests just cover its cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-07 06:53:15 +00:00
Jacob Adam W.
d6fdd30c19 script: Implement HTMLSelectElement.selectedOptions (#43017)
This introduces a `CollectionSource` trait as an alternative to
`CollectionFilter` in `HTMLCollection`, allowing collections to provide
elements directly via a custom iterator rather than filtering a full
subtree traversal, which would otherwise be rather inefficient for
smaller iterable sequences of options that can be determined without
traversing the whole subtree again.

The newly implemented `selectedOptions` attribute on the `<select>`
element uses this to iterate only the element's list of options that are
marked as selected.

Testing: 14 assertions in the existing WPT went from failing to passing.

Fixes #15522.

---------

Signed-off-by: Jacob Adam <software@jacobadam.net>
2026-03-07 06:16:33 +00:00
Oriol Brufau
42d228dcc7 Upgrade Stylo to 2026-03-01 (#43045)
This continues  #42361

Changelog:
- Upstream:
7cd2a178d3...74ddab4091
- Servo fixups:
a5eabbdfc2...ecf17b5425

Stylo tracking issue: https://github.com/servo/stylo/issues/321

In particular, this includes some performance optimizations, improves
`attr()`, and adds support for `none` keywords in `clamp()`.

Testing: Some WPT tests pass.

---------

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-06 23:39:55 +00:00
Martin Robinson
401d327b96 script: Clean up attribute access a little bit in Element (#43064)
- Use modern Rust conveniences such as `unwrap_or_default`
 - Unabbreviate `attr`
- Unify the lowercase ASCII name assertion and make it a debug assertion
 - Use `unreachable!` instead of panic
- Expose two attribute getters that follow the behavior of two
specification concepts and what we expect internally in Servo:
- One that takes a namespace, but does not require lowercase attribute
names. ([specification
concept](https://dom.spec.whatwg.org/#concept-element-attributes-get-by-namespace>))
- One that does not take a namespace, but does require lowercase
attribute names. ([specification
concept](https://dom.spec.whatwg.org/#concept-element-attributes-get-by-name))
Testing: This should not really change behavior so should be covered by
existing tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-06 20:02:37 +00:00
Martin Robinson
291e9e57cb script: Readily accept all event names as Atoms (#43066)
Accepting the name of the event as a `DOMString` means that when events
are constructed from within Servo (for instance via input event
handling), the static strings are converted to an owned `String`
wrapped in a `DOMString` and then finally converted to an `Atom` in
`Event`. This makes it so that all non-generated `Event` constructors
accept `Atom`, which can avoid a conversion entirely when the atom
already exists on the Stylo atoms list and eliminate one in-memory copy
in the case that it isn't on the atom list.

Eventually, all event names can be on the atom list and we can eliminate
all copies. This is a tiny optimization, but also makes the code much
friendlier everywhere.

Testing: This should not change behavior so should be covered by
existing test.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-06 19:25:33 +00:00
Martin Robinson
df3e895e1b script: Allow focusing boxes with overflow with the keyboard (#43067)
This change makes it possible to focus boxes with overflow via the
keyboard. These boxes should be focusable areas, yet are not focusable
via the mouse. Instead they can be focused via sequential tab
navigation.

Testing: This fixes a WPT test.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-06 19:22:45 +00:00
Tim van der Lippe
160e458a51 script: Implement miscellaneous commands related to delete (#43028)
These two commands are intertwined with the delete command. By
implementing them now, it becomes easier to triage actual
implementation issues in the delete command.

Part of #25005

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-06 19:02:14 +00:00
eri
7d3e60d999 devtools: Fix step out and clearing stepping hooks (#43042)
Make step out behave properly.

Testing: DevTools tests and manual testing.
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
2026-03-06 16:05:56 +00:00
Tim van der Lippe
c8c213650b script: Append CSP policies from meta elements (#43063)
Rather than overwriting the CSP list from a fetch header response, we
should add a policy from a meta element to the global CSP list (if it
exists).

Fixes #36822
Supersedes and closes #36828

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Co-authored-by: Emmanuel Paul Elom <elomemmanuel007@gmail.com>
2026-03-06 15:53:27 +00:00
Martin Robinson
e2f6852a45 script: Align focusable area logic to be closer to the specification (#43058)
This abstracts out a common helper to determine focusable area kind
which is used by `Element::is_click_focusable`,
`Element::is_sequentially_focusable`, and `Element::is_focusable_area`.
This avoid having the latter depend on the former two, which was the
reverse of what the specification said. The helper is necessary because
the specification defines click and sequential focusability as subsets
of focusable elements, but going from "This is a focusable element" to
determining what kind of focusable element something is requires
duplicating a lot of the logic that was used to determine that something
is a focusable area.

It's likely that the specification needs more work here to improve the
definition (and indeed to unify all of the places that talk about what
elements are focusable areas). For now, this just tries to make our code
more similar to the text.

See: whatwg/html#4607
Testing: This shouldn't change behavior, so should be tested by existing
tests.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-06 14:53:36 +00:00
Martin Robinson
a48bef2316 script: Add support for the accesskey attribute (#43031)
This change adds support for the `accesskey` HTML attribute the
corresponding behavior defined by the HTML standard. In addition to a
new map holding a mapping between access key characters and a rooted
reference to elements that use them, it adds a struct to represent the
"Command" concept from the specification [^1], which seems to be used
for `accesskey`. Not all command facets are implemented as some seem to
be unused in the specification.

[^1]:
https://html.spec.whatwg.org/multipage/interactive-elements.html#commands

Testing: This causes most access key tests to start passing. One test
now
only partially completes, because of a bug in the way that we fire
synthetic
mouse events.
Fixes: This is part of #25001.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-06 14:22:54 +00:00
Martin Robinson
17dcf840ef deps: Upgrade to strum 0.28 (#43057)
This requires updating to a new version of Stylo. 

Corresponding Stylo PR: servo/stylo#319
Testing: This just upgrades a dependency so existing tests should
suffice.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-06 12:19:31 +00:00
shuppy
ec55e83040 constellation: Track top-level pipeline changes in webviews (#43013)
whenever a browsing context loads a new document or otherwise navigates,
the constellation sends a new frame tree to the compositor, giving us a
nice, relatively central way to detect when we may need to update the
graft node in a webview’s AccessKit subtree. but we only want to update
that graft node when the pipeline in its *top-level* browsing context
has changed, not just when the pipeline in *any* of its browsing
contexts has changed.

this patch adds a field to the ConstellationWebView that tracks the
active top-level pipeline for each webview, allowing us to check when a
set_frame_tree_for_webview() call actually involves navigation in the
top-level browsing context.

Testing: will be covered by accessibility tree tests in a later patch
Fixes: part of #4344, extracted from our work in #42338

Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-03-06 10:11:50 +00:00
shuppy
fd93a02041 base: Deterministic AccessKit tree UUID format for pipelines (#43012)
each webview will have an AccessKit subtree, and each pipeline
representing a document will have an AccessKit subtree for its layout.
but to graft the subtree of a pipeline into that of a webview (for
top-level documents) or another pipeline (for documents in iframes etc),
the parent tree needs to know the
[TreeId](https://docs.rs/accesskit/0.24.0/accesskit/struct.TreeId.html)
of the child tree.

this is annoying for pipelines, because they run in a separate thread
(or process) to the constellation, and they may run in a separate script
thread (or web content process) to other pipelines. if the pipeline
generates a random (UUIDv4) TreeId as internal state, it has to
communicate that to the constellation (or parent pipeline) over IPC,
which takes time and makes it harder for us to obey AccessKit’s subtree
invariants (notably, the subtree must not send updates before a graft
node is created for it in some other subtree).

this patch defines a deterministic and pure conversion from PipelineId
to a UUIDv5-based TreeId, allowing anyone that knows a PipelineId to
derive its TreeId. one consequence of this approach is that it precludes
having multiple instances of
[Servo](https://doc.servo.org/servo/struct.Servo.html) in a single
application, but i’m not sure that was an intended use case (or even
possible).

Testing: this patch includes a unit test
Fixes: part of #4344, extracted from our work in #42338

<img width="521" height="400" alt="grafts drawio"
src="https://github.com/user-attachments/assets/39efa426-ba21-41dc-874b-c3e4fcb17593"
/>

Signed-off-by: delan azabani <dazabani@igalia.com>
Co-authored-by: Alice Boxhall <alice@igalia.com>
2026-03-06 09:59:40 +00:00
Tim van der Lippe
0c4b185233 script: Fix lookup of properties of DOMStringMap (#43046)
The conversion of strings was wrong for `--foo` where it should become
`-Foo`. Instead, it was consuming both the `--` and then would encounter
a `f`.

This moves the relevant algorithms to DOMStringMap and adds
corresponding spec comments to explain what's going on.

This does make us closer to passing
`html/dom/elements/global-attributes/dataset-delete.html` but
unfortunately it still fails because of #12978

Prior to this fix, the value of `d.dataset['-foo']` wasn't undefined.
However, we now fail the assertion where the attribute should remain,
despite the call to delete.

That's because per `LegacyOverrideBuiltIns` we should be checking the
existence of which properties it can delete, before it actually deletes
the attribute. Right now, we do it regardless if it is a valid property
and thus we incorrectly delete the attribute.

Testing: No change in tests, since the test in question has more
assertions that require more fixes

---------

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com>
2026-03-06 09:58:33 +00:00
Brent Schroeter
4c69d856f6 tools: Support tab navigation via navigateTo, goBack, and goForward (#43026)
Add support for navigation requests ("navigateTo", "goBack", and
"goForward") over the Remote Debugging Protocol. These may be sent by a
UI client in response to user input (for example the address bar in the
Firefox inspector), or they can be used to automate navigation during
unit tests.

This currently only supports navigation within the URL domain at which
servoshell is initially launched, due to a bug in servo's
`BrowsingContextActor` implementation. (Unit tests covering a fix for
that issue will depend on this change.)

Testing: The behavior of all 3 new message types is covered by a new
test case—`test_navigation`—in the devtools unit test suite.
Fixes: #38668

---------

Signed-off-by: Brent Schroeter <contact@brentsch.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-06 09:13:39 +00:00
atbrakhi
9a915ece22 devtools: Pass ListFrames back to devtools (#43039)
Pass `ListFrames` back to devtools

Testing: existing test passes
Fixes: part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-06 08:47:15 +00:00
eri
836970d1ea devtools: Get newest frame when resuming without a frameActorID (#43040)
Fixes resuming after stepping.

Testing: Ran existing DevTools test
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-06 07:46:46 +00:00
Kingsley Yung
8df3819a9e script: Use CryptoAlgorithm in name fields of subtle dictionaries (#43055)
We currently use `String` to store cryptographic algorithm name in
subtle dictionaries in WebCrypto code. The algorithm normalization
guarantees that there are only a limited number of possible strings that
can be assigned to the name fields.

We switch to use the `CryptoAlgorithm` enum, which contains all possible
algorithm names, to represent these values. This reduces string
comparison and saves a small amount of memory.

The constant string `ALG_*` in `subtlecrypto.rs`, which are the
recognized algorithm name for the algorithms, are also removed since
they are already embedded in the `CryptoAlgorithm` enum.

Testing: Refactoring. Existing tests suffice.
Fixes: Part of #42579

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-06 07:14:49 +00:00
Tim van der Lippe
9f25c09193 script: Fix handling of attributes for link elements (#43043)
These were some of the remaining failures for link elements. They
concern attribute handling and when to run fetches.

1. We shouldn't refetch on media changes, but immediately apply the
effect. This is already the case for style elements
2. We shouldn't refetch when attribute values are the same
3. We shouldn't fetch when the type attribute doesn't match
4. We should fetch, even if the media doesn't match. Only when the media
is then changed, we should re-evaluate.

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-06 05:26:11 +00:00
Narfinger
11d47b62b9 script: Implement efficient TreeIterator without rooting when possible (#42781)
This implements an two types:
- Efficient Tree Iterator that can be used without rooting when
possible.
- UnrootedDom that can be used while not rooting while capturing a NoGC.

We:
- introduce new methods in 'script/dom/node.rs' to get the correct
iterator.
- introduce methods in 'script/dom/node.rs' to get the unrooted children
in an 'UnrootedDom' container.

We use the new TreeIterator in 'script/dom/document.rs' Open.

Testing: WPT tests should catch this but careful review is required.

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-06 05:21:01 +00:00
Euclid Ye
3f0665a679 ohos ci: Do not use action that does not exist (#43054)
Testing: https://github.com/servo/servo/actions/runs/22749912784
Fixes: The consistent CI failure after #42990

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-06 05:18:47 +00:00
Jonathan Schwender
a2bd2ab09b Add codesigning script for macOS (#42912)
This script automates the signing, packaging and notarization of
servoshell on macOS.
This is a first step towards: #40031 and #12532. While we could let a
maintainer code-sign and upload the signed release, probably this should
be integrated into CI, which would require additional work.

This script started out quite simple as part of `./mach package`.
However, since the script has access to secrets, it shouldn't be part of
mach (to minimize the amout of code that needs to be trusted).
We also needed to save state and be able to resume operations, since
notarizing can take quite long and the stapling needs to wait until
notarization has completed.
Since notarizing can take long (up to a day has been observed during
first tests), we save artifacts and the notarization ID, and add a
`--check-status` command that can be used to poll if notarization has
been finished.

Testing: Manually testing required. A signed and notarized `.dmg`
artifact has [been
uploaded](https://servo.zulipchat.com/#narrow/channel/500774-tsc/topic/Signing.20macos.20Servoshell/near/576256648)
to zulip, allowing others to verify the notarization worked.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-06 03:43:20 +00:00
Euclid Ye
cab4416d4c webdriver: Enable pointerMove to perform smooth transition over specified duration (#42946)
Enable `pointerMove` to perform a smooth transition over specified
duration.

- Sync move/scroll interval with default tick duraiton in testdriver:
a60a8b1b4d/tests/wpt/tests/resources/testdriver-actions.js (L34-L38)
- Fully process all pending pointer moves within this tick. This is one
of the conditions that is
[required](https://w3c.github.io/webdriver/#dfn-perform-a-pointer-move:~:text=There%20are%20no%20pending%20asynchronous%20waits%20arising%20from%20the%20last%20invocation%20of%20the%20dispatch%20tick%20actions%20steps%2E)
to finish this tick. Previously, the pending move events might be
processed in next Tick, if they have long duration.


https://github.com/user-attachments/assets/8692086f-32bb-45f3-ae0c-a072f68e1e84


https://github.com/user-attachments/assets/35af99a9-889b-41c1-91e2-55f22ad453a1

Testing: Added a WPT test. I'm surprised it is not covered by existing
tests, given the huge behaviour difference.
Fixes: https://github.com/servo/servo/issues/42950
Part of https://github.com/servo/servo/issues/41620

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-06 01:49:28 +00:00
dependabot[bot]
0a571bc262 build: bump uuid from 1.21.0 to 1.22.0 (#43051)
Bumps [uuid](https://github.com/uuid-rs/uuid) from 1.21.0 to 1.22.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/uuid-rs/uuid/releases">uuid's
releases</a>.</em></p>
<blockquote>
<h2>v1.22.0</h2>
<h2>What's Changed</h2>
<ul>
<li>Default to rand 0.10 by <a
href="https://github.com/haxtibal"><code>@​haxtibal</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/863">uuid-rs/uuid#863</a></li>
<li>Prepare for 1.22.0 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/864">uuid-rs/uuid#864</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/haxtibal"><code>@​haxtibal</code></a>
made their first contribution in <a
href="https://redirect.github.com/uuid-rs/uuid/pull/863">uuid-rs/uuid#863</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/uuid-rs/uuid/compare/v1.21.0...v1.22.0">https://github.com/uuid-rs/uuid/compare/v1.21.0...v1.22.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="da15792ae2"><code>da15792</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/864">#864</a> from
uuid-rs/cargo/v1.22.0</li>
<li><a
href="7ec48c98e8"><code>7ec48c9</code></a>
prepare for 1.22.0 release</li>
<li><a
href="c4e983f3cf"><code>c4e983f</code></a>
Merge pull request <a
href="https://redirect.github.com/uuid-rs/uuid/issues/863">#863</a> from
haxtibal/tdmg/rand_0_9_and_0_10</li>
<li><a
href="f3f677e9d8"><code>f3f677e</code></a>
update workspace root to rand 0.10</li>
<li>See full diff in <a
href="https://github.com/uuid-rs/uuid/compare/v1.21.0...v1.22.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=uuid&package-manager=cargo&previous-version=1.21.0&new-version=1.22.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-06 00:53:11 +00:00
Tim van der Lippe
7c21cb5606 script: Fully implement delete_the_selection (#43016)
This continues implementation of the delete command for
document.execCommand. Unfortunately, since these algorithms are vast
(30+ steps) and partial implementation leads to lots of issues, this PR
is "draw the rest of the owl".

I have tried to keep things manageable, by only implementing a couple of
extra steps in the delete command, so that we can focus on the "Delete
the selection" part.

To do that, several algorithms had to be implemented. Most of these
algorithms are required both by commands and by algorithms themselves,
which is why they are now exposed on a trait.

Additionally, all code now uses `cx`, to make sure it is up-to-date with
the ongoing migration and since some of the DOM API's it needs to call
already require `cx`.

Part of #25005

Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
2026-03-05 19:38:44 +00:00
Narfinger
fe6cc84284 OHOS CI: Update action versions and base (#42990)
This updates the action versions and base for the OHOS CI.

Testing: Manual run for the openharmony part is here:
https://github.com/Narfinger/servo/actions/runs/22617931816

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-05 17:54:22 +00:00
atbrakhi
1b7ec96fb6 devtools: implement listing all frames (#43015)
This change implements listing all frames from youngest to oldest. This
is in order to send correct frame message from thread actor

This is needed for our upcoming work!

Testing: Current tests are passing + manual test
Fixes: #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
Co-authored-by: eri <eri@igalia.com>
2026-03-05 14:58:30 +00:00
Simon Wülker
69e2894923 script: Unify naming of LayoutDom conversion functions to {to, from}_layout_dom (#43032)
As requested during the review of
https://github.com/servo/servo/pull/42991. These functions are currently
called `{to, from}_layout_js` or sometimes `get_jsmanaged` - this change
unifies them as `{to, from}_layout_dom` for clarity.

Testing: Covered by existing tests

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-05 12:32:31 +00:00
Steven Novaryo
a672397f2d layout: Add a query for getting the effective overflow of an element and use it in script (#42251)
In layout calculation within script, Instead of relying on the computed
values for overflow, query the overflow from layout for its used value
to accurately reflect whether an element establish a scroll container.
This query will be used for `IntersectionObserver` as well.

Testing: There are new `IntersectionObserver` WPT failures:
- `intersection-observer/isIntersecting-change-events.html`
- `intersection-observer/containing-block.html`

The failures are more than likely a false positive because intersection
observation steps wasn't supposed to trigger a reflow, but it was
before. It could be caused by the implementation of
`IntersectionObserver` in major UAs being a little bit different from
the spec in the calculation of `threshold` and `isIntersecting` .

---------

Signed-off-by: Jo Steven Novaryo <steven.novaryo@gmail.com>
Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Martin Robinson <mrobinson@igalia.com>
2026-03-05 11:35:32 +00:00
Qiaochu Hu
1b2ce4aaad prefs: Fix typo "arugment" -> "argument" (#43025)
Fixed a typo in the comment documentation in
`ports/servoshell/prefs.rs`. Changed "arugment" to "argument" on line
291.

Testing: This change does not need testing because it just fixes a typo
in a rustdoc comment.

Signed-off-by: hobostay <110hqc@gmail.com>
2026-03-05 10:52:14 +00:00
Martin Robinson
b47b39f974 script: Distinguish between sequential (keyboard) and click focusability (#43019)
This changes makes it so that keyboard and click focusability are two
separate concepts in `script`. Some elements may be focusable only by
the keyboard and some only by the click events.

In addition, the `SEQUENTIALLY_FOCUSABLE` `Node` flag is removed in
favor of a
more specification-aligned approach of checking lazily if an element is
a focusable area. This allows moving the focus fixup steps to their
correct place, asynchronously during "update the rendering" and
synchronously during `unbind_from_tree`.

Testing: This causes some WPT tests to start passing and some to start
failing:
- Two subtests tests in
`tests/wpt/meta/css/css-conditional/container-queries/` because
we do not implement support for container queries. These are legitimate
failures
   and they are compensated by a good subtest pass in the same file.
- A few subtests in `/html/interaction/focus/tabindex-focus-flag.html`
because now
we do not allow focusing non-rendering elements. The failures are HTML
elements with
`<svg>` which we do not rendering and `<summary>` elements of
`<details>` which
   need special handling we do not implement yet.
- `html/semantics/forms/the-fieldset-element/disabled-003.html`: Some of
these tests
start to fail, but they are not spec compliant and browser properly
implementing
   the asynchronous focus fixup rule also fail them. 

Fixes: #31870.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-05 08:58:59 +00:00
Euclid Ye
6a98cdc37d webdriver: Do nothing for dispatch_pause_action (#43014)
We should not try to create a input id here: it is already done in 

https://w3c.github.io/webdriver/#dfn-process-an-input-source-action-sequence

The sole effect of the action is that its `duration` parameter may
decide "tick duration".

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-05 01:50:43 +00:00
dependabot[bot]
f03425b997 build: bump proc-macro-crate from 3.4.0 to 3.5.0 (#43024)
Bumps [proc-macro-crate](https://github.com/bkchr/proc-macro-crate) from
3.4.0 to 3.5.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/bkchr/proc-macro-crate/releases">proc-macro-crate's
releases</a>.</em></p>
<blockquote>
<h2>v3.5.0</h2>
<h2>What's Changed</h2>
<ul>
<li>chore: fix typo in src/lib.rs by <a
href="https://github.com/black5box"><code>@​black5box</code></a> in <a
href="https://redirect.github.com/bkchr/proc-macro-crate/pull/63">bkchr/proc-macro-crate#63</a></li>
<li>Update <code>toml_edit</code> to 0.25.0 by <a
href="https://github.com/ColinFinck"><code>@​ColinFinck</code></a> in <a
href="https://redirect.github.com/bkchr/proc-macro-crate/pull/65">bkchr/proc-macro-crate#65</a></li>
<li>Release v3.5.0 by <a
href="https://github.com/bkchr"><code>@​bkchr</code></a> in <a
href="https://redirect.github.com/bkchr/proc-macro-crate/pull/66">bkchr/proc-macro-crate#66</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/black5box"><code>@​black5box</code></a>
made their first contribution in <a
href="https://redirect.github.com/bkchr/proc-macro-crate/pull/63">bkchr/proc-macro-crate#63</a></li>
<li><a
href="https://github.com/ColinFinck"><code>@​ColinFinck</code></a> made
their first contribution in <a
href="https://redirect.github.com/bkchr/proc-macro-crate/pull/65">bkchr/proc-macro-crate#65</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/bkchr/proc-macro-crate/compare/v3.4.0...v3.5.0">https://github.com/bkchr/proc-macro-crate/compare/v3.4.0...v3.5.0</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="8f3d8b0453"><code>8f3d8b0</code></a>
Merge pull request <a
href="https://redirect.github.com/bkchr/proc-macro-crate/issues/66">#66</a>
from bkchr/release-v3.5.0</li>
<li><a
href="c5412f52e7"><code>c5412f5</code></a>
Release v3.5.0</li>
<li><a
href="4807ac54fd"><code>4807ac5</code></a>
Merge pull request <a
href="https://redirect.github.com/bkchr/proc-macro-crate/issues/65">#65</a>
from ColinFinck/toml-edit-0.25.0</li>
<li><a
href="6a14602f8c"><code>6a14602</code></a>
Raise MSRV to 1.82.0</li>
<li><a
href="00502d3da2"><code>00502d3</code></a>
Fix CI to check for MSRV 1.76.0 instead.</li>
<li><a
href="46609987c4"><code>4660998</code></a>
Update <code>toml_edit</code> to 0.25.0</li>
<li><a
href="0af622fc42"><code>0af622f</code></a>
Merge pull request <a
href="https://redirect.github.com/bkchr/proc-macro-crate/issues/63">#63</a>
from black5box/master</li>
<li><a
href="a5390e60fa"><code>a5390e6</code></a>
chore: fix typo in src/lib.rs</li>
<li>See full diff in <a
href="https://github.com/bkchr/proc-macro-crate/compare/v3.4.0...v3.5.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=proc-macro-crate&package-manager=cargo&previous-version=3.4.0&new-version=3.5.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-05 01:50:15 +00:00
dependabot[bot]
8579a5fcda build: bump pin-project from 1.1.10 to 1.1.11 (#43023)
Bumps [pin-project](https://github.com/taiki-e/pin-project) from 1.1.10
to 1.1.11.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/pin-project/releases">pin-project's
releases</a>.</em></p>
<blockquote>
<h2>1.1.11</h2>
<ul>
<li>Enable <a
href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/immutable-releases">release
immutability</a>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/pin-project/blob/main/CHANGELOG.md">pin-project's
changelog</a>.</em></p>
<blockquote>
<h2>[1.1.11] - 2026-02-27</h2>
<ul>
<li>Enable <a
href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/immutable-releases">release
immutability</a>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="3aa50f9ae9"><code>3aa50f9</code></a>
Release 1.1.11</li>
<li><a
href="bd565cfa1c"><code>bd565cf</code></a>
Update changelog</li>
<li><a
href="90389fca80"><code>90389fc</code></a>
Update allowed lint list</li>
<li><a
href="67339afec3"><code>67339af</code></a>
tests: Update ui test output to nightly-2026-02-16</li>
<li><a
href="d5de5f6d21"><code>d5de5f6</code></a>
tools: Update tidy.sh</li>
<li><a
href="afceb72c9d"><code>afceb72</code></a>
Fix clippy::unnecessary_map_or warning</li>
<li><a
href="e985eee188"><code>e985eee</code></a>
Bump MSRV to 1.71</li>
<li><a
href="b66e5d98ca"><code>b66e5d9</code></a>
tests: Update ui test output to nightly-2026-02-07</li>
<li><a
href="3c707845da"><code>3c70784</code></a>
Apply clippy to doctest</li>
<li><a
href="ade4308d3e"><code>ade4308</code></a>
tests: Update ui test output to nightly-2026-01-22</li>
<li>Additional commits viewable in <a
href="https://github.com/taiki-e/pin-project/compare/v1.1.10...v1.1.11">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pin-project&package-manager=cargo&previous-version=1.1.10&new-version=1.1.11)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-05 00:30:21 +00:00
dependabot[bot]
503b02a822 build: bump the accesskit-related group with 2 updates (#43021)
Bumps the accesskit-related group with 2 updates:
[accesskit_windows](https://github.com/AccessKit/accesskit) and
[accesskit_winit](https://github.com/AccessKit/accesskit).

Updates `accesskit_windows` from 0.32.0 to 0.32.1
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/AccessKit/accesskit/releases">accesskit_windows's
releases</a>.</em></p>
<blockquote>
<h2>accesskit_windows: v0.32.1</h2>
<h2><a
href="https://github.com/AccessKit/accesskit/compare/accesskit_windows-v0.32.0...accesskit_windows-v0.32.1">0.32.1</a>
(2026-03-04)</h2>
<h3>Dependencies</h3>
<ul>
<li>The following workspace dependencies were updated
<ul>
<li>dependencies
<ul>
<li>accesskit_consumer bumped from 0.34.0 to 0.35.0</li>
</ul>
</li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="1bbcf10094"><code>1bbcf10</code></a>
chore: release main (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/692">#692</a>)</li>
<li><a
href="33fc4f0669"><code>33fc4f0</code></a>
feat: Implement text attributes for AT-SPI (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/695">#695</a>)</li>
<li><a
href="b5979a4c88"><code>b5979a4</code></a>
fix: Correctly register interfaces on Unix after Hyperlink was added (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/694">#694</a>)</li>
<li><a
href="7342525b8a"><code>7342525</code></a>
refactor: Use TreeState::locate_node in adapters</li>
<li><a
href="941a96d161"><code>941a96d</code></a>
refactor!: Allow locating nodes without Tree access</li>
<li><a
href="641b05b10d"><code>641b05b</code></a>
feat: Expose text attributes on macOS (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/691">#691</a>)</li>
<li><a
href="da70097f57"><code>da70097</code></a>
chore: release main (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/688">#688</a>)</li>
<li><a
href="8392850941"><code>8392850</code></a>
fix: Don't report selected state when toggled on Android (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/689">#689</a>)</li>
<li><a
href="6146089404"><code>6146089</code></a>
fix: Populate range info on Android (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/686">#686</a>)</li>
<li><a
href="67590283b0"><code>6759028</code></a>
fix: Update bytes dependency to fix RUSTSEC-2026-0007 (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/687">#687</a>)</li>
<li>See full diff in <a
href="https://github.com/AccessKit/accesskit/compare/accesskit_windows-v0.32.0...accesskit_windows-v0.32.1">compare
view</a></li>
</ul>
</details>
<br />

Updates `accesskit_winit` from 0.32.1 to 0.32.2
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/AccessKit/accesskit/releases">accesskit_winit's
releases</a>.</em></p>
<blockquote>
<h2>accesskit_winit: v0.32.2</h2>
<h2><a
href="https://github.com/AccessKit/accesskit/compare/accesskit_winit-v0.32.1...accesskit_winit-v0.32.2">0.32.2</a>
(2026-03-04)</h2>
<h3>Dependencies</h3>
<ul>
<li>The following workspace dependencies were updated
<ul>
<li>dependencies
<ul>
<li>accesskit_windows bumped from 0.32.0 to 0.32.1</li>
<li>accesskit_macos bumped from 0.25.0 to 0.26.0</li>
<li>accesskit_unix bumped from 0.20.0 to 0.21.0</li>
<li>accesskit_android bumped from 0.7.1 to 0.7.2</li>
</ul>
</li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="1bbcf10094"><code>1bbcf10</code></a>
chore: release main (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/692">#692</a>)</li>
<li><a
href="33fc4f0669"><code>33fc4f0</code></a>
feat: Implement text attributes for AT-SPI (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/695">#695</a>)</li>
<li><a
href="b5979a4c88"><code>b5979a4</code></a>
fix: Correctly register interfaces on Unix after Hyperlink was added (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/694">#694</a>)</li>
<li><a
href="7342525b8a"><code>7342525</code></a>
refactor: Use TreeState::locate_node in adapters</li>
<li><a
href="941a96d161"><code>941a96d</code></a>
refactor!: Allow locating nodes without Tree access</li>
<li><a
href="641b05b10d"><code>641b05b</code></a>
feat: Expose text attributes on macOS (<a
href="https://redirect.github.com/AccessKit/accesskit/issues/691">#691</a>)</li>
<li>See full diff in <a
href="https://github.com/AccessKit/accesskit/compare/accesskit_winit-v0.32.1...accesskit_winit-v0.32.2">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-05 00:17:17 +00:00
Taym Haddadi
251bf8c598 indexeddb: remove blocking GenerateKey sync IPC (#42966)
indexeddb: remove blocking GenerateKey sync IPC

Testing: covered by indexeddb WPT tests. 
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-04 21:54:26 +00:00
Luke Warlow
759d0e0f1c script: Improvements to command button implementation (#42883)
Improvements to command button implementation

- Correctly handle the button's optional value concept
- Add the button as the source value for the CommandEvent
- Fix handling of buttons in auto state

Testing: Existing tests

Signed-off-by: Luke Warlow <lwarlow@igalia.com>
2026-03-04 15:40:36 +00:00
Domenico Rizzo
1f6037d022 script: Refactors GPURenderPassEncoder's drop implementation. (#43018)
Moves the `Drop` logic for `GPURenderPassEncoder` into a dedicated
helper struct, `DroppableGPURenderPassEncoder`. This ensures that DOM
types do not directly implement `Drop`, aligning with the policy for
resource management in the DOM. The associated `Bindings.conf` entry is
removed as direct `Drop` is no longer needed for this type.

Testing: WebGPU tests just cover its cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-04 14:48:51 +00:00
Simon Wülker
78efa1860d script: Use stylo dom apis for querySelector/querySelectorAll (#42991)
Stylo has ready-to-use apis for `Node::querySelector` and
`Node::querySelectorAll`. We currently instead set up our own selector
queries, which is neither as correct nor as performant, so this change
makes servo use the stylo interfaces instead.

This change contains a fair amount of unsafe code - review with caution!

Notably, this makes the tab component from the astro framework work
correctly in servo (https://starlight.astro.build/components/tabs/).
I've seen that (broken) component on multiple websites.

Fixes https://github.com/servo/servo/issues/41105
Testing: New tests start to pass

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-04 14:18:48 +00:00
Narfinger
5aed3ab517 net: Implement LazyGenericCallback and use it in websocket (#42077)
We introduce a new type of callback, LazyGenericCallback and use it in
websocket initialization.

The basic requirement is that for websocket the place where the callback
is called and where it is constructed are over several functions,
including async functions. To make this generic, we implement
LazyGenericCallback and a GeneralCallbackSetter. The CallbackSetter can
be used to set the callback which then will be transfered to the
LazyGenericCallback which calls it on messages send to it.

Finally, we use this to "Generify" the initialization of WebSockets.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>

Testing: We have new tests for LazyGenericCallback and wpt test run
here: https://github.com/Narfinger/servo/actions/runs/21246091767

---------

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
Co-authored-by: Jonathan Schwender <55576758+jschwe@users.noreply.github.com>
2026-03-04 13:37:33 +00:00
Taym Haddadi
cbc2156e86 indexeddb: restore object store metadata on upgrade abort and sync connection (#42786)
The frontend connection metadata was not consistently synchronized with
backend object store state during open/upgrade, and upgrade abort did
not fully restore the connection object store set in all cases.

Testing: More indexeddb tests should pass.
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-04 13:33:45 +00:00
atbrakhi
9c43b52afb devtools: Implement function name preview in debugger popup (#42996)
The debugger preview popup was showing `function ()` for all functions.
This change implements support to show function name in the debugger
preview popup.

This is initial work towards showing other values in debugger preview
popup!

**Before:**
<img width="306" height="118" alt="image"
src="https://github.com/user-attachments/assets/5c090820-4862-4234-a6ea-50666f83c192"
/>


**After:**
<img width="282" height="128" alt="image"
src="https://github.com/user-attachments/assets/869a0122-c9da-4098-bb77-8a1110c29d48"
/>

<img width="286" height="137" alt="image"
src="https://github.com/user-attachments/assets/8655a8cb-bbd3-4b80-a297-daac58a6337f"
/>


Testing: Existing test passes
Fixes: Part of #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-04 11:14:45 +00:00
dependabot[bot]
0ba263be5b build: bump range-alloc from 0.1.4 to 0.1.5 (#43007)
Bumps [range-alloc](https://github.com/gfx-rs/range-alloc) from 0.1.4 to
0.1.5.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/gfx-rs/range-alloc/commits">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=range-alloc&package-manager=cargo&previous-version=0.1.4&new-version=0.1.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 09:58:34 +00:00
Servo WPT Sync
0343706a02 Sync WPT with upstream (04-03-2026) (#43011)
Automated downstream sync of changes from upstream as of 04-03-2026
[no-wpt-sync]

Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
2026-03-04 07:24:31 +00:00
Josh Matthews
f206571869 layout: Prevent DomRefCell::borrow from being used in layout code (#42976)
DomRefCell::borrow inside of layout code is risky because it leads to
memory races if the code is ever called from layout worker threads. This
can be caught via TSAN, but we can also catch it deterministically in CI
by using our existing thread state debug assertions correctly.

Testing: Existing WPT test coverage is sufficient.
Fixes: #42962

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-04 06:44:39 +00:00
Loïc Denuzière
1970e57b26 paint: Bound screenshot to the viewport (#42739)
Ensure that the screenshot rectangle is bounded by the width and height
of the viewport.

Testing: The WPT test `test_clip_huge_element_to_viewport` now passes
instead of crashing. It is also fixed so that the returned screenshot
size is the expected 800x600; it would otherwise be 792x600 due to the
body margin.

Fixes: #42530

---------

Signed-off-by: Loic Denuziere <loic@denuziere.net>
Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
Co-authored-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-04 06:43:24 +00:00
Euclid Ye
a1fde82cb0 pixels: Properly format the panic message in webrender_image_descriptor_and_data_for_frame (#43009)
`expect` is not a macro.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-04 05:49:30 +00:00
dependabot[bot]
4f2d224b7a build: bump tokio-macros from 2.6.0 to 2.6.1 (#43006)
Bumps [tokio-macros](https://github.com/tokio-rs/tokio) from 2.6.0 to
2.6.1.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e3ee4e58dc"><code>e3ee4e5</code></a>
chore: prepare tokio-macros v2.6.1 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7943">#7943</a>)</li>
<li><a
href="8c980ea75a"><code>8c980ea</code></a>
io: add <code>write_all_vectored</code> to <code>tokio-util</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7768">#7768</a>)</li>
<li><a
href="e35fd6d6b7"><code>e35fd6d</code></a>
ci: fix patch during clippy step (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7935">#7935</a>)</li>
<li><a
href="03fe44c103"><code>03fe44c</code></a>
runtime: fix <code>event_interval</code> doc (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7932">#7932</a>)</li>
<li><a
href="d18e5dfbb0"><code>d18e5df</code></a>
io: fix race in <code>Mock::poll_write</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7882">#7882</a>)</li>
<li><a
href="f21f2693f0"><code>f21f269</code></a>
runtime: fix race condition during the blocking pool shutdown (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7922">#7922</a>)</li>
<li><a
href="d81e8f0acb"><code>d81e8f0</code></a>
macros: remove (most) local <code>use</code> declarations in
<code>tokio::select!</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7929">#7929</a>)</li>
<li><a
href="25e7f2641e"><code>25e7f26</code></a>
rt: fix missing quotation in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7925">#7925</a>)</li>
<li><a
href="e1a91ef114"><code>e1a91ef</code></a>
util: fix typo in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7926">#7926</a>)</li>
<li><a
href="1b11840f53"><code>1b11840</code></a>
task: clarify when to use <code>spawn_blocking</code> vs dedicated
threads (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7923">#7923</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-macros-2.6.0...tokio-macros-2.6.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio-macros&package-manager=cargo&previous-version=2.6.0&new-version=2.6.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 00:52:01 +00:00
dependabot[bot]
e164127a99 build: bump async-compression from 0.4.40 to 0.4.41 (#43005)
Bumps
[async-compression](https://github.com/Nullus157/async-compression) from
0.4.40 to 0.4.41.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="269174b4be"><code>269174b</code></a>
chore(async-compression): release v0.4.41 (<a
href="https://redirect.github.com/Nullus157/async-compression/issues/458">#458</a>)</li>
<li><a
href="37e366b3ed"><code>37e366b</code></a>
Fix UnwindSafe auto impl (<a
href="https://redirect.github.com/Nullus157/async-compression/issues/459">#459</a>)</li>
<li><a
href="c39c6215cb"><code>c39c621</code></a>
On error the encoder/decoder now emit everything it was able to decode.
(<a
href="https://redirect.github.com/Nullus157/async-compression/issues/454">#454</a>)</li>
<li>See full diff in <a
href="https://github.com/Nullus157/async-compression/compare/async-compression-v0.4.40...async-compression-v0.4.41">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=async-compression&package-manager=cargo&previous-version=0.4.40&new-version=0.4.41)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 00:44:25 +00:00
dependabot[bot]
45f1bdbf41 build: bump jiff from 0.2.22 to 0.2.23 (#43004)
Bumps [jiff](https://github.com/BurntSushi/jiff) from 0.2.22 to 0.2.23.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/BurntSushi/jiff/blob/master/CHANGELOG.md">jiff's
changelog</a>.</em></p>
<blockquote>
<h1>0.2.23 (2026-03-03)</h1>
<p>This release updates Jiff's bundled copy of the [IANA Time Zone
Database]
to <code>2026a</code>. See the <a
href="https://lists.iana.org/hyperkitty/list/tz-announce@iana.org/thread/ASPLBE3A4BAEXIOQ3KZ6EJSJWBU6L53G/"><code>2026a</code>
release announcement</a> for more details.</p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e5b7f0d061"><code>e5b7f0d</code></a>
0.2.23</li>
<li><a
href="ff23414041"><code>ff23414</code></a>
jiff-tzdb-0.1.6</li>
<li><a
href="225d54b3fa"><code>225d54b</code></a>
jiff-tzdb: update to tzdb 2026a</li>
<li>See full diff in <a
href="https://github.com/BurntSushi/jiff/compare/jiff-static-0.2.22...jiff-static-0.2.23">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=jiff&package-manager=cargo&previous-version=0.2.22&new-version=0.2.23)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 00:38:48 +00:00
dependabot[bot]
1a88a27370 build: bump quote from 1.0.44 to 1.0.45 (#43003)
Bumps [quote](https://github.com/dtolnay/quote) from 1.0.44 to 1.0.45.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/dtolnay/quote/releases">quote's
releases</a>.</em></p>
<blockquote>
<h2>1.0.45</h2>
<ul>
<li>Add ToTokens impl for Arc&lt;T&gt; (<a
href="https://redirect.github.com/dtolnay/quote/issues/326">#326</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="842ffde933"><code>842ffde</code></a>
Release 1.0.45</li>
<li><a
href="93d691cce9"><code>93d691c</code></a>
Merge pull request <a
href="https://redirect.github.com/dtolnay/quote/issues/326">#326</a>
from dtolnay/arc</li>
<li><a
href="d27d589652"><code>d27d589</code></a>
ToTokens for Arc</li>
<li><a
href="24d10826cf"><code>24d1082</code></a>
Update ui test suite to nightly-2026-02-18</li>
<li><a
href="26b127632c"><code>26b1276</code></a>
Unpin CI miri toolchain</li>
<li><a
href="c5e1c9ef46"><code>c5e1c9e</code></a>
Pin CI miri to nightly-2026-02-11</li>
<li><a
href="58e21550d8"><code>58e2155</code></a>
Remove compiler version support from readme</li>
<li><a
href="1fc6b50769"><code>1fc6b50</code></a>
Raise required compiler to Rust 1.71</li>
<li><a
href="515480a434"><code>515480a</code></a>
Update ui test suite to nightly-2026-02-01</li>
<li><a
href="2c5e7709dd"><code>2c5e770</code></a>
Update ui test suite to nightly-2026-01-30</li>
<li>See full diff in <a
href="https://github.com/dtolnay/quote/compare/1.0.44...1.0.45">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quote&package-manager=cargo&previous-version=1.0.44&new-version=1.0.45)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 00:38:13 +00:00
dependabot[bot]
ff82f949a7 build: bump tokio from 1.49.0 to 1.50.0 in the tokio-rs-related group (#43002)
Bumps the tokio-rs-related group with 1 update:
[tokio](https://github.com/tokio-rs/tokio).

Updates `tokio` from 1.49.0 to 1.50.0
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tokio-rs/tokio/releases">tokio's
releases</a>.</em></p>
<blockquote>
<h2>Tokio v1.50.0</h2>
<h1>1.50.0 (Mar 3rd, 2026)</h1>
<h3>Added</h3>
<ul>
<li>net: add <code>TcpStream::set_zero_linger</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7837">#7837</a>)</li>
<li>rt: add <code>is_rt_shutdown_err</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7771">#7771</a>)</li>
</ul>
<h3>Changed</h3>
<ul>
<li>io: add optimizer hint that <code>memchr</code> returns in-bounds
pointer (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7792">#7792</a>)</li>
<li>io: implement vectored writes for <code>write_buf</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7871">#7871</a>)</li>
<li>runtime: panic when <code>event_interval</code> is set to 0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7838">#7838</a>)</li>
<li>runtime: shorten default thread name to fit in Linux limit (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7880">#7880</a>)</li>
<li>signal: remember the result of <code>SetConsoleCtrlHandler</code>
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7833">#7833</a>)</li>
<li>signal: specialize windows <code>Registry</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7885">#7885</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>io: always cleanup <code>AsyncFd</code> registration list on
deregister (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7773">#7773</a>)</li>
<li>macros: remove (most) local <code>use</code> declarations in
<code>tokio::select!</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7929">#7929</a>)</li>
<li>net: fix <code>GET_BUF_SIZE</code> constant for <code>target_os =
&quot;android&quot;</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7889">#7889</a>)</li>
<li>runtime: avoid redundant unpark in current_thread scheduler (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7834">#7834</a>)</li>
<li>runtime: don't park in <code>current_thread</code> if
<code>before_park</code> defers waker (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7835">#7835</a>)</li>
<li>io: fix write readiness on ESP32 on short writes (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7872">#7872</a>)</li>
<li>runtime: wake deferred tasks before entering
<code>block_in_place</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7879">#7879</a>)</li>
<li>sync: drop rx waker when oneshot receiver is dropped (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7886">#7886</a>)</li>
<li>runtime: fix double increment of <code>num_idle_threads</code> on
shutdown (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7910">#7910</a>,
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7918">#7918</a>,
<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7922">#7922</a>)</li>
</ul>
<h3>Unstable</h3>
<ul>
<li>fs: check for io-uring opcode support (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7815">#7815</a>)</li>
<li>runtime: avoid lock acquisition after uring init (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7850">#7850</a>)</li>
</ul>
<h3>Documented</h3>
<ul>
<li>docs: update outdated unstable features section (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7839">#7839</a>)</li>
<li>io: clarify the behavior of <code>AsyncWriteExt::shutdown()</code>
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7908">#7908</a>)</li>
<li>io: explain how to flush stdout/stderr (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7904">#7904</a>)</li>
<li>io: fix incorrect and confusing <code>AsyncWrite</code>
documentation (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7875">#7875</a>)</li>
<li>rt: clarify the documentation of <code>Runtime::spawn</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7803">#7803</a>)</li>
<li>rt: fix missing quotation in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7925">#7925</a>)</li>
<li>runtime: correct the default thread name in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7896">#7896</a>)</li>
<li>runtime: fix <code>event_interval</code> doc (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7932">#7932</a>)</li>
<li>sync: clarify RwLock fairness documentation (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7919">#7919</a>)</li>
<li>sync: clarify that <code>recv</code> returns <code>None</code> once
closed and no more messages (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7920">#7920</a>)</li>
<li>task: clarify when to use <code>spawn_blocking</code> vs dedicated
threads (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7923">#7923</a>)</li>
<li>task: doc that task drops before <code>JoinHandle</code> completion
(<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7825">#7825</a>)</li>
<li>signal: guarantee that listeners never return <code>None</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7869">#7869</a>)</li>
<li>task: fix task module feature flags in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7891">#7891</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="0273e45ead"><code>0273e45</code></a>
chore: prepare Tokio v1.50.0 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7934">#7934</a>)</li>
<li><a
href="e3ee4e58dc"><code>e3ee4e5</code></a>
chore: prepare tokio-macros v2.6.1 (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7943">#7943</a>)</li>
<li><a
href="8c980ea75a"><code>8c980ea</code></a>
io: add <code>write_all_vectored</code> to <code>tokio-util</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7768">#7768</a>)</li>
<li><a
href="e35fd6d6b7"><code>e35fd6d</code></a>
ci: fix patch during clippy step (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7935">#7935</a>)</li>
<li><a
href="03fe44c103"><code>03fe44c</code></a>
runtime: fix <code>event_interval</code> doc (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7932">#7932</a>)</li>
<li><a
href="d18e5dfbb0"><code>d18e5df</code></a>
io: fix race in <code>Mock::poll_write</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7882">#7882</a>)</li>
<li><a
href="f21f2693f0"><code>f21f269</code></a>
runtime: fix race condition during the blocking pool shutdown (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7922">#7922</a>)</li>
<li><a
href="d81e8f0acb"><code>d81e8f0</code></a>
macros: remove (most) local <code>use</code> declarations in
<code>tokio::select!</code> (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7929">#7929</a>)</li>
<li><a
href="25e7f2641e"><code>25e7f26</code></a>
rt: fix missing quotation in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7925">#7925</a>)</li>
<li><a
href="e1a91ef114"><code>e1a91ef</code></a>
util: fix typo in docs (<a
href="https://redirect.github.com/tokio-rs/tokio/issues/7926">#7926</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tokio-rs/tokio/compare/tokio-1.49.0...tokio-1.50.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tokio&package-manager=cargo&previous-version=1.49.0&new-version=1.50.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-04 00:22:57 +00:00
Oriol Brufau
cd8973873d build(deps): bump Stylo to "Make preference system more robust" (#42741)
Bumps Stylo to https://github.com/servo/stylo/pull/314

In particular, we would now get a compile error because we were setting
`layout.flexbox.enabled` and `layout.css.transition-behavior.enabled`,
even if Stylo removed at some point. So stop setting them.

Testing: Not needed, no behavior change

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-03 22:28:59 +00:00
Martin Robinson
027910e544 layout/fonts: Mitigate races related to quirks mode and fallback fonts (#42960)
This change includes two related fixes for flakiness revealed by #42847.

1. When caching fonts, try harder to not re-cache a font. This could
   happen due to a race condition with the read-write lock on the font
   cache. This change improves memory usage in some cases as it prevents
   a font from being loaded twice.
2. Incorporate both the strut size and the block size contribution of a
   previously unused font in an inline container. Before the code was
   incorporating one or the other. In addition, *only* incorporate the
   block contribution of a previously unused font if its metrics
   meaningfully differ from the container's default font. This was the
   case triggered by failing to have the fix in part one of the change.

Testing: This fixes flakiness in an internal WPT-style test.
Fixes: #42908.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
Co-authored-by: Luke Warlow <lwarlow@igalia.com>
2026-03-03 21:10:05 +00:00
Shubham Gupta
711644cfaa layout: Encapsulate iframe related data into IFrameInfo struct. (#42954)
Wraps data related to iframe in `IFrameInfo` struct.

Testing: This is just a little refactor. No change in behavior expected.
Successful compilation is enough to verify.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-03 20:18:49 +00:00
Josh Matthews
3508beac5a servoshell: Add missing format string. (#42756)
This message appeared in a backtrace without any format replacement
taking place.

Testing: No tests for error messages.

---------

Signed-off-by: Josh Matthews <josh@joshmatthews.net>
2026-03-03 20:18:31 +00:00
atbrakhi
27946914dc devtools: Use actual class name in ObjectActor (#42994)
Class name in `ObjectActor` was harcoded to `Window`, which is wrong.
This change removes the hardcoded value and replaces it with actual
class name.

**Before:**
<img width="320" height="163" alt="image"
src="https://github.com/user-attachments/assets/f94df58a-5309-4fd1-bb02-aa06dfeb32c3"
/>


**After:**
<img width="353" height="138" alt="image"
src="https://github.com/user-attachments/assets/ad129676-8c3d-48e2-a543-1447c75c40f0"
/>

Testing: Existing test passes
Fixes: part of #36027 
Depends on https://github.com/servo/servo/pull/42936

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-03 19:15:14 +00:00
Jonathan Schwender
baf2d0fc8a Fix ohos.yml bencher file size on main (#42997)
Renaming the job in #42929 silently broke the evaluation here.

Testing: Can only be tested on main / in priviledge contexts / otherwise
the unsigned binary is anyway built.
Fixes: ohos bencher failing on main (since the wrong binary name is
chosen)

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-03 16:24:01 +00:00
batu_hoang
712b7b3b63 stylo: Enable system color (#42529)
Enable system color:
- stylo PR: https://github.com/servo/stylo/pull/302
- Update WPT expectation
- Update UA styleshee to use system color value

---------

Signed-off-by: batu_hoang <longvatrong111@gmail.com>
2026-03-03 16:07:01 +00:00
Kingsley Yung
059d39aead script: Resolve name referencing issue during ML-DSA export (#42984)
In the WebCrypto modern algorithm specification, the issue
(https://github.com/WICG/webcrypto-modern-algos/issues/47) on algorithm
name referencing in the export key operation of ML-KEM had been resolved
by the following commit in the specification repository:


705f8ec6ce

Our implementation actually matches the new specification. We simply
update the specification text, with some minor refactoring accordingly.

This is equivalent the changes on ML-KEM in #42918 in which I forgot to
include the counterpart for ML-DSA :(

Testing: Refactoring. Existing tests suffice.

Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
2026-03-03 15:29:52 +00:00
Simon Wülker
036cb9a68c script: Set relatedTarget for {mouse, pointer}x{enter, leave, out, over} events (#42989)
Testing: New tests start to pass. Most related tests still fail because
we dispatch mouse and pointer events in the wrong order.

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-03 15:18:30 +00:00
Jonathan Schwender
4e44e366d3 servoshell: Delete duplicate Info.plist (#42955)
We had two `Info.plist` files. The maintained one is in the root
directory of this repository.
There is no reason for two plist files, so remove the unmaintained one. 
Additionally, we also move the maintained version from the root
directory to the servoshell directory.

Testing: We don't test the contents of the plist file.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-03 15:14:30 +00:00
Narfinger
c204a799a7 OHOS CI: Fix resident-smaps recording (#42985)
Because of the move of the reporting function to
update_user_interface_state and the multiple events of
LoadStatus::Complete, the previous reporting did not work correctly
anymore.

This fixes it by manually summing up the reports for
'resident-according-to-smaps' and using the hitrace-bencher
point_filter_type Largest.

This should restore the bencher graph.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>

Testing: No automatic test but manual test here:
https://github.com/Narfinger/servo/actions/runs/22617931816

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-03 14:28:21 +00:00
Jonathan Schwender
27fb3340c8 Fix nightly release (#42983)
Renaming the openharmony build job in #42929 caused artifact_ids to be
empty, which caused release failures.
Additionally, we add a validation step to the upload workflow, to
quickly pinpoint the issue of a missing input parameter,
since apparently github won't throw an error if a required input
parameter is empty.
This should make it easier to pinpoint the issue if it happens again. 

Testing: Not tested.

---------

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-03 14:23:52 +00:00
atbrakhi
630e4b75da devtools: Implement frame scoped evaluation (#42936)
When paused at a breakpoint, hovering over local variables now shows
their value. Previously `eval` used `executeInGlobal()` which could not
access local scope, so hovering showed `ReferenceError` instead of the
actual value.


https://github.com/user-attachments/assets/05247b82-4e4d-422d-a428-63e46b55d55f

Testing: Added a new test
Fixes: Part #36027

Signed-off-by: atbrakhi <atbrakhi@igalia.com>
2026-03-03 14:22:25 +00:00
Euclid Ye
914121ef25 pointerevent_support.js: touchScrollInTarget smoothly (#42652)
The util `function touchScrollInTarget` aims to touch scroll the target
smoothly. However, currently it creates **accelerating** scrolling: as
the coordinates of `target` keep changing during the touch move which we
use as origin. This is not intended.

What's worse, this can trigger [out of
bound](https://w3c.github.io/webdriver/#ref-for-dfn-move-target-out-of-bounds-2:~:text=If%20y%20is%20less%20than%200%20or%20greater%20than%20the%20height%20of%20the%20viewport%20in%20CSS%20pixels%2C%20then%20return%20error%20with%20error%20code%20move%20target%20out%20of%20bounds%2E)
WebDriver error, and the tests never work.

This has caused problem for Firefox/Safari as well, e.g.
[pointerevent_touch-action-table-none-test_touch.html](https://wpt.fyi/results/pointerevents/pointerevent_touch-action-table-none-test_touch.html?run_id=5177777654595584&run_id=5095681367998464&run_id=5083756189974528).

Testing: Updated expectations of existing tests.




Before for `pointerevent_touch-action-table-none-test_touch.html`:


https://github.com/user-attachments/assets/7f14eee7-bdec-4ea4-a83e-684b2b65d951

After:



https://github.com/user-attachments/assets/9b05a9e6-164d-419c-a519-383dab856a4c

---------

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-03 14:22:01 +00:00
Domenico Rizzo
bff59c629a script: Refactors GPURenderBundle's drop implementation. (#42982)
Moves the `Drop` logic for `GPURenderBundle` into a dedicated helper
struct, `DroppableGPURenderBundle`. This change ensures that
`GPURenderBundle` itself does not directly implement `Drop`, aligning
with the policy to prevent direct `Drop` implementations on DOM types.

Removes the `allowDropImpl` configuration for `GPURenderBundle` from
script bindings.

Testing: WebGPU tests cover all related cases
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-03 11:59:34 +00:00
Simon Wülker
d5f02b6f15 script: Fire pointer, mouseenter, and mouseleaveevents respecting the flat tree (#42987)
The [spec](https://w3c.github.io/pointerevents/#the-pointerenter-event)
says that pointer events should be fired for the element hovered by the
pointer and all its ancestors. That implies using the flat tree, which
we were not doing before.

Testing: This change fixes a web platform test and makes
https://github.com/simeydotme/hover-tilt work in servo

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-03 11:37:26 +00:00
Martin Robinson
eb63ad307e mach: Remove generic nightly download support (#42977)
See #42956. It's quite likely that this code has bitrotted and if this
feature is desired, should probably download the nightlies from GitHub
and also be updated to support our current packaging output.

Testing: This is just removing unused code from our build scripts.
Fixes: #42956.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
2026-03-03 10:03:02 +00:00
Oriol Brufau
36c6594c76 script: Avoid data race in ServoLayoutElement::apply_selector_flags() (#42963)
This changes `Element::selector_flags` from `Cell<ElementSelectorFlags>`
to `AtomicUsize`, thus avoiding the risk of data races.

Testing: Tested manually. We don't run tests using TSAN builds.
Fixes: #37495

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
2026-03-03 09:52:01 +00:00
webbeef
295e019d00 script: pointer events: pointerenter, pointerout, pointerleave, pointerover (#42736)
Adds support for more pointer events: pointerenter, pointerout,
pointerleave, pointerover
Also add global event handlers that were missing.

Testing: WPT expectations are updated.

cc @yezhizhen

Signed-off-by: webbeef <me@webbeef.org>
2026-03-03 08:27:53 +00:00
dependabot[bot]
b68628ad82 build: bump ipnet from 2.11.0 to 2.12.0 (#42971)
Bumps [ipnet](https://github.com/krisprice/ipnet) from 2.11.0 to 2.12.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/krisprice/ipnet/releases">ipnet's
releases</a>.</em></p>
<blockquote>
<p>Backwards compatible schemars 1.* support using version specific
features#67</p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/krisprice/ipnet/blob/master/RELEASES.md">ipnet's
changelog</a>.</em></p>
<blockquote>
<h2>Version 2.12.0</h2>
<ul>
<li>Backwards compatible schemars 1.* support using version specific
features#67</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="65c04c3556"><code>65c04c3</code></a>
Update version number.</li>
<li><a
href="397bf726e7"><code>397bf72</code></a>
Merge pull request <a
href="https://redirect.github.com/krisprice/ipnet/issues/67">#67</a>
from StefanTerdell/schemars-1</li>
<li><a
href="687f2703d9"><code>687f270</code></a>
Add support for schemars 1, deprecate old features</li>
<li>See full diff in <a
href="https://github.com/krisprice/ipnet/compare/2.11.0...2.12.0">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=ipnet&package-manager=cargo&previous-version=2.11.0&new-version=2.12.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-03 08:13:49 +00:00
Euclid Ye
76d8e343b9 ci: Remove dummy audio device related steps for linux-wpt (#42945)
This doesn't seem to have any impact.

[Try](https://github.com/servo/servo/actions/runs/22546956503)

Testing: This is a change to the testing CI configuration.

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-03 06:06:03 +00:00
dependabot[bot]
9cf9bdbe71 build: bump jiff from 0.2.21 to 0.2.22 (#42973)
Bumps [jiff](https://github.com/BurntSushi/jiff) from 0.2.21 to 0.2.22.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/BurntSushi/jiff/blob/master/CHANGELOG.md">jiff's
changelog</a>.</em></p>
<blockquote>
<h1>0.2.22 (2026-02-28)</h1>
<p>This release includes a bug fix where fallible conversions from
signed
durations to unsigned durations could panic in some cases.</p>
<p>Bug fixes:</p>
<ul>
<li><a
href="https://redirect.github.com/BurntSushi/jiff/issues/526">#526</a>:
Fix a panicking bug that occurs for
<code>std::time::Duration::try_from(SignedDuration::new(0,
-1))</code>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="4fb63be9c2"><code>4fb63be</code></a>
0.2.22</li>
<li><a
href="47f5abf9ee"><code>47f5abf</code></a>
signed_duration: fix a panicking bug in `TryFrom&lt;SignedDuration&gt;
for std::tim...</li>
<li><a
href="c3d960e192"><code>c3d960e</code></a>
fuzz: update dependencies</li>
<li>See full diff in <a
href="https://github.com/BurntSushi/jiff/compare/jiff-static-0.2.21...jiff-static-0.2.22">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=jiff&package-manager=cargo&previous-version=0.2.21&new-version=0.2.22)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-03 02:11:29 +00:00
dependabot[bot]
a688b32c1b build: bump aws-lc-rs from 1.16.0 to 1.16.1 (#42972)
Bumps [aws-lc-rs](https://github.com/aws/aws-lc-rs) from 1.16.0 to
1.16.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/aws/aws-lc-rs/releases">aws-lc-rs's
releases</a>.</em></p>
<blockquote>
<h2>aws-lc-rs v1.16.1</h2>
<h2>What's Changed</h2>
<ul>
<li>Update to aws-lc-fips-sys v0.13.12 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1052">aws/aws-lc-rs#1052</a></li>
<li>Update to aws-lc-sys v0.38.0 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1053">aws/aws-lc-rs#1053</a></li>
<li>Documentation for <code>dev-tests-only</code> feature and improved
platform support clarity by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1050">aws/aws-lc-rs#1050</a></li>
</ul>
<h3>Build Improvements</h3>
<ul>
<li>Check cranelift when using the cargo-clif executable by <a
href="https://github.com/frederikhors"><code>@​frederikhors</code></a>
in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1047">aws/aws-lc-rs#1047</a></li>
</ul>
<h2>Other merged PRs</h2>
<ul>
<li>Prepare aws-lc-rs v1.16.1 by <a
href="https://github.com/justsmth"><code>@​justsmth</code></a> in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1051">aws/aws-lc-rs#1051</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a
href="https://github.com/frederikhors"><code>@​frederikhors</code></a>
made their first contribution in <a
href="https://redirect.github.com/aws/aws-lc-rs/pull/1047">aws/aws-lc-rs#1047</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.0...v1.16.1">https://github.com/aws/aws-lc-rs/compare/v1.16.0...v1.16.1</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="70d449ad1d"><code>70d449a</code></a>
Prepare v1.16.1 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1051">#1051</a>)</li>
<li><a
href="fdba3e3c5f"><code>fdba3e3</code></a>
Prepare aws-lc-sys v0.38.0 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1053">#1053</a>)</li>
<li><a
href="e6e2cfd271"><code>e6e2cfd</code></a>
Update to aws-lc-fips-sys v0.13.12 (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1052">#1052</a>)</li>
<li><a
href="d93f5fbf23"><code>d93f5fb</code></a>
docs: Document dev-tests-only feature and improve platform support
clarity (#...</li>
<li><a
href="b6b155809d"><code>b6b1558</code></a>
Check cranelift when using the cargo-clif executable (<a
href="https://redirect.github.com/aws/aws-lc-rs/issues/1047">#1047</a>)</li>
<li>See full diff in <a
href="https://github.com/aws/aws-lc-rs/compare/v1.16.0...v1.16.1">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=aws-lc-rs&package-manager=cargo&previous-version=1.16.0&new-version=1.16.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-03 02:10:43 +00:00
dependabot[bot]
0f4ff9e5f9 build: bump winit from 0.30.12 to 0.30.13 (#42968)
Bumps [winit](https://github.com/rust-windowing/winit) from 0.30.12 to
0.30.13.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-windowing/winit/releases">winit's
releases</a>.</em></p>
<blockquote>
<h2>Winit version 0.30.13</h2>
<h3>Added</h3>
<ul>
<li>On Wayland, add <code>Window::set_resize_increments</code>.</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>On macOS, fixed crash when dragging non-file content onto
window.</li>
<li>On X11, fix <code>set_hittest</code> not working on some window
managers.</li>
<li>On X11, fix debug mode overflow panic in
<code>set_timestamp</code>.</li>
<li>On macOS, fix crash in <code>set_marked_text</code> when native
Pinyin IME sends out-of-bounds <code>selected_range</code>.</li>
<li>On Windows, fix <code>WM_IME_SETCONTEXT</code> IME UI flag masking
on <code>lParam</code>.</li>
<li>On Android, populate <code>KeyEvent::text</code> and
<code>KeyEvent::text_with_all_modifiers</code> via
<code>Key::to_text()</code>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="e9809ef54b"><code>e9809ef</code></a>
Winit version 0.30.13</li>
<li><a
href="efb5b37fff"><code>efb5b37</code></a>
chore: fix ci</li>
<li><a
href="a9baf5ecda"><code>a9baf5e</code></a>
fix(android): Populate <code>KeyEvent.text</code> via
<code>Key::to_text()</code></li>
<li><a
href="6bb43fd130"><code>6bb43fd</code></a>
wayland: implement resize increments</li>
<li><a
href="17a73f4dd4"><code>17a73f4</code></a>
win32: fix ime setcontext lparam</li>
<li><a
href="bccc568345"><code>bccc568</code></a>
fix(macOS): clamp IME selected_range to prevent substringToIndex
crash</li>
<li><a
href="69b8a07ae0"><code>69b8a07</code></a>
winit-x11: fix debug mode overflow panic in
<code>set_timestamp</code></li>
<li><a
href="3eb731f8b5"><code>3eb731f</code></a>
winit-x11: replace xfixes with x11rb in set_hittest</li>
<li><a
href="7035dd554f"><code>7035dd5</code></a>
winit-win32: Fix ABI mismatch in INIT_MAIN_THREAD_ID</li>
<li><a
href="ab4c6bfc82"><code>ab4c6bf</code></a>
macOS: fix a crash when dragging non-file content onto window</li>
<li>See full diff in <a
href="https://github.com/rust-windowing/winit/compare/v0.30.12...v0.30.13">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=winit&package-manager=cargo&previous-version=0.30.12&new-version=0.30.13)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-03 01:49:45 +00:00
Taym Haddadi
cfc4920815 indexeddb: implement "inject a key into a value using a key path with value" (#42727)
implement "inject a key into a value using a key path with value"
following he spec:

https://w3c.github.io/IndexedDB/#inject-a-key-into-a-value-using-a-key-path
 

Testing: More indexeddb tests should pass.
part of https://github.com/servo/servo/issues/40983

---------

Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
2026-03-02 23:16:29 +00:00
Martin Robinson
1d9d440b22 script: Add basic support for tab navigation (#42952)
This change adds very basic support for tab navigation, but without
support for focus scopes. Followup changes will refine the behavior of
this implementation to follow the specification around focus scopes,
shadow DOM, and slots. In particular `delegatesFocus` is not supported
here yet.

Testing: This causes quite a few WPT tests to start passing.

Signed-off-by: Martin Robinson <mrobinson@igalia.com>
Co-authored-by: Oriol Brufau <obrufau@igalia.com>
2026-03-02 20:42:25 +00:00
Shubham Gupta
77e4bfbcc4 Pass Request's URL for LargestContentfulPaint Entry (#42901)
Pass Request URL to `LargestContnetfulPaint` Entry

Testing: WPT Expectations Updated.
Fixes: #42902

---------

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-02 20:35:37 +00:00
Simon Wülker
640fe6356a fonts: Don't apply letter-spacing to formatting characters (#42961)
This change checks whether a character belongs to the `Cf` category of
unicode characters before applying `letter-spacing`. The `fonts` crate
now depends on `icu_properties`, but that crate is already in our
dependency tree (with the same features enabled).

Testing: New tests start to pass
Fixes https://github.com/servo/servo/issues/38781

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-02 19:09:01 +00:00
eri
88f2469270 devtools: Implement initial support for Step in, Step out and Step over (#42907)
We are adding initial support for stepping in the debugger. Step over
mostly works, but Step in and Step out have some quirks that we are
working on.

![2026-02-27
12-32-05](https://github.com/user-attachments/assets/0b73b32c-efa3-444c-80a4-f863a64b6fdc)

Testing: DevTools tests and manual checks.
Part of: #36027

Signed-off-by: eri <eri@igalia.com>
Co-authored-by: atbrakhi <atbrakhi@igalia.com>
2026-03-02 18:35:02 +00:00
Narfinger
b55bc205a7 script: jscontext-ify element aria methods and SetCrossOrigin (#42957)
Use &mut JSContext in element aria* methods and SetCrossOrigin methods.

Testing: Compilation is the test as this is part from
https://github.com/servo/servo/issues/40600

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
2026-03-02 17:23:33 +00:00
Simon Wülker
a7f89a22ff tests: Add back .ini file for parser reentrancy test (#42959)
The file was removed in
bb5547a5d0
but we still need it. Note that we don't crash on the async variant
anymore since https://github.com/servo/servo/pull/42910.

Fixes https://github.com/servo/servo/issues/42933
Testing: The tests run as expected.

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-02 16:43:47 +00:00
Shubham Gupta
062bb35ac5 layout: Add image_url to ImageInfo struct (#42949)
This just adds URL to pass to ImageFragment for LargestContentfulPaint
Entry

Rebased on: #42948

Testing: No expected change in behavior, Successful Compilation is
enough to verify.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-02 16:34:17 +00:00
Domenico Rizzo
68284e4a38 script: Refactors GPUPipelineLayout to disallow direct Drop. (#42937)
Moves the `Drop` implementation for `GPUPipelineLayout` to a dedicated
private helper struct, `DroppableGPUPipelineLayout`. This ensures that
DOM types do not directly implement `Drop`, aligning with best practices
for resource management in the DOM. The associated `Bindings.conf` entry
is removed as direct `Drop` is no longer needed for this type.

Testing: WebGpu just coverages cases with  proper tests
Fixes: Partially #26488

Signed-off-by: Domenico Rizzo <domenico.rizzo@gmail.com>
2026-03-02 15:26:42 +00:00
Jonathan Schwender
30372328c0 Reword our security policy (#42953)
In ac24cd6139 we started asking for people
to use **private** github security reports, but kept the wording from
before, which was related to accepting such reports as **public**
issues.
The wording doesn't make sense in the context of asking people for
private reports, so update the wording to reflect that.
This is not a policy change, just making the wording more clear.

Testing: Not required, policy description.

Signed-off-by: Jonathan Schwender <schwenderjonathan@gmail.com>
2026-03-02 13:37:59 +00:00
Simon Wülker
e033588b30 script: Fix deadlock in async html parser (#42930)
When the async parser thread finds a `<meta charset>` tag then it asks
the main thread whether parsing should restart. The main thread wasn't
responding, so the parser got stuck.


Part of https://github.com/servo/servo/issues/37418
Testing: This change adds a test

---------

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
2026-03-02 12:15:41 +00:00
Shubham Gupta
71974ea830 layout: Wrap Image related data in ImageInfo struct in NodeExt impl (#42948)
Encapsulating Image related data in ImageInfo in NodeExt impl.

Testing: This is just a little refactor. No change in behavior expected.
Successful compilation is enough to verify.

Signed-off-by: Shubham Gupta <shubham.gupta@chromium.org>
2026-03-02 10:34:39 +00:00
webbeef
4487e0222a script: Mark disabled elements pointed at and elements targets of touch events as :active (#42935)
This implements the "If the element is [being actively pointed
at](https://html.spec.whatwg.org/multipage/semantics-other.html#being-actively-pointed-at)"
part of
https://html.spec.whatwg.org/multipage/semantics-other.html#selector-active

Also added support for activation of controls tied to a `<label
for=...>` element as this is part of the same
`/html/semantics/selectors/pseudo-classes/active-disabled.html` WPT
test. We still fail the `<input disabled>` one because the hit test ends
up in a `<div>` of the input shadow DOM.

Testing: New WPT tests are passing
Fixes: Partial fix for https://github.com/servo/servo/issues/7333 and
https://github.com/servo/servo/issues/20284 (I think we still lack
support for the focusable elements).

---------

Signed-off-by: webbeef <me@webbeef.org>
2026-03-02 09:17:52 +00:00
Euclid Ye
29d20d56cf ci: Add jackd2 to dependency of Media Examples (#42947)
Testing: Output log is reduced to 910 lines in
[try](https://github.com/servo/servo/actions/runs/22567021352/job/65365322261#step:8:910).
Previously, it is 1400 lines, and we get error in [when start dummy
audio
device](https://github.com/servo/servo/actions/runs/22502937019/job/65194401381#step:7:13).
Fixes: Part of #42934?

Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
2026-03-02 09:15:40 +00:00
dependabot[bot]
a60a8b1b4d build: bump dlib from 0.5.2 to 0.5.3 (#42940)
Bumps [dlib](https://github.com/elinorbgr/dlib) from 0.5.2 to 0.5.3.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/elinorbgr/dlib/commits">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=dlib&package-manager=cargo&previous-version=0.5.2&new-version=0.5.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 04:31:29 +00:00
dependabot[bot]
a1e03eeb6b build: bump the gstreamer-related group with 3 updates (#42938)
Bumps the gstreamer-related group with 3 updates:
[glib](https://github.com/gtk-rs/gtk-rs-core), gstreamer and
[glib-macros](https://github.com/gtk-rs/gtk-rs-core).

Updates `glib` from 0.22.0 to 0.22.2
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gtk-rs/gtk-rs-core/releases">glib's
releases</a>.</em></p>
<blockquote>
<h2>0.22.2</h2>
<pre><code>Julian Sparber:
      glib: Implement From&lt;PtrSlice&lt;GStringPtr&gt; for StrV
      glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;
<p>Sebastian Dröge:<br />
gio: Mark <code>Socket::from_raw_socket()</code> as unsafe</p>
<p>Wladimir Palant:<br />
glib-macros: Silence “redundant closure” clippy warning in
closure!/closure_local!<br />
</code></pre></p>
<h2>0.22.1</h2>
<pre><code>Sebastian Dröge:
gio: Re-add accidentally removed UNIX APIs that are still part of gio
itself
      gio: Remove non-existing UNIX functions from Gir.toml
</code></pre>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="484fbe01e7"><code>484fbe0</code></a>
Update Cargo.lock</li>
<li><a
href="77ce5c64ea"><code>77ce5c6</code></a>
Update versions to 0.22.2</li>
<li><a
href="a5a6b9f659"><code>a5a6b9f</code></a>
glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;</li>
<li><a
href="1870acb44c"><code>1870acb</code></a>
glib: Implement From&lt;PtrSlice<!-- raw HTML omitted --> for StrV</li>
<li><a
href="dd77db24ee"><code>dd77db2</code></a>
Fixes <a
href="https://redirect.github.com/gtk-rs/gtk-rs-core/issues/1912">#1912</a>
- Silence “redundant closure” clippy warning in
closure!/closure_...</li>
<li><a
href="a764a0fe5b"><code>a764a0f</code></a>
gio: Mark <code>Socket::from_raw_socket()</code> as unsafe</li>
<li><a
href="aa0dee233f"><code>aa0dee2</code></a>
Update versions to 0.22.1</li>
<li><a
href="a65fe5c356"><code>a65fe5c</code></a>
gio: Remove non-existing UNIX functions from Gir.toml</li>
<li><a
href="aa8a69805a"><code>aa8a698</code></a>
gio: Re-add accidentally removed UNIX APIs that are still part of gio
itself</li>
<li>See full diff in <a
href="https://github.com/gtk-rs/gtk-rs-core/compare/0.22.0...0.22.2">compare
view</a></li>
</ul>
</details>
<br />

Updates `gstreamer` from 0.25.0 to 0.25.1

Updates `glib-macros` from 0.22.0 to 0.22.2
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/gtk-rs/gtk-rs-core/releases">glib-macros's
releases</a>.</em></p>
<blockquote>
<h2>0.22.2</h2>
<pre><code>Julian Sparber:
      glib: Implement From&lt;PtrSlice&lt;GStringPtr&gt; for StrV
      glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;
<p>Sebastian Dröge:<br />
gio: Mark <code>Socket::from_raw_socket()</code> as unsafe</p>
<p>Wladimir Palant:<br />
glib-macros: Silence “redundant closure” clippy warning in
closure!/closure_local!<br />
</code></pre></p>
<h2>0.22.1</h2>
<pre><code>Sebastian Dröge:
gio: Re-add accidentally removed UNIX APIs that are still part of gio
itself
      gio: Remove non-existing UNIX functions from Gir.toml
</code></pre>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="484fbe01e7"><code>484fbe0</code></a>
Update Cargo.lock</li>
<li><a
href="77ce5c64ea"><code>77ce5c6</code></a>
Update versions to 0.22.2</li>
<li><a
href="a5a6b9f659"><code>a5a6b9f</code></a>
glib: Implement From&lt;StrV&gt; for PtrSlice&lt;GStringPtr&gt;</li>
<li><a
href="1870acb44c"><code>1870acb</code></a>
glib: Implement From&lt;PtrSlice<!-- raw HTML omitted --> for StrV</li>
<li><a
href="dd77db24ee"><code>dd77db2</code></a>
Fixes <a
href="https://redirect.github.com/gtk-rs/gtk-rs-core/issues/1912">#1912</a>
- Silence “redundant closure” clippy warning in
closure!/closure_...</li>
<li><a
href="a764a0fe5b"><code>a764a0f</code></a>
gio: Mark <code>Socket::from_raw_socket()</code> as unsafe</li>
<li><a
href="aa0dee233f"><code>aa0dee2</code></a>
Update versions to 0.22.1</li>
<li><a
href="a65fe5c356"><code>a65fe5c</code></a>
gio: Remove non-existing UNIX functions from Gir.toml</li>
<li><a
href="aa8a69805a"><code>aa8a698</code></a>
gio: Re-add accidentally removed UNIX APIs that are still part of gio
itself</li>
<li>See full diff in <a
href="https://github.com/gtk-rs/gtk-rs-core/compare/0.22.0...0.22.2">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 04:13:03 +00:00
dependabot[bot]
c285394886 build: bump piper from 0.2.4 to 0.2.5 (#42943)
Bumps [piper](https://github.com/smol-rs/piper) from 0.2.4 to 0.2.5.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/piper/releases">piper's
releases</a>.</em></p>
<blockquote>
<h2>v0.2.5</h2>
<ul>
<li>Add functions to allow for buffered reading and writing. (<a
href="https://redirect.github.com/smol-rs/piper/issues/27">#27</a>)</li>
<li>Fix a bug where closing the <code>Writer</code> after writing can
cause the <code>Reader</code> to
lose bytes. (<a
href="https://redirect.github.com/smol-rs/piper/issues/31">#31</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/smol-rs/piper/blob/main/CHANGELOG.md">piper's
changelog</a>.</em></p>
<blockquote>
<h1>Version 0.2.5</h1>
<ul>
<li>Add functions to allow for buffered reading and writing. (<a
href="https://redirect.github.com/smol-rs/piper/issues/27">#27</a>)</li>
<li>Fix a bug where closing the <code>Writer</code> after writing can
cause the <code>Reader</code> to
lose bytes. (<a
href="https://redirect.github.com/smol-rs/piper/issues/31">#31</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="85da45edce"><code>85da45e</code></a>
v0.2.5</li>
<li><a
href="6dd31ba3b5"><code>6dd31ba</code></a>
Add a test to verify that closing the write side doesn't break the
reader side.</li>
<li><a
href="f07220867f"><code>f072208</code></a>
Switch ordering of <code>closed</code> load to use <code>Acquire</code>
instead of <code>Relaxed</code>.</li>
<li><a
href="a7614f259a"><code>a7614f2</code></a>
Fix ordering of available data check.</li>
<li><a
href="aa05148ed9"><code>aa05148</code></a>
Update criterion requirement from 0.7 to 0.8 (<a
href="https://redirect.github.com/smol-rs/piper/issues/29">#29</a>)</li>
<li><a
href="3d62a59c24"><code>3d62a59</code></a>
feat: Implement AsyncBufRead and related methods on Reader and Writer
for dir...</li>
<li><a
href="6581c84a7b"><code>6581c84</code></a>
Update criterion requirement from 0.6 to 0.7 (<a
href="https://redirect.github.com/smol-rs/piper/issues/28">#28</a>)</li>
<li><a
href="e198ca3e47"><code>e198ca3</code></a>
Update criterion requirement from 0.4 to 0.6 (<a
href="https://redirect.github.com/smol-rs/piper/issues/25">#25</a>)</li>
<li><a
href="db2dcb8366"><code>db2dcb8</code></a>
Fix crates.io description for v0.2 reduced scope (<a
href="https://redirect.github.com/smol-rs/piper/issues/26">#26</a>)</li>
<li><a
href="30dd8ecd9c"><code>30dd8ec</code></a>
Fix typo (<a
href="https://redirect.github.com/smol-rs/piper/issues/21">#21</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/smol-rs/piper/compare/v0.2.4...v0.2.5">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=piper&package-manager=cargo&previous-version=0.2.4&new-version=0.2.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 01:11:24 +00:00
dependabot[bot]
9e9dc72e58 build: bump libredox from 0.1.12 to 0.1.14 (#42942)
Bumps libredox from 0.1.12 to 0.1.14.


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=libredox&package-manager=cargo&previous-version=0.1.12&new-version=0.1.14)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 01:10:12 +00:00
dependabot[bot]
ddadbaa9a0 build: bump pin-project-lite from 0.2.16 to 0.2.17 (#42941)
Bumps [pin-project-lite](https://github.com/taiki-e/pin-project-lite)
from 0.2.16 to 0.2.17.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/pin-project-lite/releases">pin-project-lite's
releases</a>.</em></p>
<blockquote>
<h2>0.2.17</h2>
<ul>
<li>Enable <a
href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/immutable-releases">release
immutability</a>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/taiki-e/pin-project-lite/blob/main/CHANGELOG.md">pin-project-lite's
changelog</a>.</em></p>
<blockquote>
<h2>[0.2.17] - 2026-02-27</h2>
<ul>
<li>Enable <a
href="https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/immutable-releases">release
immutability</a>.</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="3bdf763446"><code>3bdf763</code></a>
Release 0.2.17</li>
<li><a
href="17437026e9"><code>1743702</code></a>
Update changelog</li>
<li><a
href="be3eb1a180"><code>be3eb1a</code></a>
Add comment about rust-version field to Cargo.toml</li>
<li><a
href="2b5f66d9bc"><code>2b5f66d</code></a>
Update allowed lint list</li>
<li><a
href="c7495a0d46"><code>c7495a0</code></a>
tools: Update tidy.sh</li>
<li><a
href="aa30a9fba2"><code>aa30a9f</code></a>
Apply clippy to doctest</li>
<li><a
href="0944bb974c"><code>0944bb9</code></a>
Update .deny.toml</li>
<li><a
href="401bd71ac2"><code>401bd71</code></a>
rustfmt: Set hex_literal_case = &quot;Upper&quot;</li>
<li><a
href="28c4feccd5"><code>28c4fec</code></a>
test: Update lint test</li>
<li><a
href="67a04498e4"><code>67a0449</code></a>
tests: Update ui test output to nightly-2025-12-04</li>
<li>Additional commits viewable in <a
href="https://github.com/taiki-e/pin-project-lite/compare/v0.2.16...v0.2.17">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pin-project-lite&package-manager=cargo&previous-version=0.2.16&new-version=0.2.17)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-03-02 01:09:46 +00:00
65380 changed files with 3581908 additions and 200037 deletions

2
.clippy.toml Normal file
View File

@@ -0,0 +1,2 @@
# Lint for https://github.com/advisories/GHSA-r6v5-fh4h-64xc until we upgrade to time >=0.3.47
disallowed-types = ["time::format_description::well_known::Rfc2822"]

View File

@@ -1,6 +1,7 @@
[profile.default]
# Print a slow warning after period, terminate unit-test after 4x period.
slow-timeout = { period = "5s", terminate-after = 4 }
status-level = "leak"
[profile.ci]
fail-fast = false

View File

@@ -1,48 +0,0 @@
# Dockerfile for the servo devcontainer environment.
# Note that the build-context is the repository root.
# We use a multi-stage build to keep the final image size down.
# We use a prebuilt image for `uv` to speed up builds and later copy the artifacts
# into the final stage.
FROM ghcr.io/astral-sh/uv:latest AS uv
FROM ubuntu:24.04 AS base
# Install apt dependencies.
COPY python/servo/platform/linux_packages /tmp/linux_packages
RUN apt-get update \
&& /tmp/linux_packages/generate_pkg_list.sh /tmp/linux_packages/apt/* | xargs apt-get install -y --no-install-recommends \
&& curl --version
# Please keep `RUST_VERSION` in sync with the `rust-toolchain.toml` file.
ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
PATH=/usr/local/cargo/bin:$PATH \
UV_TOOL_BIN_DIR=/usr/local/bin \
RUST_VERSION=1.92.0
# Keep the list of components in sync with `rust-toolchain.toml` file.
RUN curl https://sh.rustup.rs -sSf \
| sh -s -- --default-toolchain ${RUST_VERSION} -y --component clippy,llvm-tools,llvm-tools-preview,rustc-dev,rustfmt,rust-src \
&& \
rustup --version; \
cargo --version; \
rustc --version;
# prebuilt rust tools we use
FROM base AS rust_builder
# TODO: We would need to use `ARG` and install specific versions, to ensure
# that the tools are updated and not always cached.
RUN cargo install cargo-deny cargo-nextest taplo-cli cargo-about --locked
FROM base AS final
COPY --from=rust_builder \
/usr/local/cargo/bin/cargo-deny \
/usr/local/cargo/bin/cargo-nextest \
/usr/local/cargo/bin/taplo \
/usr/local/cargo/bin/cargo-about \
/usr/local/cargo/bin/
COPY --from=uv /uv /uvx /bin/

View File

@@ -0,0 +1,51 @@
# Dockerfile for the servo devcontainer environment.
# Note that the build-context is the repository root.
# We use a multi-stage build to keep the final image size down.
# We use a prebuilt image for `uv` to speed up builds and later copy the artifacts
# into the final stage.
FROM ghcr.io/astral-sh/uv:latest AS uv
FROM ubuntu:24.04 AS base
# Install apt dependencies.
COPY python/servo/platform/linux_packages /tmp/linux_packages
RUN apt-get update \
&& /tmp/linux_packages/generate_pkg_list.sh /tmp/linux_packages/apt/* | xargs apt-get install -y --no-install-recommends \
&& curl --version
# Required due to https://github.com/servo/servo/issues/35029
RUN apt purge -y fonts-droid-fallback
# Please keep `RUST_VERSION` in sync with the `rust-toolchain.toml` file.
ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
PATH=/usr/local/cargo/bin:$PATH \
UV_TOOL_BIN_DIR=/usr/local/bin \
RUST_VERSION=1.92.0
# Keep the list of components in sync with `rust-toolchain.toml` file.
RUN curl https://sh.rustup.rs -sSf \
| sh -s -- --default-toolchain ${RUST_VERSION} -y --component clippy,llvm-tools,llvm-tools-preview,rustc-dev,rustfmt,rust-src \
&& \
rustup --version; \
cargo --version; \
rustc --version;
# prebuilt rust tools we use
FROM base AS rust_builder
# TODO: We would need to use `ARG` and install specific versions, to ensure
# that the tools are updated and not always cached.
RUN cargo install cargo-deny cargo-nextest taplo-cli cargo-about --locked
FROM base AS final
COPY --from=rust_builder \
/usr/local/cargo/bin/cargo-deny \
/usr/local/cargo/bin/cargo-nextest \
/usr/local/cargo/bin/taplo \
/usr/local/cargo/bin/cargo-about \
/usr/local/cargo/bin/
COPY --from=uv /uv /uvx /bin/

View File

@@ -0,0 +1,3 @@
*
!/.devcontainer
!/python/servo/platform/linux_packages

View File

@@ -2,10 +2,12 @@
// README at: https://github.com/devcontainers/templates/tree/main/src/ubuntu
{
"name": "Ubuntu",
"build": {
"dockerfile": "Dockerfile",
"context": ".."
},
"image": "ghcr.io/servo/servo/devcontainer-ubuntu:latest",
// Alternatively, uncomment the "build" property below to build the image from the Dockerfile in this folder.
// "build": {
// "dockerfile": "Ubuntu.Dockerfile",
// "context": ".."
// },
// Most dependencies are installed in the image, but we run mach bootstrap to ensure
@@ -14,9 +16,17 @@
"postCreateCommand":
"./mach bootstrap --yes",
"mounts": [
"source=servo-cargo-target,target=/var/servo-cargo-target,type=volume"
],
"containerEnv": {
"CC": "clang",
"CXX": "clang++",
// at least on macOS the workspace directory can be mounted as case-insensitve,
// which causes build errors in mozjs. Using a volume avoids this issue, and can
// also improve performance.
"CARGO_TARGET_DIR": "/var/servo-cargo-target",
"UV_PROJECT_ENVIRONMENT": ".devcontainer-venv"
}
}

4
.github/CODEOWNERS vendored
View File

@@ -39,6 +39,10 @@
# Reviewers for XPath related code
/components/xpath @simonwuelker
# Reviewers for DevTools
/components/devtools @atbrakhi @eerii
/components/shared/devtools @atbrakhi @eerii
# Reviewers for CI related code
/.github/workflows @sagudev
/.github/actions @sagudev

25
.github/ISSUE_TEMPLATE/roadmap.md vendored Normal file
View File

@@ -0,0 +1,25 @@
---
name: Roadmap Issue
about: Create an issue to track in the Servo roadmap
title: ''
labels: B-roadmap
assignees: ''
---
## Roadmap Issue
**Description:**
A clear and concise description of the work that will be done.
**Area:** e.g. Layout, Script, Performance, ...
**People:** Who are planning to work on this task.
Leave it blank if it's just something interesting for the project,
but nobody is planning to work on at the moment.
---
Feel free to add any other comments on the issue after this line.

View File

@@ -12,10 +12,10 @@ runs:
id: parse_version
shell: bash
run: |
msrv=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[] | select(.name == "libservo") | .rust_version')
msrv=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[] | select(.name == "servo") | .rust_version')
if [[ "${msrv}" == "null" ]]; then
echo "Failed to determine MSRV of libservo"
echo "Failed to determine MSRV of servo"
exit 1
fi
echo "libservo has a minimum supported Rust version of ${msrv}."
echo "servo has a minimum supported Rust version of ${msrv}."
echo "LIBSERVO_RUST_VERSION=${msrv}" >> "$GITHUB_OUTPUT"

View File

@@ -15,7 +15,7 @@ runs:
# symlink to this version.
- name: Setup system python
if: ${{ inputs.skip-python-setup != 'true' }}
uses: actions/setup-python@v5
uses: actions/setup-python@v6
with:
python-version-file: ${{ inputs.python-version-file-path }}
- name: Install uv

View File

@@ -52,6 +52,11 @@ updates:
objc2-related:
patterns:
- "objc2*"
rustls-webpki-related:
patterns:
- rustls-webpki
- webpki-roots
- webpki-root-certs
sea-query-related:
patterns:
- "sea-query"

View File

@@ -70,7 +70,7 @@ jobs:
timeout-minutes: 30
run: sudo apt update && ./mach bootstrap --yes --skip-lints --skip-nextest
- name: Set up JDK 17
uses: actions/setup-java@v4
uses: actions/setup-java@v5
with:
java-version: '17'
distribution: 'temurin'
@@ -107,29 +107,32 @@ jobs:
APK_SIGNING_KEY_PASS: ${{ secrets.APK_SIGNING_KEY_PASS }}
run: |
./mach build --use-crown --locked --target ${{ matrix.target }} --profile ${{ inputs.profile }}
cp -r target/cargo-timings target/cargo-timings-android-${{ matrix.target }}
mv target/cargo-timings target/cargo-timings-android-${{ matrix.target }}
# TODO: This is disabled since APK crashes during startup.
# See https://github.com/servo/servo/issues/31134
# - name: Script tests
# run: ./mach test-android-startup
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-android-${{ matrix.target }}-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: target/cargo-timings-*
if-no-files-found: error
- name: Upload APK artifact
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-apk
with:
name: ${{ inputs.profile }}-binary-android-${{ matrix.target }}
path: target/android/${{ matrix.target }}/${{ inputs.profile }}/servoapp.apk
if-no-files-found: error
- name: Upload AAR artifact
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-aar
with:
name: ${{ inputs.profile }}-library-android-${{ matrix.target }}
path: target/android/${{ matrix.target }}/${{ inputs.profile }}/servoview.aar
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
if: matrix.target == 'aarch64-linux-android'
id: artifact_ids

View File

@@ -58,7 +58,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
github-hosted-runner-label: ubuntu-22.04
@@ -77,8 +77,8 @@ jobs:
name: Bencher (${{ inputs.target }}) [${{ needs.runner-select.outputs.unique-id }}]
runs-on: ${{ needs.runner-select.outputs.selected-runner-label }}
steps:
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: actions/download-artifact@v4
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
- uses: actions/download-artifact@v8
with:
name: ${{ inputs.profile }}-binary-${{ inputs.target }}
path: ${{ inputs.profile }}-binary-${{ inputs.target }}

70
.github/workflows/book-export.yml vendored Normal file
View File

@@ -0,0 +1,70 @@
name: Book Export
on:
push:
branches:
- main
jobs:
upstream:
# Run job only on servo/servo
if: github.repository == 'servo/servo'
runs-on: ubuntu-latest
environment:
name: book-sync
deployment: false
steps:
- name: Check out Servo
uses: actions/checkout@v6
with:
sparse-checkout: |
python/servo/platform/linux_packages
fetch-depth: '2'
- name: Check out Servo book
uses: actions/checkout@v6
with:
path: book
repository: 'servo/book'
token: ${{ secrets.BOOK_SYNC_TOKEN }}
- name: Check for changes
working-directory: python/servo/platform/linux_packages
id: changes
run: |
# Note: This check assumes the action only runs on `main`.
if git diff --quiet HEAD HEAD^ -- . ; then
echo "No changes detected, exiting."
echo "CHANGES=false" >> $GITHUB_OUTPUT
else
echo "Changes detected, exporting book."
./generate_pkg_list.sh apt/apt_common.txt > ${{github.workspace}}/book/src/building/linux_packages/apt_common.txt
./generate_pkg_list.sh apt/apt_ubuntu_only.txt > ${{github.workspace}}/book/src/building/linux_packages/apt_ubuntu_only.txt
./generate_pkg_list.sh dnf/dnf_base.txt > ${{github.workspace}}/book/src/building/linux_packages/dnf_base.txt
./generate_pkg_list.sh xbps/xbps_base.txt > ${{github.workspace}}/book/src/building/linux_packages/xbps_base.txt
echo "CHANGES=true" >> $GITHUB_OUTPUT
fi
- name: Commit changes
working-directory: book
if: ${{ steps.changes.outputs.CHANGES == 'true'}}
run: |
git config --local user.email "ghbot+book-sync@servo.org"
git config --local user.name "Book Sync Bot"
git add src/building/linux_packages/
git commit -m "linux: Update dependency list based on servo/servo@${GITHUB_SHA::13}"
- name: Push changes
if: ${{ steps.changes.outputs.CHANGES == 'true'}}
working-directory: book
run: git push 'https://${{ secrets.BOOK_SYNC_TOKEN }}@github.com/servo-bot/book.git' 'HEAD:linux_pkgs_sync_${{ github.sha }}'
- name: Open PR
if: ${{ steps.changes.outputs.CHANGES == 'true'}}
env:
GH_TOKEN: ${{ secrets.BOOK_SYNC_CREATE_PR_TOKEN }}
UPDATE_BRANCH: linux_pkgs_sync_${{ github.sha }}
working-directory: book
run: |
BODY=$(cat <<EOF
Update dependency list based on servo/servo@${GITHUB_SHA}
EOF
)
gh pr create \
--title "Sync Linux packages with servo (${GITHUB_SHA::7})" \
--repo servo/book \
--body "$BODY" --head servo-bot:${{ env.UPDATE_BRANCH }}

128
.github/workflows/docker.yml vendored Normal file
View File

@@ -0,0 +1,128 @@
name: Build Docker image and push to GitHub Packages
# This workflow file is adapted from the example at https://docs.github.com/en/packages/managing-github-packages-using-github-actions-workflows/publishing-and-installing-a-package-with-github-actions#upgrading-a-workflow-that-accesses-a-registry-using-a-personal-access-token
on:
push:
branches:
- main
# Only rebuild if the Dockerfile or dependencies change.
paths: &container-paths
- '.devcontainer/**'
- 'python/servo/platform/linux_packages/**'
- '.github/workflows/docker.yml'
workflow_dispatch:
pull_request:
branches:
- main
paths: *container-paths
env:
IMAGE_NAME: devcontainer-ubuntu
IMAGE_DOWNLOAD_PATH: docker-image-artifacts
# AMD64 and ARM64 label names are what docker chose
AMD64_IMAGE_ARCHIVE: devcontainer-ubuntu-amd64.tar
ARM64_IMAGE_ARCHIVE: devcontainer-ubuntu-arm64.tar
AMD64_IMAGE_ARTIFACT_NAME: devcontainer-ubuntu-image-amd64
ARM64_IMAGE_ARTIFACT_NAME: devcontainer-ubuntu-image-arm64
jobs:
devcontainer_ubuntu_build:
runs-on: ${{ matrix.runner }}
strategy:
fail-fast: false
matrix:
include:
- arch: amd64
platform: linux/amd64
runner: ubuntu-24.04
image_archive: devcontainer-ubuntu-amd64.tar
image_artifact_name: devcontainer-ubuntu-image-amd64
- arch: arm64
platform: linux/arm64
runner: ubuntu-24.04-arm
image_archive: devcontainer-ubuntu-arm64.tar
image_artifact_name: devcontainer-ubuntu-image-arm64
permissions:
contents: read
steps:
- uses: actions/checkout@v6
- name: Build ${{ matrix.arch }} image
run: |
docker build . \
--file .devcontainer/Ubuntu.Dockerfile \
--platform ${{ matrix.platform }} \
--tag ${{ env.IMAGE_NAME }}:${{ matrix.arch }} \
--label "runnumber=${GITHUB_RUN_ID}"
- name: Save ${{ matrix.arch }} image
if: github.event_name != 'pull_request'
run: docker save --output "${{ matrix.image_archive }}" "${{ env.IMAGE_NAME }}:${{ matrix.arch }}"
- name: Upload ${{ matrix.arch }} image artifact
if: github.event_name != 'pull_request'
uses: actions/upload-artifact@v7
with:
name: ${{ matrix.image_artifact_name }}
path: ${{ matrix.image_archive }}
archive: false
if-no-files-found: error
devcontainer_ubuntu_publish:
runs-on: ubuntu-24.04
needs:
- devcontainer_ubuntu_build
# Use manual workflow dispatch in your fork to test changes.
if: (github.event_name == 'push' && github.repository_owner == 'servo') || github.event_name == 'workflow_dispatch'
permissions:
contents: read
packages: write
steps:
- uses: actions/download-artifact@v8
with:
path: ${{ env.IMAGE_DOWNLOAD_PATH }}
merge-multiple: true
- name: List downloaded image artifacts
run: ls -R "${{ env.IMAGE_DOWNLOAD_PATH }}"
- name: Derive image metadata
id: image_meta
run: |
IMAGE_ID=ghcr.io/${{ github.repository_owner }}/servo/${{ env.IMAGE_NAME }}
# This changes all uppercase characters to lowercase.
IMAGE_ID=$(echo "$IMAGE_ID" | tr '[A-Z]' '[a-z]')
# This strips the git ref prefix from the version.
VERSION=$(echo "${{ github.ref }}" | sed -e 's,.*/\(.*\),\1,')
# This uses the Docker `latest` tag convention.
[ "$VERSION" = "main" ] && VERSION=latest
echo "IMAGE_ID=$IMAGE_ID"
echo "VERSION=$VERSION"
echo "image_id=$IMAGE_ID" >> "$GITHUB_OUTPUT"
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
echo "multiarch_tag=$IMAGE_ID:$VERSION" >> "$GITHUB_OUTPUT"
- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
- name: Push platform images and publish manifest list
run: |
for archive in "${{ env.AMD64_IMAGE_ARCHIVE }}" "${{ env.ARM64_IMAGE_ARCHIVE }}"; do
docker load --input "${{ env.IMAGE_DOWNLOAD_PATH }}/$archive"
done
IMAGE_TAGS=()
for arch in amd64 arm64; do
IMAGE=${{ steps.image_meta.outputs.image_id }}:$arch-${{ steps.image_meta.outputs.version }}
IMAGE_TAGS+=("$IMAGE")
docker tag ${{ env.IMAGE_NAME }}:$arch "$IMAGE"
docker push "$IMAGE"
done
# This pushes to the registry
docker buildx imagetools create --tag ${{ steps.image_meta.outputs.multiarch_tag }} "${IMAGE_TAGS[@]}"

View File

@@ -21,7 +21,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
# Before updating the GH action runner image for the nightly job, ensure
@@ -42,7 +42,7 @@ jobs:
name: Lint [${{ needs.runner-select.outputs.unique-id }}]
runs-on: ${{ needs.runner-select.outputs.selected-runner-label }}
steps:
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
fetch-depth: 2

View File

@@ -46,7 +46,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
# Before updating the GH action runner image for the nightly job, ensure
@@ -80,7 +80,7 @@ jobs:
if: github.event_name == 'pull_request_target'
with:
ref: refs/pull/${{ github.event.number }}/head
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
with:
name: ${{ inputs.profile }}-binary-linux
path: ${{ inputs.profile }}-binary-linux
@@ -101,9 +101,6 @@ jobs:
sudo apt install -qy --no-install-recommends mesa-vulkan-drivers fonts-noto-cjk fonts-dejavu-extra
# FIXME #35029
sudo apt purge -y fonts-droid-fallback
sudo apt install -y jackd2 libjack-jackd2-0
- name: Start Dummy Audio Device
run: jackd -d dummy &
- name: Sync from upstream WPT
if: ${{ inputs.wpt-sync-from-upstream }}
run: |
@@ -126,17 +123,19 @@ jobs:
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
- name: Archive results (filtered)
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-filtered-logs-linux-${{ matrix.chunk_id }}
path: wpt-filtered-logs/*/
if-no-files-found: error
- name: Archive results (full)
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-full-logs-linux-${{ matrix.chunk_id }}
path: wpt-full-logs/*/
if-no-files-found: error
report-test-results:
name: Process WPT Results
@@ -145,14 +144,14 @@ jobs:
needs: linux-wpt
steps:
- name: Merge logs (full)
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: wpt-full-logs-linux
pattern: wpt-full-logs-linux-*
delete-merged: true
# This job needs to be last. If no filtered results were uploaded, it will fail, but we want to merge other archives in that case.
- name: Merge logs (filtered)
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: wpt-filtered-logs-linux
pattern: wpt-filtered-logs-linux-*
@@ -165,7 +164,7 @@ jobs:
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream && github.event_name == 'pull_request_target' }}
with:
ref: refs/pull/${{ github.event.number }}/head
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
with:
name: wpt-filtered-logs-linux
@@ -177,10 +176,11 @@ jobs:
cat results/linux/*.log > stable-unexpected-results.log || true
- name: Upload aggregated results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: stable-unexpected-results-linux
path: stable-unexpected-results.log
if-no-files-found: error
- name: Report results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
run: |

View File

@@ -105,7 +105,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
# Before updating the GH action runner image for the nightly job, ensure
@@ -128,7 +128,7 @@ jobs:
outputs:
artifact_ids: ${{ steps.artifact_ids.outputs.artifact_ids }}
steps:
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
if: ${{ runner.environment != 'self-hosted' }}
@@ -145,7 +145,9 @@ jobs:
- name: Change Mirror Priorities
if: ${{ runner.environment != 'self-hosted' }}
uses: ./.github/actions/apt-mirrors
- uses: taiki-e/install-action@v2
- name: Install cargo nextest
if: ${{ inputs.unit-tests }}
uses: taiki-e/install-action@v2
with:
tool: nextest
- name: Bootstrap dependencies
@@ -155,7 +157,7 @@ jobs:
sudo apt update
echo "wireshark-common wireshark-common/install-setuid boolean true" | sudo debconf-set-selections
sudo apt install -qy tshark
./mach bootstrap --yes --skip-lints
./mach bootstrap --yes --skip-lints --skip-nextest
# Always install crown, even on self-hosted runners, because it is tightly
# coupled to the rustc version, and we may have the wrong version if the
@@ -166,7 +168,7 @@ jobs:
- name: Build (${{ inputs.profile }})
run: |
./mach build --use-crown --locked --profile ${{ inputs.profile }} ${{ inputs.build-args }}
cp -r target/cargo-timings target/cargo-timings-linux
mv target/cargo-timings target/cargo-timings-linux
- name: Smoketest
run: xvfb-run ./mach smoketest --profile ${{ inputs.profile }}
- name: Script tests
@@ -195,19 +197,21 @@ jobs:
if: ${{ false && inputs.unit-tests }} # FIXME #39273
run: ./mach test-devtools --profile ${{ inputs.profile }}
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-linux-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: target/cargo-timings-*
if-no-files-found: error
- name: Build mach package
run: ./mach package --profile ${{ inputs.profile }}
- name: Upload artifact for mach package
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-tarball
with:
name: ${{ inputs.profile }}-binary-linux
path: target/${{ inputs.profile }}/servo-tech-demo.tar.gz
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
id: artifact_ids
shell: bash
@@ -224,7 +228,7 @@ jobs:
profile: ${{ inputs.profile }}
wpt-sync-from-upstream: ${{ inputs.wpt-sync-from-upstream }}
number-of-wpt-chunks: ${{ inputs. number-of-wpt-chunks }}
binary-path: servo/servo
binary-path: servo/servoshell
secrets: inherit
bencher:
@@ -235,7 +239,7 @@ jobs:
target: "linux"
profile: ${{ inputs.profile }}
compressed-file-path: ${{ inputs.profile }}-binary-linux/servo-tech-demo.tar.gz
binary-path: servo/servo
binary-path: servo/servoshell
file-size: true
# We only evaluate speedometer and dromaeo score in release
speedometer: ${{ inputs.profile == 'release' }}
@@ -276,9 +280,18 @@ jobs:
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ steps.msrv.outputs.rust_version }}
# We can remove this after upgrading to Rust 1.90, but for now
# installing lld is the easiest way to get it in path.
- name: install lld
run: sudo apt-get install -y lld
- name: Compile libservo with MSRV
env:
# lld seems to use less memory and prevents OOM errors during linking.
# We can remove this after upgrading to Rust 1.90, where lld will be the default.
RUSTFLAGS: "-C link-arg=-fuse-ld=lld"
LLVM_OBJDUMP: llvm-objdump-14
run: |
cargo +${{ steps.msrv.outputs.rust_version }} build -p libservo --locked --all-targets
cargo +${{ steps.msrv.outputs.rust_version }} build -p servo --locked
# Runs the underlying job (“workload”) on a self-hosted runner if available.
runner-select-coverage:
@@ -291,7 +304,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
# Before updating the GH action runner image for the nightly job, ensure
@@ -313,7 +326,7 @@ jobs:
runs-on: ${{ needs.runner-select-coverage.outputs.selected-runner-label }}
continue-on-error: true
steps:
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
if: ${{ runner.environment != 'self-hosted' }}
@@ -380,6 +393,13 @@ jobs:
if: github.event_name != 'pull_request_target'
with:
fetch-depth: 1
# This is necessary to checkout the pull request if this run was triggered via a
# `pull_request_target` event.
- uses: actions/checkout@v5
if: github.event_name == 'pull_request_target'
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 1
- name: Change Mirror Priorities
uses: ./.github/actions/apt-mirrors
- name: Install Dependencies
@@ -393,6 +413,7 @@ jobs:
gstreamer1.0-plugins-good \
gstreamer1.0-plugins-ugly \
gstreamer1.0-tools \
jackd2 \
libasound2-plugins \
libfaad2 \
libffi7 \

View File

@@ -72,6 +72,11 @@ on:
env:
RUST_BACKTRACE: 1
SHELL: /bin/bash
# Increment this to purge the cache (https://github.com/mozilla/sccache/blob/main/docs/GHA.md)
SCCACHE_GHA_VERSION: 1
SCCACHE_GHA_ENABLED: "true"
RUSTC_WRAPPER: "sccache"
CCACHE: "sccache"
CARGO_INCREMENTAL: 0
jobs:
@@ -104,13 +109,17 @@ jobs:
- if: ${{ runner.environment == 'self-hosted' }}
# Same as `git switch --detach FETCH_HEAD`, but fixes up dirty working
# trees, in case the runner image was baked with a dirty working tree.
# Safeguard: -- means FETCH_HEAD is revision instead of path.
# See <https://github.com/servo/servo/pull/44309>
run: |
git switch --detach
git reset --hard FETCH_HEAD
git reset --hard FETCH_HEAD --
- if: runner.environment != 'self-hosted'
name: Setup Python
uses: ./.github/actions/setup-python
- name: Run sccache-cache
uses: mozilla-actions/sccache-action@v0.0.9
# Always install crown, even on self-hosted runners, because it is tightly
# coupled to the rustc version, and we may have the wrong version if the
@@ -118,19 +127,21 @@ jobs:
- name: Install crown
run: cargo install --path support/crown
- uses: taiki-e/install-action@v2
- name: Install cargo nextest
if: ${{ inputs.unit-tests }}
uses: taiki-e/install-action@v2
with:
tool: nextest
- if: runner.environment != 'self-hosted'
name: Bootstrap
run: |
./mach bootstrap --yes --skip-lints
./mach bootstrap --yes --skip-lints --skip-nextest
brew install gnu-tar
- name: Build (${{ inputs.profile }})
run: |
./mach build --use-crown --locked --profile ${{ inputs.profile }} ${{ inputs.build-args }}
cp -r target/cargo-timings target/cargo-timings-macos-arm64
mv target/cargo-timings target/cargo-timings-macos-arm64
- name: Smoketest
uses: nick-fields/retry@v3
with: # See https://github.com/servo/servo/issues/30757
@@ -170,29 +181,32 @@ jobs:
max_attempts: 2
command: ./etc/ci/macos_package_smoketest.sh target/${{ inputs.profile }}/servo-tech-demo.dmg
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-macos-arm64-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: target/cargo-timings-*
if-no-files-found: error
- name: Upload artifact for mach package
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-dmg
with:
name: ${{ inputs.profile }}-binary-mac-arm64
path: target/${{ inputs.profile }}/servo-tech-demo.dmg
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
id: artifact_ids
shell: bash
run: |
echo "artifact_ids=${{ steps.upload-dmg.outputs.artifact-id }}" >> $GITHUB_OUTPUT
- name: Build package for target
run: gtar -czf target.tar.gz target/${{ inputs.profile }}/servo target/${{ inputs.profile }}/lib/*.dylib resources
run: gtar -czf target.tar.gz target/${{ inputs.profile }}/servoshell target/${{ inputs.profile }}/lib/*.dylib resources
- name: Upload package for target
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: ${{ inputs.profile }}-binary-macos-arm64
path: target.tar.gz
if-no-files-found: error
wpt-2020:
if: ${{ inputs.wpt }}
@@ -213,7 +227,7 @@ jobs:
target: 'macos-arm64'
profile: ${{ inputs.profile }}
compressed-file-path: ${{ inputs.profile }}-binary-macos-arm64/target.tar.gz
binary-path: target/${{ inputs.profile }}/servo
binary-path: target/${{ inputs.profile }}/servoshell
file-size: true
speedometer: false
dromaeo: false
@@ -246,4 +260,4 @@ jobs:
toolchain: ${{ steps.msrv.outputs.rust_version }}
- name: Compile libservo with MSRV
run: |
cargo +${{ steps.msrv.outputs.rust_version }} build -p libservo --locked --all-targets
cargo +${{ steps.msrv.outputs.rust_version }} build -p servo --locked

View File

@@ -38,7 +38,7 @@ jobs:
if: github.event_name == 'pull_request_target'
with:
ref: refs/pull/${{ github.event.number }}/head
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
with:
name: ${{ inputs.profile }}-binary-${{ env.NAME }}
- name: Setup Python
@@ -62,17 +62,19 @@ jobs:
--filter-intermittents wpt-filtered-logs/${{ env.NAME }}/${{ matrix.chunk_id }}.json
${{ inputs.wpt-args }}
- name: Archive results (filtered)
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-filtered-logs-${{ env.NAME }}-${{ matrix.chunk_id }}
path: wpt-filtered-logs/*/
if-no-files-found: error
- name: Archive results (full)
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
if: ${{ always() }}
with:
name: wpt-full-logs-${{ env.NAME }}-${{ matrix.chunk_id }}
path: wpt-full-logs/*/
if-no-files-found: error
report-test-results:
name: Process WPT Results
@@ -81,13 +83,13 @@ jobs:
needs: mac-wpt
steps:
- name: Merge logs (filtered)
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: wpt-filtered-logs-${{ env.NAME }}
pattern: wpt-filtered-logs-${{ env.NAME }}-*
delete-merged: true
- name: Merge logs (full)
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: wpt-full-logs-${{ env.NAME }}
pattern: wpt-full-logs-${{ env.NAME }}-*
@@ -103,11 +105,12 @@ jobs:
cat results/${{ env.NAME }}/*.log > stable-unexpected-results.log || true
- name: Upload aggregated results
if: ${{ !cancelled() && !inputs.wpt-sync-from-upstream }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: stable-unexpected-results-${{ env.NAME }}
path: stable-unexpected-results.log
- uses: actions/download-artifact@v4
if-no-files-found: error
- uses: actions/download-artifact@v8
if: ${{ !cancelled() }}
with:
name: wpt-filtered-logs-${{ env.NAME }}

View File

@@ -87,7 +87,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
github-hosted-runner-label: macos-15-intel
@@ -114,7 +114,7 @@ jobs:
- name: Kill XProtectBehaviorService
run: |
echo Killing XProtect.; sudo pkill -9 XProtect >/dev/null || true;
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
- if: runner.environment != 'self-hosted'
name: Setup Python
@@ -126,19 +126,21 @@ jobs:
- name: Install crown
run: cargo install --path support/crown
- uses: taiki-e/install-action@v2
- name: Install cargo nextest
if: ${{ inputs.unit-tests }}
uses: taiki-e/install-action@v2
with:
tool: nextest
- if: runner.environment != 'self-hosted'
name: Bootstrap
run: |
./mach bootstrap --yes --skip-lints
./mach bootstrap --yes --skip-lints --skip-nextest
brew install gnu-tar
- name: Build (${{ inputs.profile }})
run: |
./mach build --use-crown --locked --profile ${{ inputs.profile }} ${{ inputs.build-args }}
cp -r target/cargo-timings target/cargo-timings-macos
mv target/cargo-timings target/cargo-timings-macos
- name: Smoketest
uses: nick-fields/retry@v3
with: # See https://github.com/servo/servo/issues/30757
@@ -178,29 +180,32 @@ jobs:
max_attempts: 2
command: ./etc/ci/macos_package_smoketest.sh target/${{ inputs.profile }}/servo-tech-demo.dmg
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-macos-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: target/cargo-timings-*
if-no-files-found: error
- name: Upload artifact for mach package
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-dmg
with:
name: ${{ inputs.profile }}-binary-mac
path: target/${{ inputs.profile }}/servo-tech-demo.dmg
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
id: artifact_ids
shell: bash
run: |
echo "artifact_ids=${{ steps.upload-dmg.outputs.artifact-id }}" >> $GITHUB_OUTPUT
- name: Build package for target
run: gtar -czf target.tar.gz target/${{ inputs.profile }}/servo target/${{ inputs.profile }}/lib/*.dylib resources
run: gtar -czf target.tar.gz target/${{ inputs.profile }}/servoshell target/${{ inputs.profile }}/lib/*.dylib resources
- name: Upload package for target
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: ${{ inputs.profile }}-binary-macos
path: target.tar.gz
if-no-files-found: error
wpt-2020:
if: ${{ inputs.wpt }}
@@ -221,7 +226,7 @@ jobs:
target: 'macos'
profile: ${{ inputs.profile }}
compressed-file-path: ${{ inputs.profile }}-binary-macos/target.tar.gz
binary-path: target/${{ inputs.profile }}/servo
binary-path: target/${{ inputs.profile }}/servoshell
file-size: true
speedometer: false
dromaeo: false
@@ -254,4 +259,4 @@ jobs:
toolchain: ${{ steps.msrv.outputs.rust_version }}
- name: Compile libservo with MSRV
run: |
cargo +${{ steps.msrv.outputs.rust_version }} build -p libservo --locked --all-targets
cargo +${{ steps.msrv.outputs.rust_version }} build -p servo --locked

View File

@@ -36,7 +36,7 @@ jobs:
run: |
{
echo 'result<<EOF'
python ./python/servo/try_parser.py ${{ github.event_name == 'pull_request' && 'linux-unit-tests lint' || github.event_name == 'push' && 'full macos bencher production-bencher coverage' || 'fail-fast full macos-arm-unit-tests' }}
python ./python/servo/try_parser.py ${{ github.event_name == 'pull_request' && 'linux-unit-tests lint' || github.event_name == 'push' && 'full macos bencher production-bencher coverage' || 'fail-fast full' }}
echo EOF
} >> $GITHUB_OUTPUT
@@ -71,7 +71,7 @@ jobs:
- build
steps:
- name: Merge build timings
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: cargo-timings
pattern: cargo-timings-*

View File

@@ -16,7 +16,7 @@ on:
type: boolean
outputs:
artifact_ids:
value: ${{ jobs.build.outputs.artifact_ids }}
value: ${{ jobs.build-openharmony.outputs.artifact_ids }}
description: Comma-separated list of artifact IDs for the release artifacts
optional_job_status:
description: "Status of optional jobs (as an object)"
@@ -46,7 +46,7 @@ jobs:
build-openharmony:
name: OpenHarmony Build
timeout-minutes: 60
runs-on: ubuntu-22.04
runs-on: ubuntu-24.04
strategy:
matrix:
target: ["aarch64-unknown-linux-ohos", "x86_64-unknown-linux-ohos"]
@@ -54,13 +54,13 @@ jobs:
artifact_ids: ${{ steps.artifact_ids.outputs.artifact_ids }}
signed: ${{ steps.signing_config.outputs.signed }}
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
if: github.event_name != 'pull_request_target'
with:
fetch-depth: 2
# This is necessary to checkout the pull request if this run was triggered via a
# `pull_request_target` event.
- uses: actions/checkout@v5
- uses: actions/checkout@v6
if: github.event_name == 'pull_request_target'
with:
ref: ${{ github.event.pull_request.head.sha }}
@@ -81,9 +81,9 @@ jobs:
version: "6.0.0.1" # api 20 in openharmony
fixup-path: true
- name: Install node for hvigor
uses: actions/setup-node@v4
uses: actions/setup-node@v6
with:
node-version: 18
node-version: 24
- name: Install hvigor modules
run: |
mkdir ~/hvigor-installation
@@ -108,34 +108,38 @@ jobs:
OHOS_BASE_SDK_HOME: ${{ steps.setup_sdk.outputs.ohos-base-sdk-home }}
run: |
./mach build --locked --target ${{ matrix.target }} --profile ${{ inputs.profile }}
cp -r target/cargo-timings target/cargo-timings-ohos-${{ matrix.target }}
mv target/cargo-timings target/cargo-timings-ohos-${{ matrix.target }}
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-ohos-${{ matrix.target }}-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: target/cargo-timings-*
if-no-files-found: error
- name: Upload shared library
if: ${{ inputs.upload_library }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-library
with:
name: ${{ inputs.profile }}-library-ohos-${{ matrix.target }}
path: target/aarch64-unknown-linux-ohos/production/libservoshell.so
path: target/${{ matrix.target }}/${{ inputs.profile }}/libservoshell.so
if-no-files-found: error
- name: Upload signed HAP artifact
if: ${{ env.SERVO_OHOS_SIGNING_CONFIG != '' }} # Build output has different name if not signed.
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-hap-signed
with:
name: ${{ inputs.profile }}-binary-ohos-${{ matrix.target }}
path: target/openharmony/${{ matrix.target }}/${{ inputs.profile }}/entry/build/default/outputs/default/servoshell-default-signed.hap
if-no-files-found: error
- name: Upload unsigned HAP artifact
if: ${{ env.SERVO_OHOS_SIGNING_CONFIG == '' }} # Build output has different name if not signed.
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-hap-unsigned
with:
name: ${{ inputs.profile }}-binary-ohos-${{ matrix.target }}
path: target/openharmony/${{ matrix.target }}/${{ inputs.profile }}/entry/build/default/outputs/default/servoshell-default-unsigned.hap
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
# The implicit assumption here is that `upload_library` is true and the signed hap is uploaded,
# since this output will only be consumed by the release workflow.
@@ -155,7 +159,7 @@ jobs:
with:
target: ohos-${{ matrix.target }}
profile: ${{ inputs.profile }}
compressed-file-path: ${{ inputs.profile }}-binary-ohos-${{ matrix.target }}/servoshell-default-${{ needs.build.outputs.signed && 'signed' || 'unsigned' }}.hap
compressed-file-path: ${{ inputs.profile }}-binary-ohos-${{ matrix.target }}/servoshell-default-${{ needs.build-openharmony.outputs.signed && 'signed' || 'unsigned' }}.hap
binary-path: libs/${{ matrix.target == 'aarch64-unknown-linux-ohos' && 'arm64-v8a' || matrix.target == 'x86_64-unknown-linux-ohos' && 'x86_64' }}/libservoshell.so
file-size: true
speedometer: false
@@ -178,19 +182,22 @@ jobs:
run: git fetch --depth=1 origin $GITHUB_SHA
- if: ${{ github.event_name == 'pull_request_target' }}
run: git fetch --depth=1 origin ${{ github.event.pull_request.head.sha }}
# Safeguard: -- means FETCH_HEAD is revision instead of path.
# See <https://github.com/servo/servo/pull/44309>
- run: |
git switch --detach
git reset --hard FETCH_HEAD
git reset --hard FETCH_HEAD --
- name: Adding test files to directory
run: cp -r support/hitrace-bencher/* support/openharmony/AppScope/resources/resfile/
- name: Build for aarch64 HarmonyOS
run: |
./mach build --locked --target aarch64-unknown-linux-ohos --profile=${{ inputs.profile }} --flavor=harmonyos --no-default-features --features tracing,tracing-hitrace
- uses: actions/upload-artifact@v6
- uses: actions/upload-artifact@v7
with:
# Upload the **unsigned** artifact - We don't have the signing materials in pull request workflows
name: servoshell-hos-${{ inputs.profile }}.hap
path: target/openharmony/aarch64-unknown-linux-ohos/${{ inputs.profile }}/entry/build/harmonyos/outputs/default/servoshell-default-unsigned.hap
if-no-files-found: error
- name: Save result as job output
id: result
if: always()
@@ -209,7 +216,7 @@ jobs:
job_status: ${{ steps.result.outputs.JOB_STATUS }}
if: github.repository == 'servo/servo' && needs.build-harmonyos-aarch64.outputs.job_status == 'success'
steps:
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
with:
# Name of the artifact to download.
# If unspecified, all artifacts for the run are downloaded.
@@ -228,13 +235,13 @@ jobs:
# to make sure we don't use a previous version if installation failed for some reason.
hdc uninstall org.servo.servo
hdc install -r servoshell-hos-signed.hap
- uses: actions/checkout@v5
- uses: actions/checkout@v6
if: github.event_name != 'pull_request_target'
with:
fetch-depth: 0
# This is necessary to checkout the pull request if this run was triggered via a
# `pull_request_target` event.
- uses: actions/checkout@v5
- uses: actions/checkout@v6
if: github.event_name == 'pull_request_target'
with:
ref: ${{ github.event.pull_request.head.sha }}
@@ -305,10 +312,11 @@ jobs:
run: hitrace-bench -r support/hitrace-bencher/runs.json --bencher -p ${{ inputs.profile }}
- name: Upload failure screenshots
if: ${{ steps.hitrace_bench.success == 'failure' }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: bencher-${{ inputs.profile }}-failure-screenshot
path: "/tmp/servo.jpeg"
if-no-files-found: error
- name: Run speedometer
id: speedometer
run: uv run ./etc/ci/scenario/servo_speedometer.py ${{ inputs.profile }}
@@ -323,11 +331,12 @@ jobs:
hdc file recv /data/local/tmp/servo.jpeg speedometer_error_logs/servo_hos_screenshot.jpeg
# Todo: Upload logs. This is currently not possible since the test-speedometer-ohos command
# sets a log filter, which filters everything except JS console output.
- uses: actions/upload-artifact@v6
- uses: actions/upload-artifact@v7
if: ${{ !cancelled() && steps.speedometer.outcome == 'failure' }}
with:
name: ohos-speedometer-failure-${{ matrix.target }}-${{ inputs.profile }}
path: speedometer_error_logs
if-no-files-found: error
- name: Combining bencher files
if: ${{ !cancelled() && steps.setup_complete.outcome == 'success' }}
run: jq --compact-output --slurp add speedometer.json bench.json > combined-bencher.json
@@ -367,7 +376,7 @@ jobs:
# This will ensure the scenario pyproject.toml is picked up and the correct venv used.
UV_PROJECT: "etc/ci/scenario"
steps:
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
with:
# Name of the artifact to download.
# If unspecified, all artifacts for the run are downloaded.
@@ -387,7 +396,7 @@ jobs:
hdc uninstall org.servo.servo
hdc install -r servoshell-hos-signed.hap
- name: Checkout scenario scripts
uses: actions/checkout@v5
uses: actions/checkout@v6
with:
sparse-checkout: |
etc/ci/scenario
@@ -420,10 +429,11 @@ jobs:
run: uv run ./etc/ci/scenario/servo_test_slide.py
- name: Upload failure screenshots
if: ${{ steps.install_hap.outcome == 'success' && failure() }}
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: hos-${{ inputs.profile }}-scenario-failures-screenshots
path: "servo_scenario_*_error.jpg"
if-no-files-found: error
- name: Save result as job output
id: result
if: always()

View File

@@ -13,6 +13,10 @@ on:
description: '`true` to create a release on this repo, false to release to the nightly-releases repo'
type: boolean
default: false
crates_io:
description: '`true` to publish to crates.io'
type: boolean
default: false
release_tag:
required: true
type: string
@@ -28,6 +32,9 @@ jobs:
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
name: Create Draft GH Release
runs-on: ubuntu-latest
environment: &publish-environment
name: publish
deployment: false
steps:
- id: create-release
run: |
@@ -46,7 +53,7 @@ jobs:
TEMP_TAG=$(basename "$RELEASE_URL")
RELEASE_ID=$( \
gh api -H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
-H "X-GitHub-Api-Version: 2026-03-10" \
"/repos/${RELEASE_REPO}/releases/tags/${TEMP_TAG}" \
| jq '.id' \
)
@@ -66,37 +73,64 @@ jobs:
&& (inputs.regular_release || false) == false
name: Publish GH Release
runs-on: ubuntu-latest
environment: *publish-environment
steps:
- name: Publish as latest (success)
if: ${{ !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') }}
- name: Publish release (success)
if: ${{ !contains(needs.*.result, 'failure') && (!contains(needs.*.result, 'cancelled') && !cancelled()) }}
env:
MAKE_LATEST: ${{ github.event_name == 'schedule' && 'true' || 'false' }}
run: |
gh api \
--method PATCH \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
-H "X-GitHub-Api-Version: 2026-03-10" \
/repos/${RELEASE_REPO}/releases/${RELEASE_ID} \
-F draft=false
- name: Publish as latest (failure)
if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}
-F draft=false \
-f make_latest="${MAKE_LATEST}"
- name: Publish release (failure)
if: ${{ contains(needs.*.result, 'failure') || (contains(needs.*.result, 'cancelled') || cancelled()) }}
run: |
gh api \
--method PATCH \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
-H "X-GitHub-Api-Version: 2026-03-10" \
/repos/${RELEASE_REPO}/releases/${RELEASE_ID} \
-F prerelease=true -F draft=false
-F prerelease=true \
-F draft=false \
-f make_latest=false
env:
GITHUB_TOKEN: ${{ inputs.regular_release && github.token || secrets.NIGHTLY_REPO_TOKEN }}
RELEASE_ID: ${{ needs.create-draft-release.outputs.release-id }}
needs:
- create-draft-release
- upload-vendored-source
- upload-linux-nightly
- upload-win-nightly
- upload-mac-nightly
- upload-mac-arm64-nightly
- upload-android-nightly
- upload-ohos-nightly
- upload-artifacts-nightly
- upload-artifacts-release
publish-crates-io:
name: 'Publish to crates.io'
if: github.repository == 'servo/servo' && (inputs.crates_io || false)
environment:
name: publish_crates_io
deployment: false
runs-on: ubuntu-22.04
permissions:
id-token: write
steps:
- uses: actions/checkout@v6
- uses: rust-lang/crates-io-auth-action@v1
id: auth
- name: Publish to crates.io
env:
CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }}
SERVO_CRATES_IO_SLEEP_AFTER_PUBLISH_SECONDS: "30"
SERVO_CRATES_IO_VERIFY_PUBLISHED_TIMEOUT_SECONDS: "300"
SERVO_CRATES_IO_VERIFY_PUBLISHED_INTERVAL_SECONDS: "10"
# Verification requires building, which is incredibly slow and also increases our attack surface.
# If we decide for an extra verification, we should add a seperate job before this one, which
# does a `dry-run` publish without any elevated permissions.
run: |
python3 etc/ci/publish_crates_io.py --no-verify
build-win:
# This job is only useful when run on upstream servo.
@@ -113,6 +147,7 @@ jobs:
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
name: Upload vendored source archive
runs-on: ubuntu-latest
environment: *publish-environment
permissions:
contents: write
id-token: write
@@ -141,45 +176,100 @@ jobs:
env:
GITHUB_TOKEN: ${{ inputs.regular_release && github.token || secrets.NIGHTLY_REPO_TOKEN }}
upload-win-nightly:
upload-artifacts-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
runs-on: ubuntu-latest
permissions:
id-token: write
attestations: write
needs:
environment: *publish-environment
needs: &upload-artifacts-needs
- create-draft-release
- build-win
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-win.outputs.artifact_ids }}
artifact_platform: windows-msvc
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
- build-mac
- build-mac-arm64
- build-linux
- build-android
- build-ohos
strategy: &upload-artifacts-strategy
fail-fast: false
matrix:
include:
- artifact_ids: ${{ needs.build-win.outputs.artifact_ids }}
artifact_platform: windows-msvc
- artifact_ids: ${{ needs.build-mac.outputs.artifact_ids }}
artifact_platform: mac
- artifact_ids: ${{ needs.build-mac-arm64.outputs.artifact_ids }}
artifact_platform: mac-arm64
- artifact_ids: ${{ needs.build-linux.outputs.artifact_ids }}
artifact_platform: linux
- artifact_ids: ${{ needs.build-android.outputs.artifact_ids }}
artifact_platform: android
- artifact_ids: ${{ needs.build-ohos.outputs.artifact_ids }}
artifact_platform: ohos
env:
ARTIFACT_IDS: ${{ matrix.artifact_ids }}
ARTIFACT_PLATFORM: ${{ matrix.artifact_platform }}
GITHUB_RELEASE_ID: ${{ needs.create-draft-release.outputs.release-id }}
RELEASE_REPO: ${{ github.repository_owner }}/servo-nightly-builds
RELEASE_REPO_TOKEN: ${{ secrets.NIGHTLY_REPO_TOKEN }}
S3_UPLOAD_CREDENTIALS: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
steps: &upload-artifacts-steps
- uses: actions/checkout@v6
with:
sparse-checkout: |
.github
etc/ci
fetch-depth: '1'
- name: Setup Python
uses: ./.github/actions/setup-python
- name: Validate artifact IDs
run: |
if [[ -z "${ARTIFACT_IDS}" ]]; then
echo "Error: No artifact IDs provided."
echo "Help: Check the build job's outputs.artifact_ids value."
echo "If you recently renamed the build job without updating the corresponding output reference,"
echo "that is likely the cause of this error."
exit 1
fi
- uses: actions/download-artifact@v8
with:
artifact-ids: ${{ env.ARTIFACT_IDS }}
merge-multiple: true
path: release-artifacts
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v3
with:
subject-path: 'release-artifacts/*'
- name: Upload release artifacts
run: |
./etc/ci/upload_nightly.py "${ARTIFACT_PLATFORM}" \
--secret-from-environment \
--github-release-id "${GITHUB_RELEASE_ID}" \
release-artifacts/*
upload-win-release:
upload-artifacts-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
runs-on: ubuntu-latest
environment: *publish-environment
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-win
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-win.outputs.artifact_ids }}
artifact_platform: windows-msvc
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
needs: *upload-artifacts-needs
strategy: *upload-artifacts-strategy
env:
ARTIFACT_IDS: ${{ matrix.artifact_ids }}
ARTIFACT_PLATFORM: ${{ matrix.artifact_platform }}
GITHUB_RELEASE_ID: ${{ needs.create-draft-release.outputs.release-id }}
RELEASE_REPO: ${{ github.repository_owner }}/servo
RELEASE_REPO_TOKEN: ${{ github.token }}
S3_UPLOAD_CREDENTIALS: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
steps: *upload-artifacts-steps
build-mac:
@@ -191,46 +281,6 @@ jobs:
profile: "production"
force-github-hosted-runner: true # <https://github.com/servo/servo/issues/33296>
upload-mac-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
permissions:
id-token: write
attestations: write
needs:
- create-draft-release
- build-mac
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-mac.outputs.artifact_ids }}
artifact_platform: mac
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
upload-mac-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-mac
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-mac.outputs.artifact_ids }}
artifact_platform: mac
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
build-mac-arm64:
# This job is only useful when run on upstream servo.
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
@@ -240,46 +290,6 @@ jobs:
profile: "production"
force-github-hosted-runner: true # <https://github.com/servo/servo/issues/33296>
upload-mac-arm64-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
permissions:
id-token: write
attestations: write
needs:
- create-draft-release
- build-mac-arm64
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-mac-arm64.outputs.artifact_ids }}
artifact_platform: mac-arm64
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
upload-mac-arm64-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-mac-arm64
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-mac-arm64.outputs.artifact_ids }}
artifact_platform: mac-arm64
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
build-linux:
# This job is only useful when run on upstream servo.
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
@@ -289,96 +299,15 @@ jobs:
profile: "production"
force-github-hosted-runner: true # <https://github.com/servo/servo/issues/33296>
upload-linux-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
permissions:
id-token: write
attestations: write
needs:
- create-draft-release
- build-linux
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-linux.outputs.artifact_ids }}
artifact_platform: linux
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
upload-linux-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-linux
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-linux.outputs.artifact_ids }}
artifact_platform: linux
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
build-android:
# This job is only useful when run on upstream servo.
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
name: Build release (Android)
uses: ./.github/workflows/android.yml
with:
profile: "release"
profile: "production"
secrets: inherit
upload-android-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
permissions:
id-token: write
attestations: write
needs:
- create-draft-release
- build-android
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-android.outputs.artifact_ids }}
artifact_platform: android
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
upload-android-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-android
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-android.outputs.artifact_ids }}
artifact_platform: android
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
build-ohos:
# This job is only useful when run on upstream servo.
if: github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch'
@@ -388,43 +317,3 @@ jobs:
profile: "production"
upload_library: true
secrets: inherit
upload-ohos-nightly:
# Only run scheduled nightly builds on upstream servo.
if: |
(github.repository == 'servo/servo' || github.event_name == 'workflow_dispatch')
&& (inputs.regular_release || false) == false
permissions:
id-token: write
attestations: write
needs:
- create-draft-release
- build-ohos
secrets:
github_upload_token: ${{ secrets.NIGHTLY_REPO_TOKEN }}
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-ohos.outputs.artifact_ids }}
artifact_platform: ohos
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}
upload-ohos-release:
if: github.event_name == 'workflow_dispatch' && inputs.regular_release
permissions:
id-token: write
attestations: write
# Necessary for the github token to upload artifacts to the release.
contents: write
needs:
- create-draft-release
- build-ohos
secrets:
s3_upload_token: ${{ secrets.S3_UPLOAD_CREDENTIALS }}
uses: ./.github/workflows/upload_release.yml
with:
artifact_ids: ${{ needs.build-ohos.outputs.artifact_ids }}
artifact_platform: ohos
github_release_id: ${{ needs.create-draft-release.outputs.release-id }}
target_repo: ${{ github.repository_owner }}/${{ inputs.regular_release && 'servo' || 'servo-nightly-builds' }}

View File

@@ -29,7 +29,7 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v5
- uses: actions/download-artifact@v4
- uses: actions/download-artifact@v8
with:
name: wpt-full-logs-linux
- name: Setup Python

View File

@@ -15,7 +15,7 @@ jobs:
try_string: ${{ steps.try_string.outputs.result }}
steps:
- name: Collect Labels
uses: actions/github-script@v7
uses: actions/github-script@v8
id: try_string
with:
result-encoding: string
@@ -87,7 +87,7 @@ jobs:
} >> $GITHUB_OUTPUT
- name: Comment Run Start
if: ${{ steps.try_string.outputs.result }}
uses: actions/github-script@v7
uses: actions/github-script@v8
with:
result-encoding: string
script: |

View File

@@ -56,7 +56,7 @@ jobs:
} >> $GITHUB_OUTPUT
- name: Configuration
id: configuration
uses: actions/github-script@v7
uses: actions/github-script@v8
with:
script: |
// When triggered via a push try the `try` branch, search the last commit for a configuration object.
@@ -128,7 +128,7 @@ jobs:
steps:
- name: Merge build timings
continue-on-error: true
uses: actions/upload-artifact/merge@v4
uses: actions/upload-artifact/merge@v7
with:
name: cargo-timings
pattern: cargo-timings-*

View File

@@ -1,60 +0,0 @@
name: Upload and Attest Release Assets
on:
workflow_call:
inputs:
artifact_platform:
type: string
required: true
description: "The platform of the release artifacts to upload."
target_repo:
type: string
required: true
description: "The target repository owner and name (e.g. `servo/servo`) where the release will be created."
github_release_id:
type: string
required: true
description: "The ID of the GitHub release to which assets will be added."
artifact_ids:
required: true
type: string
description: "A comma-separated list of artifact IDs to upload."
secrets:
github_upload_token:
required: false
description: "A GitHub token with permission to upload release assets. If omitted github.token will be used instead."
s3_upload_token:
required: true
description: "A token with permission to upload release artifacts to our S3 bucket."
jobs:
upload-artifact:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
sparse-checkout: |
.github
etc/ci
fetch-depth: '1'
- name: Setup Python
uses: ./.github/actions/setup-python
- uses: actions/download-artifact@v7
with:
artifact-ids: ${{ inputs.artifact_ids }}
merge-multiple: true
path: release-artifacts
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v3
with:
subject-path: 'release-artifacts/*'
- name: Upload release artifacts
run: |
./etc/ci/upload_nightly.py ${{ inputs.artifact_platform}} \
--secret-from-environment \
--github-release-id ${{ inputs.github_release_id }} \
release-artifacts/*
env:
S3_UPLOAD_CREDENTIALS: ${{ secrets.s3_upload_token }}
RELEASE_REPO_TOKEN: ${{ secrets.github_upload_token || github.token }}
RELEASE_REPO: ${{ inputs.target_repo }}

View File

@@ -83,7 +83,7 @@ jobs:
steps:
- name: Runner select
id: select
uses: servo/ci-runners/actions/runner-select@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
uses: servo/ci-runners/actions/runner-select@f0b81b95522256c64ee207b4236ec71fc23b99a1
with:
GITHUB_TOKEN: ${{ github.token }}
github-hosted-runner-label: windows-2022
@@ -103,7 +103,7 @@ jobs:
outputs:
release_artifact_ids: ${{ steps.artifact_ids.outputs.release_artifact_ids }}
steps:
- uses: servo/ci-runners/actions/checkout@6d88b19dda997f1ce2a11e4c1c34717c2bbcafba
- uses: servo/ci-runners/actions/checkout@f0b81b95522256c64ee207b4236ec71fc23b99a1
- name: ccache
# FIXME: “Error: Restoring cache failed: Error: Unable to locate executable file: sh.”
@@ -149,7 +149,7 @@ jobs:
- name: Build (${{ inputs.profile }})
run: |
.\mach build --use-crown --locked --profile ${{ inputs.profile }} ${{ inputs.build-args }}
cp C:\a\servo\servo\target\cargo-timings C:\a\servo\servo\target\cargo-timings-windows -Recurse
mv C:\a\servo\servo\target\cargo-timings C:\a\servo\servo\target\cargo-timings-windows
- name: Copy resources
# GitHub-hosted runners sometimes check out the repo on D: drive.
if: ${{ runner.environment != 'self-hosted' && startsWith(github.workspace, 'D:\') }}
@@ -157,13 +157,13 @@ jobs:
- name: Smoketest
run: .\mach smoketest --profile ${{ inputs.profile }}
- name: Install cargo nextest
if: ${{ runner.environment != 'self-hosted' }}
if: ${{ runner.environment != 'self-hosted' && inputs.unit-tests }}
uses: taiki-e/install-action@v2
with:
tool: nextest
# On self-hosted windows runners the install-action fails
- name: Install cargo nextest (self-hosted)
if: ${{ runner.environment == 'self-hosted' }}
if: ${{ runner.environment == 'self-hosted' && inputs.unit-tests }}
run: cargo install cargo-nextest --locked
- name: Unit tests
if: ${{ inputs.unit-tests }}
@@ -188,30 +188,33 @@ jobs:
if: ${{ false && inputs.unit-tests }} # FIXME #39273
run: .\mach test-devtools --profile ${{ inputs.profile }}
- name: Archive build timing
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
with:
name: cargo-timings-windows-${{ inputs.profile }}
# Using a wildcard here ensures that the archive includes the path.
path: C:\\a\\servo\\servo\\target\\cargo-timings-*
if-no-files-found: error
- name: Build mach package
run: .\mach package --profile ${{ inputs.profile }}
# These files are available
# MSI Installer: C:\a\servo\servo\target\${{ inputs.profile }}\msi\Installer.msi
# Bundle: C:\a\servo\servo\target\${{ inputs.profile }}\msi\Servo.exe
# Zip: C:\a\servo\servo\target\${{ inputs.profile }}\msi\Servo.zip
# Bundle: C:\a\servo\servo\target\${{ inputs.profile }}\msi\ServoShell.exe
# Zip: C:\a\servo\servo\target\${{ inputs.profile }}\msi\ServoShell.zip
- name: Upload artifact for mach package
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-exe
with:
name: ${{ inputs.profile }}-binary-windows
path: C:\\a\\servo\\servo\\target\\${{ inputs.profile }}\\msi\\Servo.exe
path: C:\\a\\servo\\servo\\target\\${{ inputs.profile }}\\msi\\ServoShell.exe
if-no-files-found: error
- name: Upload artifact for mach package (zip)
uses: actions/upload-artifact@v6
uses: actions/upload-artifact@v7
id: upload-zip
if: ${{ inputs.upload_zip }}
with:
name: ${{ inputs.profile }}-binary-windows-zip
path: C:\\a\\servo\\servo\\target\\${{ inputs.profile }}\\msi\\Servo.zip
path: C:\\a\\servo\\servo\\target\\${{ inputs.profile }}\\msi\\ServoShell.zip
if-no-files-found: error
- name: Collect artifact IDs needed by the release workflow
id: artifact_ids
shell: bash
@@ -230,7 +233,7 @@ jobs:
target: 'windows'
profile: ${{ inputs.profile }}
compressed-file-path: ''
binary-path: ${{ inputs.profile }}-binary-windows/Servo.exe
binary-path: ${{ inputs.profile }}-binary-windows/ServoShell.exe
file-size: true
speedometer: false
dromaeo: false
@@ -263,4 +266,4 @@ jobs:
toolchain: ${{ steps.msrv.outputs.rust_version }}
- name: Compile libservo with MSRV
run: |
cargo +${{ steps.msrv.outputs.rust_version }} build -p libservo --locked --all-targets
cargo +${{ steps.msrv.outputs.rust_version }} build -p servo --locked

1
.gitignore vendored
View File

@@ -29,6 +29,7 @@ servo.pftrace
/glfw
webrender-captures/
/screenshots
/etc/notarization/
# Python setuptools
/servo.egg-info

2107
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -10,8 +10,11 @@ default-members = ["ports/servoshell"]
exclude = [".cargo", "support/crown"]
[workspace.package]
version = "0.0.1"
version = "0.1.0"
authors = ["The Servo Project Developers"]
repository = "https://github.com/servo/servo"
# A generic description for packages that don't have a meaningful description yet.
description = "A component of the servo web-engine."
license = "MPL-2.0"
edition = "2024"
publish = false
@@ -33,46 +36,40 @@ app_units = "0.7"
arboard = "3"
argon2 = { version = "0.5", features = ["alloc"] }
arrayvec = "0.7"
async-tungstenite = { version = "0.33", features = ["tokio-rustls-webpki-roots"] }
atomic_refcell = "0.1.13"
async-tungstenite = { version = "0.34", features = ["tokio-rustls-webpki-roots"] }
atomic_refcell = "0.1.14"
aws-lc-rs = { version = "1.16", default-features = false, features = ["aws-lc-sys"] }
background_hang_monitor_api = { package = "servo-background-hang-monitor-api", path = "components/shared/background_hang_monitor" }
backtrace = "0.3"
base = { package = "servo-base", path = "components/shared/base" }
base64 = "0.22.1"
base64ct = { version = "1.8", features = ["alloc"] }
bitflags = "2.11"
bluetooth_traits = { package = "servo-bluetooth-traits", path = "components/shared/bluetooth" }
brotli = "8.0.2"
bytemuck = "1"
byteorder = "1.5"
canvas_traits = { package = "servo-canvas-traits", path = "components/shared/canvas" }
bytes = "1.0"
byte-slice-cast = "1.2.3"
cbc = "0.1.2"
cfg-if = "1.0.4"
chacha20poly1305 = "0.10"
chardetng = "0.1"
chrono = { version = "0.4", features = ["serde"] }
cipher = { version = "0.4.4", features = ["alloc"] }
constellation_traits = { package = "servo-constellation-traits", path = "components/shared/constellation" }
content-security-policy = { version = "0.6.0", features = ["serde"] }
content-security-policy = { version = "0.8.0", features = ["serde"] }
cookie = { package = "cookie", version = "0.18" }
crossbeam-channel = "0.5"
cssparser = { version = "0.36", features = ["serde"] }
ctr = "0.9.2"
data-url = "0.3"
der = { version = "0.7", features = ["alloc", "derive"] }
devtools_traits = { package = "servo-devtools-traits", path = "components/shared/devtools" }
digest = "0.10"
dpi = "0.1"
dwrote = "0.11.5"
ecdsa = "0.16"
elliptic-curve = "0.13"
embedder_traits = { package = "servo-embedder-traits", path = "components/shared/embedder" }
encoding_rs = { version = "0.8", features = ["serde"] }
env_logger = "0.11"
euclid = "0.22"
flate2 = "1.1"
fonts_traits = { package = "servo-fonts-traits", path = "components/shared/fonts" }
freetype-sys = "0.20"
futures = { version = "0.3", default-features = false }
futures-core = { version = "0.3", default-features = false }
@@ -80,7 +77,7 @@ futures-util = { version = "0.3", default-features = false }
gleam = "0.15"
glib = "0.22"
glib-sys = "0.22"
glow = "0.16.0"
glow = "0.17.0"
gstreamer = { version = "0.25", features = ["v1_18"] }
gstreamer-app = "0.25"
gstreamer-audio = "0.25"
@@ -99,42 +96,42 @@ harfbuzz-sys = "0.6.1"
headers = "0.4"
hitrace = { version = "0.1.6", features = ["api-19", "tracing-rs"] }
hkdf = "0.12"
html5ever = "0.38"
html5ever = "0.39"
http = "1.4"
http-body-util = "0.1"
hyper = "1.8"
hyper = "1.9"
hyper-rustls = { version = "0.27", default-features = false, features = ["http1", "http2", "logging", "tls12", "webpki-tokio"] }
hyper-util = { version = "0.1", features = ["client-legacy", "http2", "tokio", "client-proxy"] }
hyper_serde = { package = "servo-hyper-serde", path = "components/hyper_serde" }
icu_locid = "1.5.0"
icu_properties = "1.5.0"
icu_segmenter = "1.5.0"
image = { version = "0.25", default-features = false, features = ["avif", "rayon", "bmp", "gif", "ico", "jpeg", "png", "webp"] }
imsz = "0.4"
indexmap = { version = "2.11.4", features = ["std"] }
indexmap = { version = "2.14.0", features = ["std"] }
inventory = { version = "0.3.24" }
ipc-channel = "0.21"
itertools = "0.14"
js = { package = "mozjs", version = "=0.15.1", default-features = false, features = ["libz-sys", "intl"] }
js = { package = "mozjs", version = "=0.15.9", default-features = false, features = ["libz-sys", "intl"] }
keyboard-types = { version = "0.8.3", features = ["serde", "webdriver"] }
kurbo = { version = "0.12", features = ["euclid"] }
layout_api = { package = "servo-layout-api", path = "components/shared/layout" }
libc = "0.2"
lru = "0.17"
log = "0.4.29"
mach2 = "0.6"
malloc_size_of = { package = "servo-malloc-size-of", path = "components/malloc_size_of" }
malloc_size_of_derive = "0.1"
markup5ever = "0.38"
markup5ever = "0.39"
memmap2 = "0.9.10"
mime = "0.3.13"
mime-multipart-hyper1 = "0.10.0"
mime_guess = "2.0.5"
ml-dsa = "0.0.4"
ml-kem = { version = "0.2", features = ["deterministic"] }
mozangle = "0.5.3"
net_traits = { package = "servo-net-traits", path = "components/shared/net" }
mozangle = "0.5.5"
nix = "0.30"
nom = "8.0.0"
nom-rfc8288 = "0.4.0"
num-bigint-dig = "0.8"
num-complex = "0.4.6"
num-derive = "0.4.2"
num-traits = "0.2"
num_cpus = "1.17.0"
@@ -144,7 +141,6 @@ objc2-core-graphics = "0.3.2"
objc2-core-text = "0.3.2"
ocb3 = "0.1.0"
openxr = "0.20"
paint_api = { package = "servo-paint-api", path = "components/shared/paint" }
p256 = { version = "0.13", features = ["ecdh"] }
p384 = { version = "0.13", features = ["ecdh"] }
p521 = { version = "0.13", features = ["ecdh"] }
@@ -154,51 +150,46 @@ percent-encoding = "2.3"
pkcs8 = { version = "0.10", features = ["rand_core"] }
postcard = { version = "1.1.3", default-features = false, features = ["use-std"] }
proc-macro2 = "1"
profile_traits = { package = "servo-profile-traits", path = "components/shared/profile" }
quote = "1"
rand = "0.9"
rangemap = "1.7.1"
raw-window-handle = "0.6"
rayon = "1"
read-fonts = "0.35.0"
regex = "1.12"
resvg = "0.45.0"
rsa = { version = "0.9.10", features = ["sha1", "sha2"] }
rustc-hash = "2.1.1"
rustc-hash = "2.1.2"
rustls = { version = "0.23", default-features = false, features = ["logging", "std", "tls12"] }
rustls-pki-types = "1.14"
rustls-platform-verifier = "0.6.2"
script_traits = { package = "servo-script-traits", path = "components/shared/script" }
sea-query = { version = "1.0.0-rc.31", default-features = false, features = ["backend-sqlite", "derive"] }
sea-query-rusqlite = { version = "0.8.0-rc.15" }
rustls-platform-verifier = "0.7.0"
sea-query = { version = "=1.0.0-rc.31", default-features = false, features = ["backend-sqlite", "derive"] }
sea-query-rusqlite = { version = "=0.8.0-rc.15" }
sec1 = "0.7"
selectors = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
selectors = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
serde = "1.0.228"
serde_bytes = "0.11"
serde_core = "1.0.226"
serde_json = "1.0"
servo-media = { path = "components/media/servo-media" }
servo-media-dummy = { path = "components/media/backends/dummy" }
servo-media-gstreamer = { path = "components/media/backends/gstreamer" }
servo-tracing = { path = "components/servo_tracing" }
servo_arc = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
servo_arc = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
sha1 = "0.10"
sha2 = "0.10"
sha3 = "0.10"
speexdsp-resampler = "0.1.0"
skrifa = "0.37.0"
smallvec = { version = "1.15", features = ["serde", "union"] }
storage_traits = { package = "servo-storage-traits", path = "components/shared/storage" }
string_cache = "0.9"
strum = { version = "0.27", features = ["derive"] }
stylo = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
stylo_atoms = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
stylo_dom = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
stylo_malloc_size_of = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
stylo_static_prefs = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
stylo_traits = { git = "https://github.com/servo/stylo", rev = "2f131eb1909c6193a7cfae22e49f288fe9df4fbb" }
surfman = { version = "0.11.0", features = ["chains"] }
strum = { version = "0.28", features = ["derive"] }
stylo = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
stylo_atoms = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
stylo_dom = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
stylo_malloc_size_of = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
stylo_static_prefs = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
stylo_traits = { git = "https://github.com/servo/stylo", rev = "a556f4cbd15fc289039261661b049a5dc845cd80" }
surfman = { version = "0.12.0", features = ["chains"] }
syn = { version = "2", default-features = false, features = ["clone-impls", "derive", "parsing"] }
synstructure = "0.13"
taffy = { version = "0.9.2", default-features = false, features = ["calc", "detailed_layout_info", "grid", "std"] }
taffy = { version = "0.10.1", default-features = false, features = ["calc", "detailed_layout_info", "grid", "std"] }
tendril = { version = "0.5", features = ["encoding_rs"] }
tikv-jemalloc-sys = "0.6.1"
tikv-jemallocator = "0.6.1"
@@ -210,35 +201,109 @@ tokio-util = { version = "0.7.18", default-features = false }
tower = { version = "0.5", default-features = false, features = ["util"] }
tracing = "0.1.44"
tracing-perfetto = "0.1.5"
tracing-subscriber = "0.3.22"
tungstenite = "0.28"
tracing-subscriber = "0.3.23"
tungstenite = "0.29"
unicode-bidi = "0.3.18"
unicode_categories = "0.1.1"
unicode-properties = { version = "0.1.4", features = ["emoji"] }
unicode-script = "0.5"
unicode-segmentation = "1.12.0"
unicode-segmentation = "1.13.2"
url = "2.5"
urlpattern = "0.3"
utf-8 = "0.7"
uuid = { version = "1.21.0", features = ["v4", "v5"] }
uuid = { version = "1.23.1", features = ["v4", "v5"] }
vello = "0.6"
vello_cpu = "0.0.4"
webdriver = "0.53.0"
webgpu_traits = { package = "servo-webgpu-traits", path = "components/shared/webgpu" }
webdriver = { version = "0.53.0", default-features = false }
webpki-roots = "1.0"
webrender = { version = "0.68", features = ["capture"] }
webrender_api = "0.68"
webxr-api = { package = "servo-webxr-api", path = "components/shared/webxr" }
web_atoms = "0.2"
wgpu-core = "26"
wgpu-types = "26"
winapi = "0.3"
windows-sys = "0.61"
winit = "0.30.12"
winit = "0.30.13"
wio = "0.2"
wr_malloc_size_of = "0.2.2"
x25519-dalek = { version = "2.0.1", features = ["static_secrets"] }
xi-unicode = "0.3.0"
xml5ever = "0.38"
xpath = { package = "servo-xpath", path = "components/xpath" }
xml5ever = "0.39"
yuv = { version = "0.8.13", features = ["rayon"] }
############################################################################################
## Workspace-local dependencies
############################################################################################
# All local path dependencies in the servo workspace, that use the workspace version, should
# be listed here, between the `Begin` and `End` comments, so that we can easily find and
# update the version requirements when bumping the workspace version.
# Begin workspace-version dependencies - Don't change this comment, we grep for it in scripts!
deny_public_fields = { package = "servo-deny-public-fields", version = "0.1.0", path = "components/deny_public_fields" }
devtools = { package = "servo-devtools", version = "0.1.0", path = "components/devtools" }
devtools_traits = { package = "servo-devtools-traits", version = "0.1.0", path = "components/shared/devtools" }
dom_struct = { package = "servo-dom-struct", version = "0.1.0", path = "components/dom_struct" }
embedder_traits = { package = "servo-embedder-traits", version = "0.1.0", path = "components/shared/embedder" }
fonts = { package = "servo-fonts", version = "0.1.0", path = "components/fonts" }
fonts_traits = { package = "servo-fonts-traits", version = "0.1.0", path = "components/shared/fonts" }
hyper_serde = { package = "servo-hyper-serde", version = "0.1.0", path = "components/hyper_serde" }
jstraceable_derive = { package = "servo-jstraceable-derive", version = "0.1.0", path = "components/jstraceable_derive" }
layout = { package = "servo-layout", version = "0.1.0", path = "components/layout" }
layout_api = { package = "servo-layout-api", version = "0.1.0", path = "components/shared/layout" }
malloc_size_of = { package = "servo-malloc-size-of", version = "0.1.0", path = "components/malloc_size_of" }
media = { package = "servo-media-thread", version = "0.1.0", path = "components/media/media-thread" }
metrics = { package = "servo-metrics", version = "0.1.0", path = "components/metrics" }
net = { package = "servo-net", version = "0.1.0", path = "components/net" }
net_traits = { package = "servo-net-traits", version = "0.1.0", path = "components/shared/net" }
paint = { package = "servo-paint", version = "0.1.0", path = "components/paint" }
paint_api = { package = "servo-paint-api", version = "0.1.0", path = "components/shared/paint" }
pixels = { package = "servo-pixels", version = "0.1.0", path = "components/pixels" }
profile = { package = "servo-profile", version = "0.1.0", path = "components/profile" }
profile_traits = { package = "servo-profile-traits", version = "0.1.0", path = "components/shared/profile" }
script = { package = "servo-script", version = "0.1.0", path = "components/script" }
script_bindings = { package = "servo-script-bindings", version = "0.1.0", path = "components/script_bindings" }
script_traits = { package = "servo-script-traits", version = "0.1.0", path = "components/shared/script" }
servo = { version = "0.1.0", path = "components/servo", default-features = false }
servo-allocator = { version = "0.1.0", path = "components/allocator" }
servo-background-hang-monitor = { version = "0.1.0", path = "components/background_hang_monitor" }
servo-background-hang-monitor-api = { version = "0.1.0", path = "components/shared/background_hang_monitor" }
servo-base = { version = "0.1.0", path = "components/shared/base" }
servo-bluetooth = { version = "0.1.0", path = "components/bluetooth" }
servo-bluetooth-traits = { version = "0.1.0", path = "components/shared/bluetooth" }
servo-canvas = { version = "0.1.0", path = "components/canvas" }
servo-canvas-traits = { version = "0.1.0", path = "components/shared/canvas" }
servo-config = { version = "0.1.0", path = "components/config" }
servo-config-macro = { version = "0.1.0", path = "components/config/macro" }
servo-constellation = { version = "0.1.0", path = "components/constellation" }
servo-constellation-traits = { version = "0.1.0", path = "components/shared/constellation" }
servo-default-resources = { version = "0.1.0", path = "components/default-resources" }
servo-geometry = { version = "0.1.0", path = "components/geometry" }
servo-media = { version = "0.1.0", path = "components/media/servo-media" }
servo-media-audio = { version = "0.1.0", path = "components/media/audio" }
servo-media-auto = { version = "0.1.0", path = "components/media/backends/auto" }
servo-media-derive = { version = "0.1.0", path = "components/media/servo-media-derive" }
servo-media-dummy = { version = "0.1.0", path = "components/media/backends/dummy" }
servo-media-gstreamer = { version = "0.1.0", path = "components/media/backends/gstreamer" }
servo-media-gstreamer-render = { version = "0.1.0", path = "components/media/backends/gstreamer/render" }
servo-media-gstreamer-render-android = { version = "0.1.0", path = "components/media/backends/gstreamer/render-android" }
servo-media-gstreamer-render-unix = { version = "0.1.0", path = "components/media/backends/gstreamer/render-unix" }
servo-media-ohos = { version = "0.1.0", path = "components/media/backends/ohos" }
servo-media-player = { version = "0.1.0", path = "components/media/player" }
servo-media-streams = { version = "0.1.0", path = "components/media/streams" }
servo-media-traits = { version = "0.1.0", path = "components/media/traits" }
servo-media-webrtc = { version = "0.1.0", path = "components/media/webrtc" }
servo-tracing = { version = "0.1.0", path = "components/servo_tracing" }
servo-url = { version = "0.1.0", path = "components/url" }
servo-wakelock = { version = "0.1.0", path = "components/wakelock" }
storage = { package = "servo-storage", version = "0.1.0", path = "components/storage" }
storage_traits = { package = "servo-storage-traits", version = "0.1.0", path = "components/shared/storage" }
timers = { package = "servo-timers", version = "0.1.0", path = "components/timers" }
webdriver_server = { package = "servo-webdriver-server", version = "0.1.0", path = "components/webdriver_server" }
webgl = { package = "servo-webgl", version = "0.1.0", path = "components/webgl", default-features = false }
webgpu = { package = "servo-webgpu", version = "0.1.0", path = "components/webgpu" }
webgpu_traits = { package = "servo-webgpu-traits", version = "0.1.0", path = "components/shared/webgpu" }
webxr = { package = "servo-webxr", version = "0.1.0", path = "components/webxr" }
webxr-api = { package = "servo-webxr-api", version = "0.1.0", path = "components/shared/webxr" }
xpath = { package = "servo-xpath", version = "0.1.0", path = "components/xpath" }
# End workspace-version dependencies - Don't change this comment, we grep for it in scripts!
# RSA key generation could be very slow without compilation
# optimizations, in development mode. Without optimizations, WPT might
@@ -306,16 +371,19 @@ codegen-units = 1
# xml5ever = { path = "../html5ever/xml5ever" }
# tendril = { path = "../html5ever/tendril" }
#
# For WebRender:
#
# webrender = { path = "../webrender/webrender" }
# webrender_api = { path = "../webrender/webrender_api" }
# wr_malloc_size_of = { path = "../webrender/wr_malloc_size_of" }
#
# Or for mozjs:
#
# mozjs = { path = "../mozjs/mozjs" }
# mozjs_sys = { path = "../mozjs/mozjs-sys" }
#
# Pending egui bumping their accesskit version: https://github.com/emilk/egui/pull/7850
# This is only used in servoshell.
# TODO: When these are no longer needed remove the exception in deny.toml as well.
egui = { git = "https://github.com/emilk/egui.git", rev = "5d8f393335e051785b4fd3af9ef92eda5b61177f" }
egui-winit = { git = "https://github.com/emilk/egui.git", rev = "5d8f393335e051785b4fd3af9ef92eda5b61177f" }
# Or for CSP crate:
# content-security-policy = { path = "../rust-content-security-policy" }
#
# Or for Stylo:
#
@@ -329,17 +397,8 @@ egui-winit = { git = "https://github.com/emilk/egui.git", rev = "5d8f393335e0517
# stylo_static_prefs = { path = "../stylo/stylo_static_prefs" }
# stylo_traits = { path = "../stylo/style_traits" }
#
# Or for WebRender:
#
# [patch."https://github.com/servo/webrender"]
# webrender = { path = "../webrender/webrender" }
# webrender_api = { path = "../webrender/webrender_api" }
# wr_malloc_size_of = { path = "../webrender/wr_malloc_size_of" }
#
# Or for another Git dependency:
#
# [patch."https://github.com/servo/<repository>"]
# <crate> = { path = "/path/to/local/checkout" }
#
# [patch."https://github.com/servo/rust-content-security-policy"]
# content-security-policy = { path = "../rust-content-security-policy" }

View File

@@ -1,32 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleExecutable</key>
<string>servo</string>
<key>CFBundleGetInfoString</key>
<string>Servo</string>
<key>CFBundleIconFile</key>
<string>servo.icns</string>
<key>CFBundleIdentifier</key>
<string>org.servo.Servo</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>Servo</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>0.0.6</string>
<key>NSHighResolutionCapable</key>
<true/>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSQuitAlwaysKeepsWindows</key>
<false/>
<key>CFBundleSupportedPlatforms</key>
<array>
<string>MacOSX</string>
</array>
</dict>
</plist>

View File

@@ -1,4 +1,5 @@
*Describe the changes that this pull request makes here. This will be the commit message.*
*Describe the changes that this pull request makes here. This will be the commit message
and it should go at the top of the pull request.*
Testing: *Describe how this pull request is tested or why it doesn't require tests*
Fixes: *Link to an issue this pull requests fixes or remove this line if there is no issue*
Testing: *Describe the new automated tests that cover this change or explain why it doesn't require tests.*
Fixes: *Link to an issue this pull request fixes or remove this line if there is no issue.*

View File

@@ -1,4 +1,3 @@
# Security Policy
Given that Servo does not yet have customers or products, we are comfortable accepting the security related issues as [GitHub security reports](https://github.com/servo/servo/security/advisories/new) for now.
Please submit security related issues as [GitHub security reports](https://github.com/servo/servo/security/advisories/new).

View File

@@ -6,6 +6,8 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
path = "lib.rs"

View File

@@ -6,23 +6,25 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "background_hang_monitor"
name = "servo_background_hang_monitor"
path = "lib.rs"
test = false
doctest = false
[dependencies]
background_hang_monitor_api = { workspace = true }
backtrace = { workspace = true }
base = { workspace = true }
crossbeam-channel = { workspace = true }
libc = { workspace = true }
log = { workspace = true }
rustc-demangle = { version = "0.1", optional = true }
rustc-hash = { workspace = true }
serde_json = { workspace = true }
servo-background-hang-monitor-api = { workspace = true }
servo-base = { workspace = true }
[target.'cfg(target_os = "macos")'.dependencies]
mach2 = { workspace = true, optional = true }

View File

@@ -11,10 +11,10 @@ use background_hang_monitor_api::{
BackgroundHangMonitorExitSignal, BackgroundHangMonitorRegister, HangAlert, HangAnnotation,
HangMonitorAlert, MonitoredComponentId,
};
use base::generic_channel::{GenericReceiver, GenericSender, RoutedReceiver};
use crossbeam_channel::{Receiver, Sender, after, never, select, unbounded};
use log::{error, warn};
use rustc_hash::FxHashMap;
use servo_base::generic_channel::{GenericReceiver, GenericSender, RoutedReceiver};
use crate::SamplerImpl;
use crate::sampler::{NativeStack, Sampler};

View File

@@ -37,6 +37,7 @@ pub use self::background_hang_monitor::*;
)
),
all(target_os = "windows", target_arch = "aarch64"),
target_os = "freebsd"
))]
pub(crate) use crate::sampler::DummySampler as SamplerImpl;
#[cfg(all(

View File

@@ -9,13 +9,13 @@ use std::sync::{Arc, Mutex};
use std::thread;
use std::time::Duration;
use background_hang_monitor::HangMonitorRegister;
use background_hang_monitor_api::{
BackgroundHangMonitorControlMsg, BackgroundHangMonitorExitSignal, HangAlert, HangAnnotation,
HangMonitorAlert, MonitoredComponentId, MonitoredComponentType, ScriptHangAnnotation,
};
use base::generic_channel;
use base::id::TEST_SCRIPT_EVENT_LOOP_ID;
use servo_background_hang_monitor::HangMonitorRegister;
use servo_base::generic_channel;
use servo_base::id::TEST_SCRIPT_EVENT_LOOP_ID;
static SERIAL: Mutex<()> = Mutex::new(());

View File

@@ -6,32 +6,28 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "bluetooth"
name = "servo_bluetooth"
path = "lib.rs"
[dependencies]
base = { workspace = true }
bitflags = { workspace = true }
bluetooth_traits = { workspace = true }
blurmock = { version = "0.1.2", optional = true }
btleplug = { version = "0.12", optional = true }
embedder_traits = { workspace = true }
futures = { workspace = true, features = ["executor"] }
log = { workspace = true }
rand = { workspace = true }
servo_config = { package = "servo-config", path = "../config" }
servo-base = { workspace = true }
servo-bluetooth-traits = { workspace = true }
servo-config = { workspace = true }
tokio = { workspace = true, features = ["rt", "time", "sync"], optional = true }
uuid = { workspace = true }
[target.'cfg(target_os = "linux")'.dependencies]
blurz = { version = "0.3", optional = true }
[target.'cfg(target_os = "android")'.dependencies]
blurdroid = { version = "0.1.2", optional = true }
[target.'cfg(target_os = "macos")'.dependencies]
blurmac = { path = "../../third_party/blurmac", optional = true }
[features]
default = ["bluetooth-test"]
bluetooth-test = ["blurmock"]
native-bluetooth = ["bluetooth-test", "blurdroid", "blurmac", "blurz"]
native-bluetooth = ["bluetooth-test", "btleplug", "tokio"]

View File

@@ -5,99 +5,81 @@
use std::error::Error;
use std::sync::Arc;
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
use blurdroid::bluetooth_adapter::Adapter as BluetoothAdapterAndroid;
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
use blurdroid::bluetooth_device::Device as BluetoothDeviceAndroid;
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
use blurdroid::bluetooth_discovery_session::DiscoverySession as BluetoothDiscoverySessionAndroid;
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
use blurmac::BluetoothAdapter as BluetoothAdapterMac;
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
use blurmac::BluetoothDevice as BluetoothDeviceMac;
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
use blurmac::BluetoothDiscoverySession as BluetoothDiscoverySessionMac;
#[cfg(feature = "bluetooth-test")]
use blurmock::fake_adapter::FakeBluetoothAdapter;
#[cfg(feature = "bluetooth-test")]
use blurmock::fake_device::FakeBluetoothDevice;
#[cfg(feature = "bluetooth-test")]
use blurmock::fake_discovery_session::FakeBluetoothDiscoverySession;
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
use blurz::bluetooth_adapter::BluetoothAdapter as BluetoothAdapterBluez;
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
use blurz::bluetooth_device::BluetoothDevice as BluetoothDeviceBluez;
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
use blurz::bluetooth_discovery_session::BluetoothDiscoverySession as BluetoothDiscoverySessionBluez;
#[cfg(feature = "native-bluetooth")]
use btleplug::api::{Central, CentralState, Manager};
#[cfg(feature = "native-bluetooth")]
use btleplug::platform::{Adapter, Manager as PlatformManager};
use super::bluetooth::{BluetoothDevice, BluetoothDiscoverySession};
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
use super::empty::BluetoothDevice as BluetoothDeviceEmpty;
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
use super::empty::BluetoothDiscoverySession as BluetoothDiscoverySessionEmpty;
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
use super::empty::EmptyAdapter as BluetoothAdapterEmpty;
use super::macros::get_inner_and_call;
#[cfg(feature = "bluetooth-test")]
use super::macros::get_inner_and_call_test_func;
use crate::macros::get_inner_and_call_test_func;
#[cfg(feature = "native-bluetooth")]
#[derive(Clone, Debug)]
pub struct BtleplugAdapter {
adapter: Adapter,
}
#[cfg(feature = "native-bluetooth")]
impl BtleplugAdapter {
pub async fn new() -> Result<Self, Box<dyn Error>> {
let manager = PlatformManager::new().await?;
let adapters = manager.adapters().await?;
let adapter = adapters
.into_iter()
.next()
.ok_or_else(|| btleplug::Error::NoAdapterAvailable)?;
Ok(BtleplugAdapter { adapter })
}
pub async fn get_address(&self) -> Result<String, Box<dyn Error>> {
Ok(self.adapter.adapter_info().await?)
}
pub async fn is_powered(&self) -> Result<bool, Box<dyn Error>> {
let state = self.adapter.adapter_state().await?;
Ok(state == CentralState::PoweredOn)
}
pub async fn get_devices(&self) -> Result<Vec<BluetoothDevice>, Box<dyn Error>> {
let peripherals = self.adapter.peripherals().await?;
Ok(peripherals
.into_iter()
.map(|p| BluetoothDevice::Btleplug(super::bluetooth::BtleplugDevice { peripheral: p }))
.collect())
}
pub fn create_discovery_session(&self) -> Result<BluetoothDiscoverySession, Box<dyn Error>> {
Ok(BluetoothDiscoverySession::Btleplug(
super::bluetooth::BtleplugDiscoverySession {
adapter: self.adapter.clone(),
},
))
}
}
#[derive(Clone, Debug)]
pub enum BluetoothAdapter {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
Bluez(Arc<BluetoothAdapterBluez>),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
Android(Arc<BluetoothAdapterAndroid>),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
Mac(Arc<BluetoothAdapterMac>),
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
Empty(Arc<BluetoothAdapterEmpty>),
#[cfg(feature = "native-bluetooth")]
Btleplug(BtleplugAdapter),
#[cfg(feature = "bluetooth-test")]
Mock(Arc<FakeBluetoothAdapter>),
}
impl BluetoothAdapter {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
pub fn new() -> Result<BluetoothAdapter, Box<dyn Error>> {
let bluez_adapter = BluetoothAdapterBluez::init()?;
Ok(Self::Bluez(Arc::new(bluez_adapter)))
#[cfg(feature = "native-bluetooth")]
pub async fn new() -> Result<BluetoothAdapter, Box<dyn Error>> {
Ok(Self::Btleplug(BtleplugAdapter::new().await?))
}
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
#[cfg(not(feature = "native-bluetooth"))]
pub fn new() -> Result<BluetoothAdapter, Box<dyn Error>> {
let blurdroid_adapter = BluetoothAdapterAndroid::get_adapter()?;
Ok(Self::Android(Arc::new(blurdroid_adapter)))
}
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
pub fn new() -> Result<BluetoothAdapter, Box<dyn Error>> {
let mac_adapter = BluetoothAdapterMac::init()?;
Ok(Self::Mac(Arc::new(mac_adapter)))
}
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
pub fn new() -> Result<BluetoothAdapter, Box<dyn Error>> {
let adapter = BluetoothAdapterEmpty::init()?;
Ok(Self::Empty(Arc::new(adapter)))
Err(Box::from("Bluetooth not supported on this platform"))
}
#[cfg(feature = "bluetooth-test")]
@@ -105,62 +87,30 @@ impl BluetoothAdapter {
Ok(Self::Mock(FakeBluetoothAdapter::new_empty()))
}
pub fn get_id(&self) -> String {
get_inner_and_call!(self, BluetoothAdapter, get_id)
pub async fn get_address(&self) -> Result<String, Box<dyn Error>> {
match self {
#[cfg(feature = "native-bluetooth")]
Self::Btleplug(inner) => inner.get_address().await,
#[cfg(feature = "bluetooth-test")]
Self::Mock(inner) => inner.get_address(),
}
}
pub fn get_devices(&self) -> Result<Vec<BluetoothDevice>, Box<dyn Error>> {
pub async fn is_powered(&self) -> Result<bool, Box<dyn Error>> {
match self {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
BluetoothAdapter::Bluez(inner) => {
let device_list = inner.get_device_list()?;
Ok(device_list
.into_iter()
.map(|device| BluetoothDevice::Bluez(BluetoothDeviceBluez::new(device).into()))
.collect())
},
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
BluetoothAdapter::Android(inner) => {
let device_list = inner.get_device_list()?;
Ok(device_list
.into_iter()
.map(|device| {
BluetoothDevice::Android(BluetoothDeviceAndroid::new_empty(
self.0.clone(),
device,
))
})
.collect())
},
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
BluetoothAdapter::Mac(inner) => {
let device_list = inner.get_device_list()?;
Ok(device_list
.into_iter()
.map(|device| {
BluetoothDevice::Mac(Arc::new(BluetoothDeviceMac::new(
inner.clone(),
device,
)))
})
.collect())
},
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
BluetoothAdapter::Empty(inner) => {
let device_list = inner.get_device_list()?;
Ok(device_list
.into_iter()
.map(|device| {
BluetoothDevice::Empty(Arc::new(BluetoothDeviceEmpty::new(device)))
})
.collect())
},
#[cfg(feature = "native-bluetooth")]
Self::Btleplug(inner) => inner.is_powered().await,
#[cfg(feature = "bluetooth-test")]
BluetoothAdapter::Mock(inner) => {
Self::Mock(inner) => inner.is_powered(),
}
}
pub async fn get_devices(&self) -> Result<Vec<BluetoothDevice>, Box<dyn Error>> {
match self {
#[cfg(feature = "native-bluetooth")]
Self::Btleplug(inner) => inner.get_devices().await,
#[cfg(feature = "bluetooth-test")]
Self::Mock(inner) => {
let device_list = inner.get_device_list()?;
Ok(device_list
.into_iter()
@@ -172,157 +122,34 @@ impl BluetoothAdapter {
}
}
pub fn get_device(&self, address: String) -> Result<Option<BluetoothDevice>, Box<dyn Error>> {
let devices = self.get_devices()?;
for device in devices {
if device.get_address()? == address {
return Ok(Some(device));
}
pub fn create_discovery_session(&self) -> Result<BluetoothDiscoverySession, Box<dyn Error>> {
match self {
#[cfg(feature = "native-bluetooth")]
Self::Btleplug(inner) => inner.create_discovery_session(),
#[cfg(feature = "bluetooth-test")]
Self::Mock(inner) => Ok(BluetoothDiscoverySession::Mock(Arc::new(
FakeBluetoothDiscoverySession::create_session(inner.clone())?,
))),
}
Ok(None)
}
pub fn create_mock_device(&self, _device: String) -> Result<BluetoothDevice, Box<dyn Error>> {
match self {
#[cfg(feature = "bluetooth-test")]
BluetoothAdapter::Mock(inner) => Ok(BluetoothDevice::Mock(
FakeBluetoothDevice::new_empty(inner.clone(), _device),
)),
_ => Err(Box::from(
"Error! Test functions are not supported on real devices!",
)),
Self::Mock(inner) => Ok(BluetoothDevice::Mock(FakeBluetoothDevice::new_empty(
inner.clone(),
_device,
))),
#[cfg(feature = "native-bluetooth")]
_ => Err(Box::from("Test functions not supported on real devices")),
}
}
pub fn create_discovery_session(&self) -> Result<BluetoothDiscoverySession, Box<dyn Error>> {
let discovery_session = match self {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
#[allow(clippy::arc_with_non_send_sync)] // Problem with underlying library
BluetoothAdapter::Bluez(inner) => BluetoothDiscoverySession::Bluez(Arc::new(
BluetoothDiscoverySessionBluez::create_session(inner.get_id())?,
)),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
BluetoothAdapter::Android(inner) => BluetoothDiscoverySession::Android(Arc::new(
BluetoothDiscoverySessionAndroid::create_session(inner.clone())?,
)),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
BluetoothAdapter::Mac(_) => {
BluetoothDiscoverySession::Mac(Arc::new(BluetoothDiscoverySessionMac {}))
},
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
BluetoothAdapter::Empty(_) => {
BluetoothDiscoverySession::Empty(Arc::new(BluetoothDiscoverySessionEmpty {}))
},
#[cfg(feature = "bluetooth-test")]
BluetoothAdapter::Mock(inner) => BluetoothDiscoverySession::Mock(Arc::new(
FakeBluetoothDiscoverySession::create_session(inner.clone())?,
)),
};
Ok(discovery_session)
}
pub fn get_address(&self) -> Result<String, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_address)
}
pub fn get_name(&self) -> Result<String, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_name)
}
pub fn get_alias(&self) -> Result<String, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_alias)
}
pub fn get_class(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_class)
}
pub fn is_powered(&self) -> Result<bool, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, is_powered)
}
pub fn is_discoverable(&self) -> Result<bool, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, is_discoverable)
}
pub fn is_pairable(&self) -> Result<bool, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, is_pairable)
}
pub fn get_pairable_timeout(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_pairable_timeout)
}
pub fn get_discoverable_timeout(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_discoverable_timeout)
}
pub fn is_discovering(&self) -> Result<bool, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, is_discovering)
}
pub fn get_uuids(&self) -> Result<Vec<String>, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_uuids)
}
pub fn get_vendor_id_source(&self) -> Result<String, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_vendor_id_source)
}
pub fn get_vendor_id(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_vendor_id)
}
pub fn get_product_id(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_product_id)
}
pub fn get_device_id(&self) -> Result<u32, Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_device_id)
}
pub fn get_modalias(&self) -> Result<(String, u32, u32, u32), Box<dyn Error>> {
get_inner_and_call!(self, BluetoothAdapter, get_modalias)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_id(&self, id: String) -> Result<(), Box<dyn Error>> {
match self {
#[cfg(feature = "bluetooth-test")]
BluetoothAdapter::Mock(inner) => {
inner.set_id(id);
Ok(())
},
_ => Err(Box::from(
"Error! Test functions are not supported on real devices!",
)),
}
}
#[cfg(feature = "bluetooth-test")]
pub fn set_address(&self, address: String) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_address, address)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_name(&self, name: String) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_name, name)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_alias(&self, alias: String) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_alias, alias)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_class(&self, class: u32) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_class, class)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_powered(&self, powered: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_powered, powered)
@@ -342,64 +169,4 @@ impl BluetoothAdapter {
pub fn set_discoverable(&self, discoverable: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_discoverable, discoverable)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_pairable(&self, pairable: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_pairable, pairable)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_pairable_timeout(&self, timeout: u32) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_pairable_timeout, timeout)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_can_start_discovery(&self, can_start_discovery: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(
self,
BluetoothAdapter,
set_can_start_discovery,
can_start_discovery
)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_discoverable_timeout(&self, timeout: u32) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_discoverable_timeout, timeout)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_discovering(&self, discovering: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_discovering, discovering)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_can_stop_discovery(&self, can_stop_discovery: bool) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(
self,
BluetoothAdapter,
set_can_stop_discovery,
can_stop_discovery
)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_uuids(&self, uuids: Vec<String>) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_uuids, uuids)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_modalias(&self, modalias: String) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_modalias, modalias)
}
#[cfg(feature = "bluetooth-test")]
pub fn get_ad_datas(&self) -> Result<Vec<String>, Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, get_ad_datas)
}
#[cfg(feature = "bluetooth-test")]
pub fn set_ad_datas(&self, ad_datas: Vec<String>) -> Result<(), Box<dyn Error>> {
get_inner_and_call_test_func!(self, BluetoothAdapter, set_ad_datas, ad_datas)
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,377 +0,0 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use std::collections::HashMap;
use std::error::Error;
use std::sync::Arc;
const NOT_SUPPORTED_ERROR: &str = "Error! Not supported platform!";
#[derive(Clone, Debug)]
pub struct EmptyAdapter {}
impl EmptyAdapter {
pub fn init() -> Result<EmptyAdapter, Box<dyn Error>> {
Ok(EmptyAdapter::new())
}
fn new() -> EmptyAdapter {
EmptyAdapter {}
}
pub fn get_id(&self) -> String {
String::new()
}
pub fn get_device_list(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_address(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_name(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_alias(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_alias(&self, _value: String) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_class(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_powered(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_powered(&self, _value: bool) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_discoverable(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_discoverable(&self, _value: bool) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_pairable(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_pairable(&self, _value: bool) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_pairable_timeout(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_pairable_timeout(&self, _value: u32) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_discoverable_timeout(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_discoverable_timeout(&self, _value: u32) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_discovering(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_uuids(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_vendor_id_source(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_vendor_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_product_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_device_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_modalias(&self) -> Result<(String, u32, u32, u32), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}
#[derive(Clone, Debug)]
pub struct BluetoothDiscoverySession {}
impl BluetoothDiscoverySession {
pub fn create_session(
_adapter: Arc<EmptyAdapter>,
) -> Result<BluetoothDiscoverySession, Box<dyn Error>> {
Ok(BluetoothDiscoverySession {})
}
pub fn start_discovery(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn stop_discovery(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}
#[derive(Clone, Debug)]
pub struct BluetoothDevice {}
impl BluetoothDevice {
pub fn new(_device: String) -> BluetoothDevice {
BluetoothDevice {}
}
pub fn get_id(&self) -> String {
String::new()
}
pub fn get_address(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_name(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_icon(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_class(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_appearance(&self) -> Result<u16, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_uuids(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_paired(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_connected(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_trusted(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_blocked(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_alias(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn set_alias(&self, _value: String) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_legacy_pairing(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_vendor_id_source(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_vendor_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_product_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_device_id(&self) -> Result<u32, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_modalias(&self) -> Result<(String, u32, u32, u32), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_rssi(&self) -> Result<i16, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_tx_power(&self) -> Result<i16, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_manufacturer_data(&self) -> Result<HashMap<u16, Vec<u8>>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_service_data(&self) -> Result<HashMap<String, Vec<u8>>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_gatt_services(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn connect(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn disconnect(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn connect_profile(&self, _uuid: String) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn disconnect_profile(&self, _uuid: String) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn pair(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn cancel_pairing(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}
#[derive(Clone, Debug)]
pub struct BluetoothGATTService {}
impl BluetoothGATTService {
pub fn new(_service: String) -> BluetoothGATTService {
BluetoothGATTService {}
}
pub fn get_id(&self) -> String {
String::new()
}
pub fn get_uuid(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_primary(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_includes(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_gatt_characteristics(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}
#[derive(Clone, Debug)]
pub struct BluetoothGATTCharacteristic {}
impl BluetoothGATTCharacteristic {
pub fn new(_characteristic: String) -> BluetoothGATTCharacteristic {
BluetoothGATTCharacteristic {}
}
pub fn get_id(&self) -> String {
String::new()
}
pub fn get_uuid(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_value(&self) -> Result<Vec<u8>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn is_notifying(&self) -> Result<bool, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_flags(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_gatt_descriptors(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn read_value(&self) -> Result<Vec<u8>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn write_value(&self, _values: Vec<u8>) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn start_notify(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn stop_notify(&self) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}
#[derive(Clone, Debug)]
pub struct BluetoothGATTDescriptor {}
impl BluetoothGATTDescriptor {
pub fn new(_descriptor: String) -> BluetoothGATTDescriptor {
BluetoothGATTDescriptor {}
}
pub fn get_id(&self) -> String {
String::new()
}
pub fn get_uuid(&self) -> Result<String, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_value(&self) -> Result<Vec<u8>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn get_flags(&self) -> Result<Vec<String>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn read_value(&self) -> Result<Vec<u8>, Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
pub fn write_value(&self, _values: Vec<u8>) -> Result<(), Box<dyn Error>> {
Err(Box::from(NOT_SUPPORTED_ERROR))
}
}

View File

@@ -4,12 +4,6 @@
pub mod adapter;
pub mod bluetooth;
#[cfg(not(any(
all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth")
)))]
mod empty;
mod macros;
pub mod test;
@@ -19,21 +13,23 @@ use std::string::String;
use std::thread;
use std::time::Duration;
use base::generic_channel::{self, GenericReceiver, GenericSender};
use base::id::WebViewId;
use bitflags::bitflags;
use bluetooth_traits::blocklist::{Blocklist, uuid_is_blocklisted};
use bluetooth_traits::scanfilter::{
use embedder_traits::{BluetoothDeviceDescription, EmbedderMsg, EmbedderProxy};
use log::warn;
use rand::{self, Rng};
#[cfg(not(feature = "native-bluetooth"))]
use servo_base::generic_channel::GenericReceiver;
use servo_base::generic_channel::{self, GenericSender};
use servo_base::id::WebViewId;
use servo_bluetooth_traits::blocklist::{Blocklist, uuid_is_blocklisted};
use servo_bluetooth_traits::scanfilter::{
BluetoothScanfilter, BluetoothScanfilterSequence, RequestDeviceoptions,
};
use bluetooth_traits::{
use servo_bluetooth_traits::{
BluetoothCharacteristicMsg, BluetoothDescriptorMsg, BluetoothDeviceMsg, BluetoothError,
BluetoothRequest, BluetoothResponse, BluetoothResponseResult, BluetoothResult,
BluetoothServiceMsg, GATTType,
};
use embedder_traits::{EmbedderMsg, EmbedderProxy};
use log::warn;
use rand::{self, Rng};
use servo_config::pref;
use crate::bluetooth::{
@@ -75,6 +71,47 @@ pub trait BluetoothThreadFactory {
}
impl BluetoothThreadFactory for GenericSender<BluetoothRequest> {
#[cfg(feature = "native-bluetooth")]
fn new(embedder_proxy: EmbedderProxy) -> GenericSender<BluetoothRequest> {
let (sender, receiver) = generic_channel::channel().unwrap();
thread::Builder::new()
.name("Bluetooth".to_owned())
.spawn(move || {
let runtime = tokio::runtime::Builder::new_current_thread()
.enable_all()
.build()
.expect("Failed to create bluetooth tokio runtime");
let adapter = runtime.block_on(async {
if pref!(dom_bluetooth_enabled) {
BluetoothAdapter::new().await.ok()
} else {
BluetoothAdapter::new_mock().ok()
}
});
// Bridge: GenericReceiver -> tokio mpsc channel
let (async_sender, async_receiver) = tokio::sync::mpsc::unbounded_channel();
thread::Builder::new()
.name("BluetoothTokioBridge".to_owned())
.spawn(move || {
while let Ok(message) = receiver.recv() {
if async_sender.send(message).is_err() {
break;
}
}
})
.expect("BT Tokio Bridge thread spawning failed");
let mut manager = BluetoothManager::new(adapter, embedder_proxy);
runtime.block_on(manager.start(async_receiver));
})
.expect("Thread spawning failed");
sender
}
#[cfg(not(feature = "native-bluetooth"))]
fn new(embedder_proxy: EmbedderProxy) -> GenericSender<BluetoothRequest> {
let (sender, receiver) = generic_channel::channel().unwrap();
let adapter = if pref!(dom_bluetooth_enabled) {
@@ -86,7 +123,7 @@ impl BluetoothThreadFactory for GenericSender<BluetoothRequest> {
thread::Builder::new()
.name("Bluetooth".to_owned())
.spawn(move || {
BluetoothManager::new(receiver, adapter, embedder_proxy).start();
BluetoothManager::new(adapter, embedder_proxy).start_sync(receiver);
})
.expect("Thread spawning failed");
sender
@@ -94,21 +131,21 @@ impl BluetoothThreadFactory for GenericSender<BluetoothRequest> {
}
/// <https://webbluetoothcg.github.io/web-bluetooth/#matches-a-filter>
fn matches_filter(device: &BluetoothDevice, filter: &BluetoothScanfilter) -> bool {
async fn matches_filter(device: &BluetoothDevice, filter: &BluetoothScanfilter) -> bool {
if filter.is_empty_or_invalid() {
return false;
}
// Step 1.
if let Some(name) = filter.get_name() {
if device.get_name().ok() != Some(name.to_string()) {
if device.get_name().await.ok() != Some(name.to_string()) {
return false;
}
}
// Step 2.
if !filter.get_name_prefix().is_empty() {
if let Ok(device_name) = device.get_name() {
if let Ok(device_name) = device.get_name().await {
if !device_name.starts_with(filter.get_name_prefix()) {
return false;
}
@@ -119,7 +156,7 @@ fn matches_filter(device: &BluetoothDevice, filter: &BluetoothScanfilter) -> boo
// Step 3.
if !filter.get_services().is_empty() {
if let Ok(device_uuids) = device.get_uuids() {
if let Ok(device_uuids) = device.get_uuids().await {
for service in filter.get_services() {
if !device_uuids.iter().any(|x| x == service) {
return false;
@@ -130,7 +167,7 @@ fn matches_filter(device: &BluetoothDevice, filter: &BluetoothScanfilter) -> boo
// Step 4.
if let Some(manufacturer_data) = filter.get_manufacturer_data() {
let advertised_manufacturer_data = match device.get_manufacturer_data() {
let advertised_manufacturer_data = match device.get_manufacturer_data().await {
Ok(data) => data,
Err(_) => return false,
};
@@ -147,7 +184,7 @@ fn matches_filter(device: &BluetoothDevice, filter: &BluetoothScanfilter) -> boo
// Step 5.
if let Some(service_data) = filter.get_service_data() {
let advertised_service_data = match device.get_service_data() {
let advertised_service_data = match device.get_service_data().await {
Ok(data) => data,
Err(_) => return false,
};
@@ -185,12 +222,28 @@ fn data_filter_matches(data: &[u8], prefix: &[u8], mask: &[u8]) -> bool {
true
}
fn matches_filters(device: &BluetoothDevice, filters: &BluetoothScanfilterSequence) -> bool {
async fn matches_filters(device: &BluetoothDevice, filters: &BluetoothScanfilterSequence) -> bool {
if filters.has_empty_or_invalid_filter() {
return false;
}
for f in filters.iter() {
if matches_filter(device, f).await {
return true;
}
}
false
}
filters.iter().any(|f| matches_filter(device, f))
/// Async sleep that works in both tokio and non-tokio (mock) contexts.
async fn async_sleep(duration: Duration) {
#[cfg(feature = "native-bluetooth")]
{
tokio::time::sleep(duration).await;
}
#[cfg(not(feature = "native-bluetooth"))]
{
thread::sleep(duration);
}
}
fn is_mock_adapter(adapter: &BluetoothAdapter) -> bool {
@@ -198,7 +251,6 @@ fn is_mock_adapter(adapter: &BluetoothAdapter) -> bool {
}
pub struct BluetoothManager {
receiver: GenericReceiver<BluetoothRequest>,
adapter: Option<BluetoothAdapter>,
address_to_id: HashMap<String, String>,
service_to_device: HashMap<String, String>,
@@ -214,12 +266,10 @@ pub struct BluetoothManager {
impl BluetoothManager {
pub fn new(
receiver: GenericReceiver<BluetoothRequest>,
adapter: Option<BluetoothAdapter>,
embedder_proxy: EmbedderProxy,
) -> BluetoothManager {
BluetoothManager {
receiver,
adapter,
address_to_id: HashMap::new(),
service_to_device: HashMap::new(),
@@ -234,58 +284,82 @@ impl BluetoothManager {
}
}
fn start(&mut self) {
while let Ok(msg) = self.receiver.recv() {
match msg {
BluetoothRequest::RequestDevice(options, sender) => {
let _ = sender.send(self.request_device(options));
},
BluetoothRequest::GATTServerConnect(device_id, sender) => {
let _ = sender.send(self.gatt_server_connect(device_id));
},
BluetoothRequest::GATTServerDisconnect(device_id, sender) => {
let _ = sender.send(self.gatt_server_disconnect(device_id));
},
BluetoothRequest::GetGATTChildren(id, uuid, single, child_type, sender) => {
let _ = sender.send(self.get_gatt_children(id, uuid, single, child_type));
},
BluetoothRequest::ReadValue(id, sender) => {
let _ = sender.send(self.read_value(id));
},
BluetoothRequest::WriteValue(id, value, sender) => {
let _ = sender.send(self.write_value(id, value));
},
BluetoothRequest::EnableNotification(id, enable, sender) => {
let _ = sender.send(self.enable_notification(id, enable));
},
BluetoothRequest::WatchAdvertisements(id, sender) => {
let _ = sender.send(self.watch_advertisements(id));
},
BluetoothRequest::Test(data_set_name, sender) => {
let _ = sender.send(self.test(data_set_name));
},
BluetoothRequest::SetRepresentedToNull(
service_ids,
characteristic_ids,
descriptor_ids,
) => self.remove_ids_from_caches(service_ids, characteristic_ids, descriptor_ids),
BluetoothRequest::IsRepresentedDeviceNull(id, sender) => {
let _ = sender.send(!self.device_is_cached(&id));
},
BluetoothRequest::GetAvailability(sender) => {
let _ = sender.send(self.get_availability());
},
BluetoothRequest::MatchesFilter(id, filters, sender) => {
let _ = sender.send(self.device_matches_filter(&id, &filters));
},
BluetoothRequest::Exit => break,
/// Async message loop.
/// The tokio runtime is always active, so btleplug's background tasks run continuously.
#[cfg(feature = "native-bluetooth")]
async fn start(&mut self, mut rx: tokio::sync::mpsc::UnboundedReceiver<BluetoothRequest>) {
while let Some(msg) = rx.recv().await {
if self.handle_message(msg).await {
break;
}
}
}
/// Synchronous message loop.
#[cfg(not(feature = "native-bluetooth"))]
fn start_sync(&mut self, receiver: GenericReceiver<BluetoothRequest>) {
// For mock-only builds, we don't have a tokio runtime.
// Create a minimal one just to call async methods (which are fast for mock).
while let Ok(msg) = receiver.recv() {
let should_exit = futures::executor::block_on(self.handle_message(msg));
if should_exit {
break;
}
}
}
/// Handle a single message. Returns true if the event loop should exit.
async fn handle_message(&mut self, msg: BluetoothRequest) -> bool {
match msg {
BluetoothRequest::RequestDevice(options, sender) => {
let _ = sender.send(self.request_device(options).await);
},
BluetoothRequest::GATTServerConnect(device_id, sender) => {
let _ = sender.send(self.gatt_server_connect(device_id).await);
},
BluetoothRequest::GATTServerDisconnect(device_id, sender) => {
let _ = sender.send(self.gatt_server_disconnect(device_id).await);
},
BluetoothRequest::GetGATTChildren(id, uuid, single, child_type, sender) => {
let _ = sender.send(self.get_gatt_children(id, uuid, single, child_type).await);
},
BluetoothRequest::ReadValue(id, sender) => {
let _ = sender.send(self.read_value(id).await);
},
BluetoothRequest::WriteValue(id, value, sender) => {
let _ = sender.send(self.write_value(id, value).await);
},
BluetoothRequest::EnableNotification(id, enable, sender) => {
let _ = sender.send(self.enable_notification(id, enable).await);
},
BluetoothRequest::WatchAdvertisements(id, sender) => {
let _ = sender.send(self.watch_advertisements(id));
},
BluetoothRequest::Test(data_set_name, sender) => {
let _ = sender.send(self.test(data_set_name).await);
},
BluetoothRequest::SetRepresentedToNull(
service_ids,
characteristic_ids,
descriptor_ids,
) => self.remove_ids_from_caches(service_ids, characteristic_ids, descriptor_ids),
BluetoothRequest::IsRepresentedDeviceNull(id, sender) => {
let _ = sender.send(!self.device_is_cached(&id));
},
BluetoothRequest::GetAvailability(sender) => {
let _ = sender.send(self.get_availability().await);
},
BluetoothRequest::MatchesFilter(id, filters, sender) => {
let _ = sender.send(self.device_matches_filter(&id, &filters).await);
},
BluetoothRequest::Exit => return true,
}
false
}
// Test
fn test(&mut self, data_set_name: String) -> BluetoothResult<()> {
async fn test(&mut self, data_set_name: String) -> BluetoothResult<()> {
self.address_to_id.clear();
self.service_to_device.clear();
self.characteristic_to_service.clear();
@@ -296,7 +370,7 @@ impl BluetoothManager {
self.cached_descriptors.clear();
self.allowed_services.clear();
self.adapter = BluetoothAdapter::new_mock().ok();
match test::test(self, data_set_name) {
match test::test(self, data_set_name).await {
Ok(_) => Ok(()),
Err(error) => Err(BluetoothError::Type(error.to_string())),
}
@@ -326,13 +400,20 @@ impl BluetoothManager {
// Adapter
pub fn get_or_create_adapter(&mut self) -> Option<BluetoothAdapter> {
let adapter_valid = self
.adapter
.as_ref()
.is_some_and(|a| a.get_address().is_ok());
pub async fn get_or_create_adapter(&mut self) -> Option<BluetoothAdapter> {
let adapter_valid = match self.adapter.as_ref() {
Some(a) => a.get_address().await.is_ok(),
None => false,
};
if !adapter_valid {
self.adapter = BluetoothAdapter::new().ok();
#[cfg(feature = "native-bluetooth")]
{
self.adapter = BluetoothAdapter::new().await.ok();
}
#[cfg(not(feature = "native-bluetooth"))]
{
self.adapter = BluetoothAdapter::new().ok();
}
}
let adapter = self.adapter.as_ref()?;
@@ -344,10 +425,10 @@ impl BluetoothManager {
self.adapter.clone()
}
fn get_adapter(&mut self) -> BluetoothResult<BluetoothAdapter> {
match self.get_or_create_adapter() {
async fn get_adapter(&mut self) -> BluetoothResult<BluetoothAdapter> {
match self.get_or_create_adapter().await {
Some(adapter) => {
if !adapter.is_powered().unwrap_or(false) {
if !adapter.is_powered().await.unwrap_or(false) {
return Err(BluetoothError::NotFound);
}
Ok(adapter)
@@ -358,8 +439,11 @@ impl BluetoothManager {
// Device
fn get_and_cache_devices(&mut self, adapter: &mut BluetoothAdapter) -> Vec<BluetoothDevice> {
let devices = adapter.get_devices().unwrap_or_default();
async fn get_and_cache_devices(
&mut self,
adapter: &mut BluetoothAdapter,
) -> Vec<BluetoothDevice> {
let devices = adapter.get_devices().await.unwrap_or_default();
for device in &devices {
if let Ok(address) = device.get_address() {
#[allow(clippy::map_entry)] // False positive, the fix creates a borrowing error
@@ -375,18 +459,18 @@ impl BluetoothManager {
self.cached_devices.values().cloned().collect()
}
fn get_device(
async fn get_device(
&mut self,
adapter: &mut BluetoothAdapter,
device_id: &str,
) -> Option<&BluetoothDevice> {
return_if_cached!(self.cached_devices, device_id);
self.get_and_cache_devices(adapter);
self.get_and_cache_devices(adapter).await;
return_if_cached!(self.cached_devices, device_id);
None
}
fn select_device(
async fn select_device(
&mut self,
webview_id: WebViewId,
devices: Vec<BluetoothDevice>,
@@ -401,12 +485,18 @@ impl BluetoothManager {
return None;
}
let mut dialog_rows: Vec<String> = vec![];
let mut device_descriptions = Vec::with_capacity(devices.len());
for device in devices {
dialog_rows.extend_from_slice(&[
device.get_address().unwrap_or("".to_string()),
device.get_name().unwrap_or("".to_string()),
]);
let address = device.get_address().unwrap_or_default();
let name = device.get_name().await.unwrap_or_else(|_| {
let short = if address.len() > 8 {
&address[..8]
} else {
&address
};
format!("Unknown ({}...)", short)
});
device_descriptions.push(BluetoothDeviceDescription { address, name });
}
let (ipc_sender, ipc_receiver) =
@@ -414,7 +504,7 @@ impl BluetoothManager {
self.embedder_proxy
.send(EmbedderMsg::GetSelectedBluetoothDevice(
webview_id,
dialog_rows,
device_descriptions,
ipc_sender,
));
@@ -449,27 +539,27 @@ impl BluetoothManager {
self.address_to_id.values().any(|v| v == device_id)
}
fn device_matches_filter(
async fn device_matches_filter(
&mut self,
device_id: &str,
filters: &BluetoothScanfilterSequence,
) -> BluetoothResult<bool> {
let mut adapter = self.get_adapter()?;
match self.get_device(&mut adapter, device_id) {
Some(device) => Ok(matches_filters(device, filters)),
let mut adapter = self.get_adapter().await?;
match self.get_device(&mut adapter, device_id).await {
Some(device) => Ok(matches_filters(device, filters).await),
None => Ok(false),
}
}
// Service
fn get_and_cache_gatt_services(
async fn get_and_cache_gatt_services(
&mut self,
adapter: &mut BluetoothAdapter,
device_id: &str,
) -> Vec<BluetoothGATTService> {
let mut services = match self.get_device(adapter, device_id) {
Some(d) => d.get_gatt_services().unwrap_or_default(),
let mut services = match self.get_device(adapter, device_id).await {
Some(d) => d.get_gatt_services().await.unwrap_or_default(),
None => vec![],
};
@@ -488,14 +578,14 @@ impl BluetoothManager {
services
}
fn get_gatt_service(
async fn get_gatt_service(
&mut self,
adapter: &mut BluetoothAdapter,
service_id: &str,
) -> Option<&BluetoothGATTService> {
return_if_cached!(self.cached_services, service_id);
let device_id = self.service_to_device.get(service_id)?.clone();
self.get_and_cache_gatt_services(adapter, &device_id);
self.get_and_cache_gatt_services(adapter, &device_id).await;
return_if_cached!(self.cached_services, service_id);
None
}
@@ -507,12 +597,12 @@ impl BluetoothManager {
// Characteristic
fn get_and_cache_gatt_characteristics(
async fn get_and_cache_gatt_characteristics(
&mut self,
adapter: &mut BluetoothAdapter,
service_id: &str,
) -> Vec<BluetoothGATTCharacteristic> {
let mut characteristics = match self.get_gatt_service(adapter, service_id) {
let mut characteristics = match self.get_gatt_service(adapter, service_id).await {
Some(s) => s.get_gatt_characteristics().unwrap_or_default(),
None => vec![],
};
@@ -528,7 +618,7 @@ impl BluetoothManager {
characteristics
}
fn get_gatt_characteristic(
async fn get_gatt_characteristic(
&mut self,
adapter: &mut BluetoothAdapter,
characteristic_id: &str,
@@ -538,7 +628,8 @@ impl BluetoothManager {
.characteristic_to_service
.get(characteristic_id)?
.clone();
self.get_and_cache_gatt_characteristics(adapter, &service_id);
self.get_and_cache_gatt_characteristics(adapter, &service_id)
.await;
return_if_cached!(self.cached_characteristics, characteristic_id);
None
}
@@ -571,12 +662,15 @@ impl BluetoothManager {
// Descriptor
fn get_and_cache_gatt_descriptors(
async fn get_and_cache_gatt_descriptors(
&mut self,
adapter: &mut BluetoothAdapter,
characteristic_id: &str,
) -> Vec<BluetoothGATTDescriptor> {
let mut descriptors = match self.get_gatt_characteristic(adapter, characteristic_id) {
let mut descriptors = match self
.get_gatt_characteristic(adapter, characteristic_id)
.await
{
Some(c) => c.get_gatt_descriptors().unwrap_or_default(),
None => vec![],
};
@@ -592,7 +686,7 @@ impl BluetoothManager {
descriptors
}
fn get_gatt_descriptor(
async fn get_gatt_descriptor(
&mut self,
adapter: &mut BluetoothAdapter,
descriptor_id: &str,
@@ -602,7 +696,8 @@ impl BluetoothManager {
.descriptor_to_characteristic
.get(descriptor_id)?
.clone();
self.get_and_cache_gatt_descriptors(adapter, &characteristic_id);
self.get_and_cache_gatt_descriptors(adapter, &characteristic_id)
.await;
return_if_cached!(self.cached_descriptors, descriptor_id);
None
}
@@ -610,29 +705,37 @@ impl BluetoothManager {
// Methods
/// <https://webbluetoothcg.github.io/web-bluetooth/#request-bluetooth-devices>
fn request_device(&mut self, options: RequestDeviceoptions) -> BluetoothResponseResult {
async fn request_device(&mut self, options: RequestDeviceoptions) -> BluetoothResponseResult {
// Step 6.
let mut adapter = self.get_adapter()?;
let mut adapter = self.get_adapter().await?;
// Step 7.
// Note: There are no requiredServiceUUIDS, we scan for all devices.
if let Ok(ref session) = adapter.create_discovery_session() {
if session.start_discovery().is_ok() && !is_mock_adapter(&adapter) {
thread::sleep(Duration::from_millis(DISCOVERY_TIMEOUT_MS));
if session.start_discovery().await.is_ok() && !is_mock_adapter(&adapter) {
async_sleep(Duration::from_millis(DISCOVERY_TIMEOUT_MS)).await;
}
let _ = session.stop_discovery();
let _ = session.stop_discovery().await;
}
let mut matched_devices = self.get_and_cache_devices(&mut adapter);
let mut matched_devices = self.get_and_cache_devices(&mut adapter).await;
// Step 8.
if !options.is_accepting_all_devices() {
matched_devices.retain(|d| matches_filters(d, options.get_filters()));
let mut filtered = Vec::new();
for d in matched_devices {
if matches_filters(&d, options.get_filters()).await {
filtered.push(d);
}
}
matched_devices = filtered;
}
// Step 9.
if let Some(address) = self.select_device(options.webview_id(), matched_devices, &adapter) {
if let Some(address) = self
.select_device(options.webview_id(), matched_devices, &adapter)
.await
{
let device_id = match self.address_to_id.get(&address) {
Some(id) => id.clone(),
None => return Err(BluetoothError::NotFound),
@@ -642,10 +745,10 @@ impl BluetoothManager {
services = services_set | &services;
}
self.allowed_services.insert(device_id.clone(), services);
if let Some(device) = self.get_device(&mut adapter, &device_id) {
if let Some(device) = self.get_device(&mut adapter, &device_id).await {
let message = BluetoothDeviceMsg {
id: device_id,
name: device.get_name().ok(),
name: device.get_name().await.ok(),
};
return Ok(BluetoothResponse::RequestDevice(message));
}
@@ -656,28 +759,28 @@ impl BluetoothManager {
}
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattserver-connect>
fn gatt_server_connect(&mut self, device_id: String) -> BluetoothResponseResult {
async fn gatt_server_connect(&mut self, device_id: String) -> BluetoothResponseResult {
// Step 2.
if !self.device_is_cached(&device_id) {
return Err(BluetoothError::Network);
}
let mut adapter = self.get_adapter()?;
let mut adapter = self.get_adapter().await?;
// Step 5.1.1.
match self.get_device(&mut adapter, &device_id) {
match self.get_device(&mut adapter, &device_id).await {
Some(d) => {
if d.is_connected().unwrap_or(false) {
if d.is_connected().await.unwrap_or(false) {
return Ok(BluetoothResponse::GATTServerConnect(true));
}
let _ = d.connect();
let _ = d.connect().await;
for _ in 0..MAXIMUM_TRANSACTION_TIME {
if d.is_connected().unwrap_or(false) {
if d.is_connected().await.unwrap_or(false) {
return Ok(BluetoothResponse::GATTServerConnect(true));
} else {
if is_mock_adapter(&adapter) {
break;
}
thread::sleep(Duration::from_millis(CONNECTION_TIMEOUT_MS));
async_sleep(Duration::from_millis(CONNECTION_TIMEOUT_MS)).await;
}
// TODO: Step 5.1.4: Use the exchange MTU procedure.
}
@@ -689,18 +792,18 @@ impl BluetoothManager {
}
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattserver-disconnect>
fn gatt_server_disconnect(&mut self, device_id: String) -> BluetoothResult<()> {
let mut adapter = self.get_adapter()?;
match self.get_device(&mut adapter, &device_id) {
async fn gatt_server_disconnect(&mut self, device_id: String) -> BluetoothResult<()> {
let mut adapter = self.get_adapter().await?;
match self.get_device(&mut adapter, &device_id).await {
Some(d) => {
// Step 2.
if !d.is_connected().unwrap_or(true) {
if !d.is_connected().await.unwrap_or(true) {
return Ok(());
}
let _ = d.disconnect();
let _ = d.disconnect().await;
for _ in 0..MAXIMUM_TRANSACTION_TIME {
if d.is_connected().unwrap_or(true) {
thread::sleep(Duration::from_millis(CONNECTION_TIMEOUT_MS))
if d.is_connected().await.unwrap_or(true) {
async_sleep(Duration::from_millis(CONNECTION_TIMEOUT_MS)).await;
} else {
return Ok(());
}
@@ -712,14 +815,14 @@ impl BluetoothManager {
}
/// <https://webbluetoothcg.github.io/web-bluetooth/#getgattchildren>
fn get_gatt_children(
async fn get_gatt_children(
&mut self,
id: String,
uuid: Option<String>,
single: bool,
child_type: GATTType,
) -> BluetoothResponseResult {
let mut adapter = self.get_adapter()?;
let mut adapter = self.get_adapter().await?;
match child_type {
GATTType::PrimaryService => {
// Step 5.
@@ -736,7 +839,7 @@ impl BluetoothManager {
return Err(BluetoothError::Security);
}
}
let mut services = self.get_and_cache_gatt_services(&mut adapter, &id);
let mut services = self.get_and_cache_gatt_services(&mut adapter, &id).await;
if let Some(uuid) = uuid {
services.retain(|e| e.get_uuid().unwrap_or_default() == uuid);
}
@@ -752,6 +855,7 @@ impl BluetoothManager {
}
}
}
// Step 7.
if services_vec.is_empty() {
return Err(BluetoothError::NotFound);
@@ -765,8 +869,9 @@ impl BluetoothManager {
return Err(BluetoothError::InvalidState);
}
// Step 6.
let mut characteristics =
self.get_and_cache_gatt_characteristics(&mut adapter, &id);
let mut characteristics = self
.get_and_cache_gatt_characteristics(&mut adapter, &id)
.await;
if let Some(uuid) = uuid {
characteristics.retain(|e| e.get_uuid().unwrap_or_default() == uuid);
}
@@ -812,7 +917,7 @@ impl BluetoothManager {
Some(device) => device,
None => return Err(BluetoothError::NotFound),
};
let primary_service = match self.get_gatt_service(&mut adapter, &id) {
let primary_service = match self.get_gatt_service(&mut adapter, &id).await {
Some(s) => s,
None => return Err(BluetoothError::NotFound),
};
@@ -845,7 +950,7 @@ impl BluetoothManager {
return Err(BluetoothError::InvalidState);
}
// Step 6.
let mut descriptors = self.get_and_cache_gatt_descriptors(&mut adapter, &id);
let mut descriptors = self.get_and_cache_gatt_descriptors(&mut adapter, &id).await;
if let Some(uuid) = uuid {
descriptors.retain(|e| e.get_uuid().unwrap_or_default() == uuid);
}
@@ -870,23 +975,25 @@ impl BluetoothManager {
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-readvalue>
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattdescriptor-readvalue>
fn read_value(&mut self, id: String) -> BluetoothResponseResult {
async fn read_value(&mut self, id: String) -> BluetoothResponseResult {
// (Characteristic) Step 5.2: Missing because it is optional.
// (Descriptor) Step 5.1: Missing because it is optional.
let mut adapter = self.get_adapter()?;
let mut adapter = self.get_adapter().await?;
// (Characteristic) Step 5.3.
let mut value = self
.get_gatt_characteristic(&mut adapter, &id)
.map(|c| c.read_value().unwrap_or_default());
let mut value = match self.get_gatt_characteristic(&mut adapter, &id).await {
Some(c) => Some(c.read_value().await.unwrap_or_default()),
None => None,
};
// (Characteristic) TODO: Step 5.4: Handle all the errors returned from the read_value call.
// (Descriptor) Step 5.2.
if value.is_none() {
value = self
.get_gatt_descriptor(&mut adapter, &id)
.map(|d| d.read_value().unwrap_or_default());
value = match self.get_gatt_descriptor(&mut adapter, &id).await {
Some(d) => Some(d.read_value().await.unwrap_or_default()),
None => None,
};
}
// (Descriptor) TODO: Step 5.3: Handle all the errors returned from the read_value call.
@@ -904,36 +1011,36 @@ impl BluetoothManager {
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-writevalue>
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattdescriptor-writevalue>
fn write_value(&mut self, id: String, value: Vec<u8>) -> BluetoothResponseResult {
async fn write_value(&mut self, id: String, value: Vec<u8>) -> BluetoothResponseResult {
// (Characteristic) Step 7.2: Missing because it is optional.
// (Descriptor) Step 7.1: Missing because it is optional.
let mut adapter = self.get_adapter()?;
let mut adapter = self.get_adapter().await?;
// (Characteristic) Step 7.3.
let mut result = self
.get_gatt_characteristic(&mut adapter, &id)
.map(|c| c.write_value(value.clone()));
let mut result = match self.get_gatt_characteristic(&mut adapter, &id).await {
Some(c) => Some(c.write_value(value.clone()).await),
None => None,
};
// (Characteristic) TODO: Step 7.4: Handle all the errors returned from the write_value call.
// (Descriptor) Step 7.2.
if result.is_none() {
result = self
.get_gatt_descriptor(&mut adapter, &id)
.map(|d| d.write_value(value.clone()));
result = match self.get_gatt_descriptor(&mut adapter, &id).await {
Some(d) => Some(d.write_value(value.clone()).await),
None => None,
};
}
// (Descriptor) TODO: Step 7.3: Handle all the errors returned from the write_value call.
match result {
Some(v) => match v {
// (Characteristic) Step 7.5.3.
// (Descriptor) Step 7.4.3.
Ok(_) => Ok(BluetoothResponse::WriteValue(value)),
// (Characteristic) Step 7.5.3.
// (Descriptor) Step 7.4.3.
Some(Ok(_)) => Ok(BluetoothResponse::WriteValue(value)),
// (Characteristic) Step 7.1.
Err(_) => Err(BluetoothError::NotSupported),
},
// (Characteristic) Step 7.1.
Some(Err(_)) => Err(BluetoothError::NotSupported),
// (Characteristic) Step 6.
// (Descriptor) Step 6.
@@ -943,7 +1050,7 @@ impl BluetoothManager {
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-startnotifications>
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetoothremotegattcharacteristic-stopnotifications>
fn enable_notification(&mut self, id: String, enable: bool) -> BluetoothResponseResult {
async fn enable_notification(&mut self, id: String, enable: bool) -> BluetoothResponseResult {
// (StartNotifications) Step 3 - 4.
// (StopNotifications) Step 1 - 2.
if !self.characteristic_is_cached(&id) {
@@ -951,16 +1058,16 @@ impl BluetoothManager {
}
// (StartNotification) TODO: Step 7: Missing because it is optional.
let mut adapter = self.get_adapter()?;
match self.get_gatt_characteristic(&mut adapter, &id) {
let mut adapter = self.get_adapter().await?;
match self.get_gatt_characteristic(&mut adapter, &id).await {
Some(c) => {
let result = if enable {
// (StartNotification) Step 8.
// TODO: Handle all the errors returned from the start_notify call.
c.start_notify()
c.start_notify().await
} else {
// (StopNotification) Step 4.
c.stop_notify()
c.stop_notify().await
};
match result {
// (StartNotification) Step 11.
@@ -984,9 +1091,9 @@ impl BluetoothManager {
}
/// <https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetooth-getavailability>
fn get_availability(&mut self) -> BluetoothResponseResult {
async fn get_availability(&mut self) -> BluetoothResponseResult {
Ok(BluetoothResponse::GetAvailability(
self.get_adapter().is_ok(),
self.get_adapter().await.is_ok(),
))
}
}

View File

@@ -2,81 +2,12 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
macro_rules! get_inner_and_call(
($enum_value: expr, $enum_type: ident, $function_name: ident) => {
match $enum_value {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
&$enum_type::Bluez(ref bluez) => bluez.$function_name(),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
&$enum_type::Android(ref android) => android.$function_name(),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
&$enum_type::Mac(ref mac) => mac.$function_name(),
#[cfg(not(any(all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth"))))]
&$enum_type::Empty(ref empty) => empty.$function_name(),
#[cfg(feature = "bluetooth-test")]
&$enum_type::Mock(ref fake) => fake.$function_name(),
}
};
(@with_bluez_offset, $enum_value: expr, $enum_type: ident, $function_name: ident) => {
match $enum_value {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
&$enum_type::Bluez(ref bluez) => bluez.$function_name(None),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
&$enum_type::Android(ref android) => android.$function_name(),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
&$enum_type::Mac(ref mac) => mac.$function_name(),
#[cfg(not(any(all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth"))))]
&$enum_type::Empty(ref empty) => empty.$function_name(),
#[cfg(feature = "bluetooth-test")]
&$enum_type::Mock(ref fake) => fake.$function_name(),
}
};
($enum_value: expr, $enum_type: ident, $function_name: ident, $value: expr) => {
match $enum_value {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
&$enum_type::Bluez(ref bluez) => bluez.$function_name($value),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
&$enum_type::Android(ref android) => android.$function_name($value),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
&$enum_type::Mac(ref mac) => mac.$function_name($value),
#[cfg(not(any(all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth"))))]
&$enum_type::Empty(ref empty) => empty.$function_name($value),
#[cfg(feature = "bluetooth-test")]
&$enum_type::Mock(ref fake) => fake.$function_name($value),
}
};
(@with_bluez_offset, $enum_value: expr, $enum_type: ident, $function_name: ident, $value: expr) => {
match $enum_value {
#[cfg(all(target_os = "linux", feature = "native-bluetooth"))]
&$enum_type::Bluez(ref bluez) => bluez.$function_name($value, None),
#[cfg(all(target_os = "android", feature = "native-bluetooth"))]
&$enum_type::Android(ref android) => android.$function_name($value),
#[cfg(all(target_os = "macos", feature = "native-bluetooth"))]
&$enum_type::Mac(ref mac) => mac.$function_name($value),
#[cfg(not(any(all(target_os = "linux", feature = "native-bluetooth"),
all(target_os = "android", feature = "native-bluetooth"),
all(target_os = "macos", feature = "native-bluetooth"))))]
&$enum_type::Empty(ref empty) => empty.$function_name($value),
#[cfg(feature = "bluetooth-test")]
&$enum_type::Mock(ref fake) => fake.$function_name($value),
}
};
);
#[cfg(feature = "bluetooth-test")]
macro_rules! get_inner_and_call_test_func {
($enum_value: expr, $enum_type: ident, $function_name: ident, $value: expr) => {
match $enum_value {
&$enum_type::Mock(ref fake) => fake.$function_name($value),
#[cfg(feature = "native-bluetooth")]
_ => Err(Box::from(
"Error! Test functions are not supported on real devices!",
)),
@@ -86,6 +17,7 @@ macro_rules! get_inner_and_call_test_func {
($enum_value: expr, $enum_type: ident, $function_name: ident) => {
match $enum_value {
&$enum_type::Mock(ref fake) => fake.$function_name(),
#[cfg(feature = "native-bluetooth")]
_ => Err(Box::from(
"Error! Test functions are not supported on real devices!",
)),
@@ -93,6 +25,5 @@ macro_rules! get_inner_and_call_test_func {
};
}
pub(crate) use get_inner_and_call;
#[cfg(feature = "bluetooth-test")]
pub(crate) use get_inner_and_call_test_func;

View File

@@ -512,8 +512,11 @@ fn create_glucose_heart_rate_devices(adapter: &BluetoothAdapter) -> Result<(), B
Ok(())
}
pub fn test(manager: &mut BluetoothManager, data_set_name: String) -> Result<(), Box<dyn Error>> {
let may_existing_adapter = manager.get_or_create_adapter();
pub async fn test(
manager: &mut BluetoothManager,
data_set_name: String,
) -> Result<(), Box<dyn Error>> {
let may_existing_adapter = manager.get_or_create_adapter().await;
let adapter = match may_existing_adapter.as_ref() {
Some(adapter) => adapter,
None => return Err(Box::from(ADAPTER_ERROR.to_string())),

View File

@@ -6,9 +6,11 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "canvas"
name = "servo_canvas"
path = "lib.rs"
[features]
@@ -16,23 +18,23 @@ tracing = ["dep:tracing"]
vello = ["dep:vello", "dep:pollster", "dep:futures-intrusive"]
[dependencies]
base = { workspace = true }
bytemuck = { workspace = true, features = ["extern_crate_alloc"] }
canvas_traits = { workspace = true }
crossbeam-channel = { workspace = true }
euclid = { workspace = true }
fonts = { package = "servo-fonts", path = "../fonts" }
fonts = { workspace = true }
futures-intrusive = { version = "0.5", optional = true }
kurbo = { workspace = true }
log = { workspace = true }
paint_api = { workspace = true }
peniko = { workspace = true }
pixels = { package = "servo-pixels", path = "../pixels" }
profile_traits = { workspace = true }
pixels = { workspace = true }
pollster = { version = "0.4", optional = true }
profile_traits = { workspace = true }
rustc-hash = { workspace = true }
servo-base = { workspace = true }
servo-canvas-traits = { workspace = true }
servo-config = { workspace = true }
servo-tracing = { workspace = true }
servo_config = { package = "servo-config", path = "../config" }
stylo = { workspace = true }
tracing = { workspace = true, optional = true }
vello = { workspace = true, optional = true }

View File

@@ -2,12 +2,12 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use canvas_traits::canvas::{
CompositionOptions, FillOrStrokeStyle, FillRule, LineOptions, Path, ShadowOptions, TextRun,
};
use euclid::default::{Point2D, Rect, Size2D, Transform2D};
use paint_api::SerializableImageData;
use pixels::Snapshot;
use servo_canvas_traits::canvas::{
CompositionOptions, FillOrStrokeStyle, FillRule, LineOptions, Path, ShadowOptions, TextRun,
};
use webrender_api::ImageDescriptor;
use crate::canvas_data::Filter;

View File

@@ -2,11 +2,11 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use base::Epoch;
use canvas_traits::canvas::*;
use euclid::default::{Point2D, Rect, Size2D, Transform2D};
use paint_api::CrossProcessPaintApi;
use pixels::Snapshot;
use servo_base::Epoch;
use servo_canvas_traits::canvas::*;
use webrender_api::ImageKey;
use crate::backend::GenericDrawTarget;
@@ -318,7 +318,7 @@ impl<DrawTarget: GenericDrawTarget> CanvasData<DrawTarget> {
let (descriptor, data) = {
let _span =
profile_traits::trace_span!("image_descriptor_and_serializable_data",).entered();
profile_traits::trace_span!("image_descriptor_and_serializable_data").entered();
self.draw_target.image_descriptor_and_serializable_data()
};

View File

@@ -5,16 +5,16 @@
use std::borrow::ToOwned;
use std::{f32, thread};
use base::generic_channel::GenericSender;
use base::{Epoch, generic_channel};
use canvas_traits::ConstellationCanvasMsg;
use canvas_traits::canvas::*;
use crossbeam_channel::{Sender, select, unbounded};
use euclid::default::{Rect, Size2D, Transform2D};
use log::warn;
use paint_api::CrossProcessPaintApi;
use pixels::Snapshot;
use rustc_hash::FxHashMap;
use servo_base::generic_channel::GenericSender;
use servo_base::{Epoch, generic_channel};
use servo_canvas_traits::ConstellationCanvasMsg;
use servo_canvas_traits::canvas::*;
use webrender_api::ImageKey;
use crate::canvas_data::*;
@@ -30,7 +30,7 @@ impl CanvasPaintThread {
CanvasPaintThread {
canvases: FxHashMap::default(),
next_canvas_id: CanvasId(0),
paint_api: paint_api.clone(),
paint_api,
}
}

View File

@@ -2,9 +2,9 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use canvas_traits::canvas::*;
use peniko::ImageAlphaType;
use pixels::{Alpha, SnapshotPixelFormat};
use servo_canvas_traits::canvas::*;
use style::color::AbsoluteColor;
use crate::backend::Convert;
@@ -144,7 +144,7 @@ impl Convert<ImageAlphaType> for Alpha {
impl Convert<peniko::Brush> for FillOrStrokeStyle {
fn convert(self) -> peniko::Brush {
use canvas_traits::canvas::FillOrStrokeStyle::*;
use servo_canvas_traits::canvas::FillOrStrokeStyle::*;
match self {
Color(absolute_color) => peniko::Brush::Solid(absolute_color.convert()),
LinearGradient(style) => {

View File

@@ -16,16 +16,16 @@ use std::collections::HashMap;
use std::num::NonZeroUsize;
use std::rc::Rc;
use base::generic_channel::GenericSharedMemory;
use canvas_traits::canvas::{
CompositionOptions, CompositionOrBlending, CompositionStyle, FillOrStrokeStyle, FillRule,
LineOptions, Path, ShadowOptions, TextRun,
};
use euclid::default::{Point2D, Rect, Size2D, Transform2D};
use fonts::FontIdentifier;
use kurbo::Shape as _;
use paint_api::SerializableImageData;
use pixels::{Snapshot, SnapshotAlphaMode, SnapshotPixelFormat};
use servo_base::generic_channel::GenericSharedMemory;
use servo_canvas_traits::canvas::{
CompositionOptions, CompositionOrBlending, CompositionStyle, FillOrStrokeStyle, FillRule,
LineOptions, Path, ShadowOptions, TextRun,
};
use vello::wgpu::{
BackendOptions, Backends, Buffer, BufferDescriptor, BufferUsages, COPY_BYTES_PER_ROW_ALIGNMENT,
CommandEncoderDescriptor, Device, Extent3d, Instance, InstanceDescriptor, InstanceFlags,

View File

@@ -6,16 +6,16 @@ use std::cell::RefCell;
use std::collections::HashMap;
use std::sync::Arc;
use base::generic_channel::GenericSharedMemory;
use canvas_traits::canvas::{
CompositionOptions, CompositionOrBlending, CompositionStyle, FillOrStrokeStyle, FillRule,
LineOptions, Path, ShadowOptions, TextRun,
};
use euclid::default::{Point2D, Rect, Size2D, Transform2D};
use fonts::FontIdentifier;
use kurbo::Shape;
use paint_api::SerializableImageData;
use pixels::{Snapshot, SnapshotAlphaMode, SnapshotPixelFormat};
use servo_base::generic_channel::GenericSharedMemory;
use servo_canvas_traits::canvas::{
CompositionOptions, CompositionOrBlending, CompositionStyle, FillOrStrokeStyle, FillRule,
LineOptions, Path, ShadowOptions, TextRun,
};
use vello_cpu::{kurbo, peniko};
use webrender_api::{ImageDescriptor, ImageDescriptorFlags};
@@ -511,7 +511,7 @@ fn snapshot_as_pixmap(mut snapshot: Snapshot) -> Arc<vello_cpu::Pixmap> {
impl Convert<vello_cpu::PaintType> for FillOrStrokeStyle {
fn convert(self) -> vello_cpu::PaintType {
use canvas_traits::canvas::FillOrStrokeStyle::*;
use servo_canvas_traits::canvas::FillOrStrokeStyle::*;
match self {
Color(absolute_color) => vello_cpu::PaintType::Solid(absolute_color.convert()),
LinearGradient(style) => {

View File

@@ -6,6 +6,8 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "servo_config"
@@ -14,6 +16,5 @@ path = "lib.rs"
[dependencies]
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }
servo_config_macro = { package = "servo-config-macro", path = "macro" }
servo_url = { package = "servo-url", path = "../url" }
servo-config-macro = { workspace = true }
stylo_static_prefs = { workspace = true }

View File

@@ -2,6 +2,12 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
//! This crate provides two mechanisms for configuring the behaviour of the Servo engine.
//! - The [`opts`] module exposes a set of global flags that are initialized once
//! and cannot be changed at runtime.
//! - The [`prefs`] module provides a mechanism to get and set global preference
//! values that can be changed at runtime.
#![deny(unsafe_code)]
pub mod opts;

View File

@@ -6,6 +6,8 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "servo_config_macro"

View File

@@ -2,8 +2,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
//! Configuration options for a single run of the servo application. Created
//! from command line arguments.
//! Options are global configuration options that are initialized once and cannot be changed at
//! runtime.
use std::default::Default;
use std::path::PathBuf;
@@ -11,28 +11,21 @@ use std::process;
use std::sync::OnceLock;
use serde::{Deserialize, Serialize};
use servo_url::ServoUrl;
/// Global flags for Servo, currently set on the command line.
/// The set of global options supported by Servo. The values for these can be configured during
/// initialization of Servo and cannot be changed later at runtime.
#[derive(Clone, Debug, Deserialize, Serialize)]
pub struct Opts {
/// `None` to disable the time profiler or `Some` to enable it with:
/// `None` to disable the time profiler or `Some` to enable it with either:
///
/// - an interval in seconds to cause it to produce output on that interval.
/// (`i.e. -p 5`).
/// - a file path to write profiling info to a TSV file upon Servo's termination.
/// (`i.e. -p out.tsv`).
pub time_profiling: Option<OutputOptions>,
/// When the profiler is enabled, this is an optional path to dump a self-contained HTML file
/// visualizing the traces as a timeline.
pub time_profiler_trace_path: Option<String>,
/// True to turn off incremental layout.
pub nonincremental_layout: bool,
pub user_stylesheets: Vec<(Vec<u8>, ServoUrl)>,
/// True to exit on thread failure instead of displaying about:failure.
pub hard_fail: bool,
@@ -83,15 +76,12 @@ pub struct Opts {
/// Unminify Css.
pub unminify_css: bool,
/// Print Progressive Web Metrics to console.
pub print_pwm: bool,
}
/// Debug options for Servo, currently set on the command line with -Z
/// Debug options for Servo.
#[derive(Clone, Debug, Default, Deserialize, Serialize)]
pub struct DiagnosticsLogging {
/// List all the debug options.
/// Print all the debug options supported by Servo to the standard output.
pub help: bool,
/// Print the DOM after each restyle.
@@ -127,6 +117,9 @@ pub struct DiagnosticsLogging {
/// Log garbage collection passes and their durations.
pub gc_profile: bool,
/// Log Progressive Web Metrics.
pub progressive_web_metrics: bool,
}
impl DiagnosticsLogging {
@@ -174,6 +167,7 @@ impl DiagnosticsLogging {
print_option("relayout-event", "Log when relayout occurs");
print_option("profile-script-events", "Log script event processing time");
print_option("gc-profile", "Log garbage collection statistics");
print_option("progressive-web-metrics", "Log Progressive Web Metrics");
println!();
process::exit(0);
@@ -197,6 +191,7 @@ impl DiagnosticsLogging {
"gc-profile" => self.gc_profile = true,
"profile-script-events" => self.profile_script_events = true,
"relayout-event" => self.relayout_event = true,
"progressive-web-metrics" => self.progressive_web_metrics = true,
"" => {},
_ => return Err(format!("Unknown diagnostic option: {option}")),
};
@@ -206,9 +201,9 @@ impl DiagnosticsLogging {
}
}
/// The destination for the time profiler reports.
#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)]
pub enum OutputOptions {
/// Database connection config (hostname, name, user, pass)
FileName(String),
Stdout(f64),
}
@@ -218,8 +213,6 @@ impl Default for Opts {
Self {
time_profiling: None,
time_profiler_trace_path: None,
nonincremental_layout: false,
user_stylesheets: Vec::new(),
hard_fail: true,
multiprocess: false,
force_ipc: false,
@@ -235,7 +228,6 @@ impl Default for Opts {
unminify_js: false,
local_script_source: None,
unminify_css: false,
print_pwm: false,
}
}
}
@@ -248,16 +240,16 @@ static OPTIONS: OnceLock<Opts> = OnceLock::new();
/// Initialize options.
///
/// Should only be called once at process startup.
/// Must be called before the first call to [get].
/// Must be called before the first call to [`get`].
pub fn initialize_options(opts: Opts) {
OPTIONS.set(opts).expect("Already initialized");
}
/// Get the servo options
///
/// If the servo options have not been initialized by calling [initialize_options], then the
/// options will be initialized to default values. Outside of tests the options should
/// be explicitly initialized.
/// If the servo options have not been initialized by calling [`initialize_options`], then the
/// options will be initialized to default values. Outside of tests the options should be
/// explicitly initialized.
#[inline]
pub fn get() -> &'static Opts {
// In unit-tests using default options reduces boilerplate.

View File

@@ -5,6 +5,7 @@
use serde::{Deserialize, Serialize};
use serde_json::Value;
/// The types of preference values in Servo.
#[derive(Clone, Debug, Deserialize, PartialEq, Serialize)]
pub enum PrefValue {
Float(f64),
@@ -16,6 +17,8 @@ pub enum PrefValue {
}
impl PrefValue {
/// Parse the `input` string as a preference value. Defaults to a `PrefValue::Str` if the input
/// cannot be parsed as valid value of one of the other types.
pub fn from_booleanish_str(input: &str) -> Self {
match input {
"false" => PrefValue::Bool(false),
@@ -95,11 +98,23 @@ impl_pref_from! {
impl_from_pref! {
PrefValue::Float => f64,
PrefValue::Int => i64,
PrefValue::UInt => u64,
PrefValue::Str => String,
PrefValue::Bool => bool,
}
// The default generated from `impl_from_pref` would cause panic
// when converting from PrefValue::Int.
impl TryFrom<PrefValue> for u64 {
type Error = String;
fn try_from(other: PrefValue) -> Result<Self, Self::Error> {
match other {
PrefValue::UInt(value) => Ok(value),
PrefValue::Int(value) if value >= 0 => Ok(value as u64),
_ => Err(format!("Cannot convert {other:?} to u64")),
}
}
}
impl From<[f64; 4]> for PrefValue {
fn from(other: [f64; 4]) -> PrefValue {
PrefValue::Array(IntoIterator::into_iter(other).map(|v| v.into()).collect())

View File

@@ -2,8 +2,11 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
//! Preferences are the global configuration options that can be changed at runtime.
use std::env::consts::ARCH;
use std::sync::{RwLock, RwLockReadGuard};
use std::time::Duration;
use serde::{Deserialize, Serialize};
use servo_config_macro::ServoPreferences;
@@ -12,7 +15,12 @@ pub use crate::pref_util::PrefValue;
static PREFERENCES: RwLock<Preferences> = RwLock::new(Preferences::const_default());
/// A trait to be implemented by components that wish to be notified about runtime changes to the
/// global preferences for the current process.
pub trait PreferencesObserver: Send + Sync {
/// This method is called when the global preferences have been updated. The argument to the
/// method is an array of tuples where the first component is the name of the preference and
/// the second component is the new value of the preference.
fn prefs_changed(&self, _changes: &[(&'static str, PrefValue)]) {}
}
@@ -24,38 +32,36 @@ pub fn get() -> RwLockReadGuard<'static, Preferences> {
PREFERENCES.read().unwrap()
}
/// Subscribe to notifications about changes to the global preferences for the current process.
pub fn add_observer(observer: Box<dyn PreferencesObserver>) {
OBSERVERS.write().unwrap().push(observer);
}
/// Update the values of the global preferences for the current process. This also notifies the
/// observers previously added using [`add_observer`].
pub fn set(preferences: Preferences) {
// Map between Stylo preference names and Servo preference names as the This should be
// kept in sync with components/script/dom/bindings/codegen/run.py which generates the
// DOM CSS style accessors.
stylo_static_prefs::set_bool("layout.unimplemented", preferences.layout_unimplemented);
stylo_static_prefs::set_i32("layout.threads", preferences.layout_threads as i32);
stylo_static_prefs::set_bool("layout.flexbox.enabled", preferences.layout_flexbox_enabled);
stylo_static_prefs::set_bool("layout.columns.enabled", preferences.layout_columns_enabled);
stylo_static_prefs::set_bool("layout.grid.enabled", preferences.layout_grid_enabled);
stylo_static_prefs::set_bool(
stylo_static_prefs::set_pref!("layout.unimplemented", preferences.layout_unimplemented);
stylo_static_prefs::set_pref!("layout.threads", preferences.layout_threads as i32);
stylo_static_prefs::set_pref!("layout.columns.enabled", preferences.layout_columns_enabled);
stylo_static_prefs::set_pref!("layout.grid.enabled", preferences.layout_grid_enabled);
stylo_static_prefs::set_pref!(
"layout.css.attr.enabled",
preferences.layout_css_attr_enabled,
preferences.layout_css_attr_enabled
);
stylo_static_prefs::set_bool(
"layout.css.transition-behavior.enabled",
preferences.layout_css_transition_behavior_enabled,
);
stylo_static_prefs::set_bool(
stylo_static_prefs::set_pref!(
"layout.writing-mode.enabled",
preferences.layout_writing_mode_enabled,
preferences.layout_writing_mode_enabled
);
stylo_static_prefs::set_bool(
stylo_static_prefs::set_pref!(
"layout.container-queries.enabled",
preferences.layout_container_queries_enabled,
preferences.layout_container_queries_enabled
);
stylo_static_prefs::set_bool(
stylo_static_prefs::set_pref!(
"layout.variable_fonts.enabled",
preferences.layout_variable_fonts_enabled,
preferences.layout_variable_fonts_enabled
);
let changed = preferences.diff(&PREFERENCES.read().unwrap());
@@ -76,6 +82,16 @@ macro_rules! pref {
};
}
/// The set of global preferences supported by Servo.
///
/// Each preference has a default value that determines its initial state. These defaults
/// fall into roughly three categories:
/// - **Stable**: enabled by default.
/// - **Experimental**: disabled by default, but intended to be enabled for experimental use.
/// - **Unstable**: disabled by default.
///
/// For a full overview of which preferences are experimental, see the
/// [experimental features documentation](https://book.servo.org/design-documentation/experimental-features.html).
#[derive(Clone, Deserialize, Serialize, ServoPreferences)]
pub struct Preferences {
pub fonts_default: String,
@@ -84,6 +100,9 @@ pub struct Preferences {
pub fonts_monospace: String,
pub fonts_default_size: i64,
pub fonts_default_monospace_size: i64,
/// The amount of time that a half cycle of a text caret blink takes in milliseconds.
/// If this value is less than or equal to zero, then caret blink is disabled.
pub editing_caret_blink_time: i64,
pub css_animations_testing_enabled: bool,
/// Start the devtools server at startup
pub devtools_server_enabled: bool,
@@ -97,6 +116,7 @@ pub struct Preferences {
pub dom_abort_controller_enabled: bool,
// feature: Adopted Stylesheet | #38132 | Web/API/Document/adoptedStyleSheets
pub dom_adoptedstylesheet_enabled: bool,
pub dom_allow_preloading_module_descendants: bool,
// feature: Clipboard API | #36084 | Web/API/Clipboard_API
pub dom_async_clipboard_enabled: bool,
pub dom_bluetooth_enabled: bool,
@@ -113,7 +133,6 @@ pub struct Preferences {
/// - vello_cpu
pub dom_canvas_backend: String,
pub dom_clipboardevent_enabled: bool,
pub dom_command_invokers_enabled: bool,
pub dom_composition_event_enabled: bool,
// feature: CookieStore | #37674 | Web/API/CookieStore
pub dom_cookiestore_enabled: bool,
@@ -132,6 +151,8 @@ pub struct Preferences {
pub dom_gamepad_enabled: bool,
// feature: Geolocation API | #38903 | Web/API/Geolocation_API
pub dom_geolocation_enabled: bool,
// feature: Screen Wake Lock API | #43615 | Web/API/Screen_Wake_Lock_API
pub dom_wakelock_enabled: bool,
// feature: IndexedDB | #6963 | Web/API/IndexedDB_API
pub dom_indexeddb_enabled: bool,
// feature: IntersectionObserver | #35767 | Web/API/Intersection_Observer_API
@@ -152,10 +173,16 @@ pub struct Preferences {
pub dom_permissions_testing_allowed_in_nonsecure_contexts: bool,
// feature: ResizeObserver | #39790 | Web/API/ResizeObserver
pub dom_resize_observer_enabled: bool,
// feature: Sanitizer API | #43948 | Web/API/HTML_Sanitizer_API
pub dom_sanitizer_enabled: bool,
pub dom_script_asynch: bool,
// feature: Storage API | #43976 | Web/API/Storage_API
pub dom_storage_manager_api_enabled: bool,
// feature: ServiceWorker | #36538 | Web/API/Service_Worker_API
pub dom_serviceworker_enabled: bool,
pub dom_serviceworker_timeout_seconds: i64,
// feature: SharedWorker | #7458 | Web/API/SharedWorker
pub dom_sharedworker_enabled: bool,
pub dom_servo_helpers_enabled: bool,
pub dom_servoparser_async_html_tokenizer_enabled: bool,
pub dom_testbinding_enabled: bool,
@@ -258,9 +285,6 @@ pub struct Preferences {
pub layout_grid_enabled: bool,
pub layout_container_queries_enabled: bool,
pub layout_css_attr_enabled: bool,
pub layout_css_transition_behavior_enabled: bool,
// feature: CSS Flexbox | #12453 | Web/CSS/Guides/Flexible_box_layout
pub layout_flexbox_enabled: bool,
pub layout_style_sharing_cache_enabled: bool,
pub layout_threads: i64,
pub layout_unimplemented: bool,
@@ -332,10 +356,12 @@ impl Preferences {
const fn const_default() -> Self {
Self {
css_animations_testing_enabled: false,
editing_caret_blink_time: 600,
devtools_server_enabled: false,
devtools_server_listen_address: String::new(),
dom_abort_controller_enabled: true,
dom_adoptedstylesheet_enabled: false,
dom_allow_preloading_module_descendants: false,
dom_allow_scripts_to_close_windows: false,
dom_async_clipboard_enabled: false,
dom_bluetooth_enabled: false,
@@ -344,7 +370,6 @@ impl Preferences {
dom_canvas_text_enabled: true,
dom_canvas_backend: String::new(),
dom_clipboardevent_enabled: true,
dom_command_invokers_enabled: false,
dom_composition_event_enabled: false,
dom_cookiestore_enabled: false,
dom_credential_management_enabled: false,
@@ -356,6 +381,7 @@ impl Preferences {
dom_fullscreen_test: false,
dom_gamepad_enabled: true,
dom_geolocation_enabled: false,
dom_wakelock_enabled: false,
dom_indexeddb_enabled: false,
dom_intersection_observer_enabled: false,
dom_microdata_testing_enabled: false,
@@ -368,9 +394,12 @@ impl Preferences {
dom_permissions_enabled: false,
dom_permissions_testing_allowed_in_nonsecure_contexts: false,
dom_resize_observer_enabled: true,
dom_sanitizer_enabled: false,
dom_script_asynch: true,
dom_storage_manager_api_enabled: false,
dom_serviceworker_enabled: false,
dom_serviceworker_timeout_seconds: 60,
dom_sharedworker_enabled: false,
dom_servo_helpers_enabled: false,
dom_servoparser_async_html_tokenizer_enabled: false,
dom_testbinding_enabled: false,
@@ -457,8 +486,6 @@ impl Preferences {
layout_columns_enabled: false,
layout_container_queries_enabled: false,
layout_css_attr_enabled: false,
layout_css_transition_behavior_enabled: true,
layout_flexbox_enabled: true,
layout_grid_enabled: false,
layout_style_sharing_cache_enabled: true,
// TODO(mrobinson): This should likely be based on the number of processors.
@@ -493,6 +520,16 @@ impl Preferences {
log_filter: String::new(),
}
}
/// The amount of time that a half cycle of a text caret blink takes. If blinking is disabled
/// this returns `None`.
pub fn editing_caret_blink_time(&self) -> Option<Duration> {
if self.editing_caret_blink_time > 0 {
Some(Duration::from_millis(self.editing_caret_blink_time as u64))
} else {
None
}
}
}
impl Default for Preferences {

View File

@@ -6,64 +6,66 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "constellation"
name = "servo_constellation"
path = "lib.rs"
[features]
default = []
bluetooth = ["bluetooth_traits"]
bluetooth = ["servo-bluetooth-traits"]
gamepad = ["embedder_traits/gamepad"]
tracing = ["dep:tracing", "canvas/tracing"]
vello = ["canvas/vello"]
webgpu = ["script_traits/webgpu"]
tracing = ["dep:tracing", "servo-canvas/tracing"]
vello = ["servo-canvas/vello"]
webgpu = ["dep:webgpu", "dep:webgpu_traits", "script_traits/webgpu"]
[lints.clippy]
unwrap_used = "deny"
panic = "deny"
[dependencies]
background_hang_monitor = { package = "servo-background-hang-monitor", path = "../background_hang_monitor" }
background_hang_monitor_api = { workspace = true }
accesskit = { workspace = true }
backtrace = { workspace = true }
base = { workspace = true }
bluetooth_traits = { workspace = true, optional = true }
canvas = { package = "servo-canvas", path = "../canvas" }
canvas_traits = { workspace = true }
constellation_traits = { workspace = true }
base64 = { workspace = true }
content-security-policy = { workspace = true }
crossbeam-channel = { workspace = true }
devtools_traits = { workspace = true }
embedder_traits = { workspace = true }
euclid = { workspace = true }
fonts = { package = "servo-fonts", path = "../fonts" }
fonts = { workspace = true }
ipc-channel = { workspace = true }
keyboard-types = { workspace = true }
layout_api = { workspace = true }
log = { workspace = true }
media = { package = "servo-media-thread", path = "../media/media-thread" }
net = { package = "servo-net", path = "../net" }
media = { workspace = true }
net = { workspace = true }
net_traits = { workspace = true }
paint_api = { workspace = true }
parking_lot = { workspace = true }
profile = { package = "servo-profile", path = "../profile" }
profile_traits = { workspace = true }
rand = { workspace = true }
rustc-hash = { workspace = true }
script_traits = { workspace = true }
serde = { workspace = true }
servo-background-hang-monitor = { workspace = true }
servo-background-hang-monitor-api = { workspace = true }
servo-base = { workspace = true }
servo-bluetooth-traits = { workspace = true, optional = true }
servo-canvas = { workspace = true }
servo-canvas-traits = { workspace = true }
servo-config = { workspace = true }
servo-constellation-traits = { workspace = true }
servo-tracing = { workspace = true }
servo_config = { package = "servo-config", path = "../config" }
servo_url = { package = "servo-url", path = "../url" }
servo-url = { workspace = true }
servo-wakelock = { workspace = true }
storage_traits = { workspace = true }
stylo = { workspace = true }
stylo_traits = { workspace = true }
tracing = { workspace = true, optional = true }
webgpu = { package = "servo-webgpu", path = "../webgpu" }
webgpu_traits = { workspace = true }
webrender = { workspace = true }
webrender_api = { workspace = true }
webgpu = { workspace = true, optional = true }
webgpu_traits = { workspace = true, optional = true }
webxr-api = { workspace = true }
[target.'cfg(any(target_os="macos", all(not(target_os = "windows"), not(target_os = "ios"), not(target_os="android"), not(target_env="ohos"), not(target_arch="arm"), not(target_arch="aarch64"))))'.dependencies]

View File

@@ -4,11 +4,11 @@
use std::collections::HashMap;
use base::id::BroadcastChannelRouterId;
use constellation_traits::BroadcastChannelMsg;
use ipc_channel::ipc::IpcSender;
use log::warn;
use rustc_hash::FxHashMap;
use servo_base::id::BroadcastChannelRouterId;
use servo_constellation_traits::BroadcastChannelMsg;
use servo_url::ImmutableOrigin;
#[derive(Default)]

View File

@@ -2,10 +2,10 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use base::id::{BrowsingContextGroupId, BrowsingContextId, PipelineId, WebViewId};
use embedder_traits::ViewportDetails;
use log::warn;
use rustc_hash::{FxHashMap, FxHashSet};
use servo_base::id::{BrowsingContextGroupId, BrowsingContextId, PipelineId, WebViewId};
use crate::pipeline::Pipeline;

File diff suppressed because it is too large Load Diff

View File

@@ -2,13 +2,14 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use base::id::{BrowsingContextId, PipelineId, WebViewId};
use embedder_traits::user_contents::UserContentManagerId;
use embedder_traits::{InputEvent, MouseLeftViewportEvent, Theme};
use euclid::Point2D;
use log::warn;
use rustc_hash::FxHashMap;
use script_traits::{ConstellationInputEvent, ScriptThreadMessage};
use servo_base::Epoch;
use servo_base::id::{BrowsingContextId, PipelineId, WebViewId};
use style_traits::CSSPixel;
use crate::browsingcontext::BrowsingContext;
@@ -21,6 +22,11 @@ pub(crate) struct ConstellationWebView {
/// The [`WebViewId`] of this [`ConstellationWebView`].
webview_id: WebViewId,
/// The [`PipelineId`] of the currently active pipeline at the top level of this WebView.
pub active_top_level_pipeline_id: Option<PipelineId>,
/// A counter for changes to [`Self::active_top_level_pipeline_id`].
pub active_top_level_pipeline_epoch: Epoch,
/// The currently focused browsing context in this webview for key events.
/// The focused pipeline is the current entry of the focused browsing
/// context.
@@ -45,6 +51,14 @@ pub(crate) struct ConstellationWebView {
/// The [`Theme`] that this [`ConstellationWebView`] uses. This is communicated to all
/// `ScriptThread`s so that they know how to render the contents of a particular `WebView.
theme: Theme,
/// Whether accessibility is active for this webview.
///
/// Set by [`crate::Constellation::set_accessibility_active()`], and forwarded to the
/// webviews *active* pipelines (of those that represent documents) at any given moment
/// via [`ScriptThreadMessage::SetAccessibilityActive`] in `set_accessibility_active()`
/// and [`crate::Constellation::set_frame_tree_for_webview()`].
pub accessibility_active: bool,
}
impl ConstellationWebView {
@@ -56,11 +70,14 @@ impl ConstellationWebView {
Self {
webview_id,
user_content_manager_id,
active_top_level_pipeline_id: None,
active_top_level_pipeline_epoch: Epoch::default(),
focused_browsing_context_id,
hovered_browsing_context_id: None,
last_mouse_move_point: Default::default(),
session_history: JointSessionHistory::new(),
theme: Theme::Light,
accessibility_active: false,
}
}

View File

@@ -0,0 +1,50 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use embedder_traits::{
InputEventOutcome, JSValue, JavaScriptEvaluationError, JavaScriptEvaluationId,
MediaSessionEvent, NewWebViewDetails, TraversalId,
};
use servo_base::generic_channel::GenericSender;
use servo_base::id::{PipelineId, WebViewId};
use servo_url::ServoUrl;
/// Messages sent from the `Constellation` to the embedder.
pub enum ConstellationToEmbedderMsg {
/// Informs the embedder that the constellation has completed shutdown.
/// Required because the constellation can have pending calls to make
/// (e.g. SetFrameTree) at the time that we send it an ExitMsg.
ShutdownComplete,
/// Report a complete sampled profile
ReportProfile(Vec<u8>),
/// All webviews lost focus for keyboard events.
WebViewBlurred,
/// A history traversal operation completed.
HistoryTraversalComplete(WebViewId, TraversalId),
/// Notifies the embedder about media session events
/// (i.e. when there is metadata for the active media session, playback state changes...).
MediaSessionEvent(WebViewId, MediaSessionEvent),
/// A pipeline panicked. First string is the reason, second one is the backtrace.
Panic(WebViewId, String, Option<String>),
/// A webview potentially gained focus for keyboard events.
/// If the boolean value is false, the webiew could not be focused.
WebViewFocused(WebViewId, bool),
/// Inform the embedding layer that a particular `InputEvent` was handled by Servo
/// and the embedder can continue processing it, if necessary.
InputEventsHandled(WebViewId, Vec<InputEventOutcome>),
/// A webview was destroyed.
WebViewClosed(WebViewId),
/// Inform the embedding layer that a JavaScript evaluation has
/// finished with the given result.
FinishJavaScriptEvaluation(
JavaScriptEvaluationId,
Result<JSValue, JavaScriptEvaluationError>,
),
/// Whether or not to allow script to open a new tab/browser
AllowOpeningWebView(WebViewId, GenericSender<Option<NewWebViewDetails>>),
/// Whether or not to allow a pipeline to load a url.
AllowNavigationRequest(WebViewId, PipelineId, ServoUrl),
/// The history state has changed.
HistoryChanged(WebViewId, Vec<ServoUrl>, usize),
}

View File

@@ -11,9 +11,6 @@ use std::marker::PhantomData;
use std::rc::Rc;
use background_hang_monitor_api::{BackgroundHangMonitorControlMsg, HangMonitorAlert};
use base::generic_channel::{self, GenericReceiver, GenericSender, SendError};
use base::id::ScriptEventLoopId;
use constellation_traits::ServiceWorkerManagerFactory;
use embedder_traits::ScriptToEmbedderChan;
use ipc_channel::IpcError;
use layout_api::ScriptThreadFactory;
@@ -21,8 +18,11 @@ use log::error;
use media::WindowGLContext;
use script_traits::{InitialScriptState, ScriptThreadMessage};
use serde::{Deserialize, Serialize};
use servo_base::generic_channel::{self, GenericReceiver, GenericSender, SendError};
use servo_base::id::ScriptEventLoopId;
use servo_config::opts::{self, Opts};
use servo_config::prefs::{self, Preferences};
use servo_constellation_traits::ServiceWorkerManagerFactory;
use crate::sandboxing::spawn_multiprocess;
use crate::{Constellation, UnprivilegedContent};
@@ -68,7 +68,7 @@ impl EventLoop {
is_private: bool,
) -> Result<Rc<Self>, IpcError> {
let (script_chan, script_port) =
base::generic_channel::channel().expect("Pipeline script chan");
servo_base::generic_channel::channel().expect("Pipeline script chan");
let embedder_chan = constellation.embedder_proxy.sender.clone();
let eventloop_waker = constellation.embedder_proxy.event_loop_waker.clone();
@@ -111,7 +111,6 @@ impl EventLoop {
player_context: WindowGLContext::get(),
privileged_urls: constellation.privileged_urls.clone(),
user_contents_for_manager_id: constellation.user_contents_for_manager_id.clone(),
accessibility_active: constellation.accessibility_active,
};
let event_loop = if opts::get().multiprocess {

View File

@@ -11,6 +11,7 @@ mod broadcastchannel;
mod browsingcontext;
mod constellation;
mod constellation_webview;
mod embedder;
mod event_loop;
mod logging;
mod pipeline;
@@ -20,6 +21,7 @@ mod serviceworker;
mod session_history;
pub use crate::constellation::{Constellation, InitialConstellationState};
pub use crate::embedder::ConstellationToEmbedderMsg;
pub use crate::event_loop::{EventLoop, NewScriptEventLoopProcessInfo};
pub use crate::logging::{FromEmbedderLogger, FromScriptLogger};
pub use crate::sandboxing::{UnprivilegedContent, content_process_sandbox_profile};

View File

@@ -11,14 +11,14 @@ use std::sync::Arc;
use std::thread;
use backtrace::Backtrace;
use base::id::{ScriptEventLoopId, TEST_PIPELINE_ID, TEST_WEBVIEW_ID};
use constellation_traits::{
EmbedderToConstellationMessage, LogEntry, ScriptToConstellationMessage,
ScriptToConstellationSender,
};
use crossbeam_channel::Sender;
use log::{Level, LevelFilter, Log, Metadata, Record};
use parking_lot::ReentrantMutex;
use servo_base::id::{ScriptEventLoopId, TEST_PIPELINE_ID, TEST_WEBVIEW_ID};
use servo_constellation_traits::{
EmbedderToConstellationMessage, LogEntry, ScriptToConstellationMessage,
ScriptToConstellationSender,
};
/// A logger directed at the constellation from content processes
/// #[derive(Clone)]

View File

@@ -5,9 +5,6 @@
use std::collections::HashSet;
use std::rc::Rc;
use base::generic_channel::SendError;
use base::id::{BrowsingContextId, HistoryStateId, PipelineId, WebViewId};
use constellation_traits::{LoadData, ServiceWorkerManagerFactory};
use embedder_traits::{AnimationState, FocusSequenceNumber};
use layout_api::ScriptThreadFactory;
use log::{debug, error, warn};
@@ -15,6 +12,9 @@ use paint_api::{CompositionPipeline, PaintMessage, PaintProxy};
use script_traits::{
DiscardBrowsingContext, DocumentActivity, NewPipelineInfo, ScriptThreadMessage,
};
use servo_base::generic_channel::SendError;
use servo_base::id::{BrowsingContextId, HistoryStateId, PipelineId, WebViewId};
use servo_constellation_traits::{LoadData, ServiceWorkerManagerFactory};
use servo_url::ServoUrl;
use crate::Constellation;

View File

@@ -65,6 +65,7 @@ impl ProcessManager {
receiver
}
#[servo_tracing::instrument(skip_all)]
pub fn remove(&mut self, index: usize) {
let (mut process, _) = self.processes.swap_remove(index);
debug!("Removing process pid={}", process.pid());

View File

@@ -2,13 +2,13 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use base::generic_channel::GenericSender;
use constellation_traits::{SWManagerSenders, ServiceWorkerManagerFactory};
use ipc_channel::IpcError;
use serde::{Deserialize, Serialize};
use servo_base::generic_channel::GenericSender;
use servo_config::opts::{self, Opts};
use servo_config::prefs;
use servo_config::prefs::Preferences;
use servo_constellation_traits::{SWManagerSenders, ServiceWorkerManagerFactory};
use servo_url::ImmutableOrigin;
use crate::process_manager::Process;

View File

@@ -5,10 +5,10 @@
use std::cmp::PartialEq;
use std::fmt;
use base::id::{BrowsingContextId, HistoryStateId, PipelineId, WebViewId};
use constellation_traits::LoadData;
use embedder_traits::ViewportDetails;
use log::debug;
use servo_base::id::{BrowsingContextId, HistoryStateId, PipelineId, WebViewId};
use servo_constellation_traits::LoadData;
use servo_url::ServoUrl;
use crate::browsingcontext::NewBrowsingContextInfo;

View File

@@ -46,7 +46,7 @@ mod from_embedder {
};
}
impl LogTarget for constellation_traits::EmbedderToConstellationMessage {
impl LogTarget for servo_constellation_traits::EmbedderToConstellationMessage {
fn log_target(&self) -> &'static str {
match self {
Self::Exit => target!("Exit"),
@@ -120,7 +120,7 @@ mod from_script {
};
}
impl LogTarget for constellation_traits::ScriptToConstellationMessage {
impl LogTarget for servo_constellation_traits::ScriptToConstellationMessage {
fn log_target(&self) -> &'static str {
match self {
Self::CompleteMessagePortTransfer(..) => target!("CompleteMessagePortTransfer"),
@@ -141,13 +141,18 @@ mod from_script {
target!("RemoveBroadcastChannelNameInRouter")
},
Self::ScheduleBroadcast(..) => target!("ScheduleBroadcast"),
Self::RegisterInterest(..) => target!("RegisterInterest"),
Self::UnregisterInterest(..) => target!("UnregisterInterest"),
Self::BroadcastStorageEvent(..) => target!("BroadcastStorageEvent"),
Self::ChangeRunningAnimationsState(..) => target!("ChangeRunningAnimationsState"),
Self::CreateCanvasPaintThread(..) => target!("CreateCanvasPaintThread"),
Self::Focus(..) => target!("Focus"),
Self::FocusRemoteDocument(..) => target!("FocusRemoteDocument"),
Self::FocusAncestorBrowsingContextsForFocusingSteps(..) => {
target!("FocusAncestorBrowsingContextsForFocusingSteps")
},
Self::FocusRemoteBrowsingContext(..) => target!("FocusRemoteBrowsingContext"),
Self::GetTopForBrowsingContext(..) => target!("GetTopForBrowsingContext"),
Self::GetBrowsingContextInfo(..) => target!("GetBrowsingContextInfo"),
Self::GetDocumentOrigin(..) => target!("GetDocumentOrigin"),
Self::GetChildBrowsingContextId(..) => target!("GetChildBrowsingContextId"),
Self::LoadComplete => target!("LoadComplete"),
Self::LoadUrl(..) => target!("LoadUrl"),
@@ -186,6 +191,8 @@ mod from_script {
target!("RespondToScreenshotReadinessRequest")
},
Self::TriggerGarbageCollection => target!("TriggerGarbageCollection"),
Self::AcquireWakeLock(..) => target!("AcquireWakeLock"),
Self::ReleaseWakeLock(..) => target!("ReleaseWakeLock"),
}
}
}

View File

@@ -0,0 +1,16 @@
[package]
name = "servo-default-resources"
version.workspace = true
authors.workspace = true
repository.workspace = true
description.workspace = true
license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
[lib]
path = "lib.rs"
[dependencies]
embedder_traits = { workspace = true }

View File

@@ -0,0 +1,39 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use std::path::PathBuf;
use embedder_traits::resources::{Resource, ResourceReaderMethods};
/// A default resource reader that provides baked in resources.
pub struct DefaultResourceReader;
impl ResourceReaderMethods for DefaultResourceReader {
fn sandbox_access_files(&self) -> Vec<PathBuf> {
vec![]
}
fn sandbox_access_files_dirs(&self) -> Vec<PathBuf> {
vec![]
}
fn read(&self, file: Resource) -> Vec<u8> {
match file {
Resource::BluetoothBlocklist => &include_bytes!("resources/gatt_blocklist.txt")[..],
Resource::DomainList => &include_bytes!("resources/public_domains.txt")[..],
Resource::HstsPreloadList => &include_bytes!("resources/hsts_preload.fstmap")[..],
Resource::BadCertHTML => &include_bytes!("resources/badcert.html")[..],
Resource::NetErrorHTML => &include_bytes!("resources/neterror.html")[..],
Resource::BrokenImageIcon => &include_bytes!("resources/rippy.png")[..],
Resource::CrashHTML => &include_bytes!("resources/crash.html")[..],
Resource::DirectoryListingHTML => {
&include_bytes!("resources/directory-listing.html")[..]
},
Resource::AboutMemoryHTML => &include_bytes!("resources/about-memory.html")[..],
Resource::DebuggerJS => &include_bytes!("resources/debugger.js")[..],
Resource::JsonViewerHTML => &include_bytes!("resources/json-viewer.html")[..],
}
.to_owned()
}
}
embedder_traits::submit_resource_reader!(&DefaultResourceReader);

View File

@@ -0,0 +1,611 @@
if ("dbg" in this) {
throw new Error("Debugger script must not run more than once!");
}
const dbg = new Debugger;
const debuggeesToPipelineIds = new Map;
const debuggeesToWorkerIds = new Map;
const sourceIdsToScripts = new Map;
const frameActorsToFrames = new Map;
const environmentActorsToEnvironments = new Map;
// <https://searchfox.org/firefox-main/source/devtools/server/actors/thread.js#155>
// Possible values for the `why.type` attribute in "paused" event
const PAUSE_REASONS = {
INTERRUPTED: "interrupted", // Associated with why.onNext attribute
RESUME_LIMIT: "resumeLimit",
};
// Find script by scriptId within a script tree
function findScriptById(script, scriptId) {
if (script.sourceStart === scriptId) {
return script;
}
for (const child of script.getChildScripts()) {
const found = findScriptById(child, scriptId);
if (found) return found;
}
return null;
}
// Walk script tree and call callback for each script
function walkScriptTree(script, callback) {
callback(script);
for (const child of script.getChildScripts()) {
walkScriptTree(child, callback);
}
}
// Find a key by a value in a map
function findKeyByValue(map, search) {
for (const [key, value] of map) {
if (value === search) return key;
}
return undefined;
}
dbg.uncaughtExceptionHook = function(error) {
console.error(`[debugger] Uncaught exception at ${error.fileName}:${error.lineNumber}:${error.columnNumber}: ${error.name}: ${error.message}`);
};
dbg.onNewScript = function(script) {
// TODO: handle wasm (`script.source.introductionType == wasm`)
sourceIdsToScripts.set(script.source.id, script);
notifyNewSource({
pipelineId: debuggeesToPipelineIds.get(script.global),
workerId: debuggeesToWorkerIds.get(script.global),
spidermonkeyId: script.source.id,
url: script.source.url,
urlOverride: script.source.displayURL,
text: script.source.text,
introductionType: script.source.introductionType ?? null,
});
};
// Track a new debuggee global
addEventListener("addDebuggee", event => {
const {global, pipelineId, workerId} = event;
const debuggerObject = dbg.addDebuggee(global);
debuggeesToPipelineIds.set(debuggerObject, pipelineId);
if (workerId !== undefined) {
debuggeesToWorkerIds.set(debuggerObject, workerId);
}
});
// <https://searchfox.org/mozilla-central/source/devtools/server/actors/object/previewers.js#80>
const previewers = {
Function: [],
Array: [],
Object: [],
// TODO: Add Map, FormData etc
};
// Convert debuggee value to property descriptor value
// <https://searchfox.org/firefox-main/source/devtools/server/actors/object/utils.js#116>
function createValueGrip(value, depth = 0) {
switch (typeof value) {
case "undefined":
return { valueType: "undefined" };
case "boolean":
return { valueType: "boolean", booleanValue: value };
case "number":
if (value === Infinity) {
return { valueType: "Infinity" };
} else if (value === -Infinity) {
return { valueType: "-Infinity" };
} else if (Number.isNaN(value)) {
return { valueType: "NaN" };
} else if (Object.is(value, -0)) {
return { valueType: "-0" };
}
return { valueType: "number", numberValue: value };
case "string":
return { valueType: "string", stringValue: value };
case "object":
if (value === null) {
return { valueType: "null" };
}
// Debugger.Object - get preview using registered previewers
// <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.object/index.html>
return {
valueType: "object",
objectClass: value.class,
preview: getPreview(value, depth),
};
default:
return { valueType: "string", stringValue: String(value) };
}
}
// Extract own properties from a debuggee object
// <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.object/index.html#function-properties-of-the-debugger-object-prototype>
function extractOwnProperties(obj, depth) {
const ownProperties = [];
let totalLength = 0;
let names;
try {
names = obj.getOwnPropertyNames();
totalLength = names.length;
} catch (e) {
return { ownProperties, ownPropertiesLength: 0 };
}
for (const name of names) {
try {
const desc = obj.getOwnPropertyDescriptor(name);
if (desc) {
const prop = {
name: name,
configurable: desc.configurable ?? false,
enumerable: desc.enumerable ?? false,
writable: desc.writable ?? false,
isAccessor: desc.get !== undefined || desc.set !== undefined,
value: createValueGrip(undefined, depth + 1),
};
if (desc.value !== undefined) {
prop.value = createValueGrip(desc.value, depth + 1);
} else if (desc.get) {
try {
const result = desc.get.call(obj);
if (result && "return" in result) {
prop.value = createValueGrip(result.return, depth + 1);
}
} catch (e) { }
}
ownProperties.push(prop);
}
} catch (e) {
// For now skip properties that throw on access
}
}
return { ownProperties, ownPropertiesLength: totalLength };
}
// <https://searchfox.org/mozilla-central/source/devtools/server/actors/object/previewers.js#125>
previewers.Function.push(function FunctionPreviewer(obj, depth) {
const { ownProperties, ownPropertiesLength } = extractOwnProperties(obj, depth);
let function_details = {
name: obj.name,
displayName: obj.displayName,
parameterNames: obj.parameterNames ? obj.parameterNames: [],
isAsync: obj.isAsyncFunction,
isGenerator: obj.isGeneratorFunction,
}
if (depth > 1) {
return { kind: "Object", function: function_details, ownPropertiesLength };
}
return {
kind: "Object",
ownProperties,
ownPropertiesLength,
function: function_details
};
});
// <https://searchfox.org/mozilla-central/source/devtools/server/actors/object/previewers.js#172>
previewers.Array.push(function ArrayPreviewer(obj, depth) {
const lengthDescriptor = obj.getOwnPropertyDescriptor("length");
const length = lengthDescriptor ? lengthDescriptor.value : 0;
if (depth > 1) {
return {
kind: "ArrayLike",
arrayLength: length,
};
}
const items = [];
for (let i = 0; i < length; i++) {
try {
const desc = obj.getOwnPropertyDescriptor(i);
if (desc && desc.value !== undefined) {
const grip = createValueGrip(desc.value, depth);
delete grip.preview;
items.push(grip);
}
} catch (e) {
// For now skip properties that throw on access
}
}
return {
kind: "ArrayLike",
arrayLength: length,
items: items,
};
});
// Generic fallback for object previewer
// <https://searchfox.org/mozilla-central/source/devtools/server/actors/object/previewers.js#856>
previewers.Object.push(function ObjectPreviewer(obj, depth) {
const { ownProperties, ownPropertiesLength } = extractOwnProperties(obj, depth);
if (depth > 1) {
return { kind: "Object", ownPropertiesLength };
}
return {
kind: "Object",
ownProperties,
ownPropertiesLength,
};
});
function getPreview(obj, depth) {
const className = obj.class;
// <https://searchfox.org/mozilla-central/source/devtools/server/actors/object.js#295>
const typePreviewers = previewers[className] || previewers.Object;
for (const previewer of typePreviewers) {
const result = previewer(obj, depth);
if (result) return result;
}
return { ownProperties: [], ownPropertiesLength: 0 };
}
// Evaluate some javascript code in the global context of the debuggee
// See executeInGlobal() at <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.object/index.html#function-properties-of-the-debugger-object-prototype>
addEventListener("eval", event => {
const {code, pipelineId, workerId, frameActorId} = event;
let completionValue;
if (frameActorId) {
const frame = frameActorsToFrames.get(frameActorId);
// <https://searchfox.org/firefox-main/source/js/src/doc/Debugger/Debugger.Frame.md#223>
if (frame?.onStack) {
completionValue = frame.eval(code);
} else {
completionValue = { throw: "Frame not available" };
}
} else {
const object = workerId !== undefined ?
findKeyByValue(debuggeesToWorkerIds, workerId) :
findKeyByValue(debuggeesToPipelineIds, pipelineId);
completionValue = object.executeInGlobal(code);
}
// Completion values: <https://firefox-source-docs.mozilla.org/devtools/backend/protocol.html#completion-values>
let resultValue;
if (completionValue === null) {
resultValue = { completionType: "terminated", value: createValueGrip(undefined), hasException: false };
} else if ("throw" in completionValue) {
// See adoptDebuggeeValue() in <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger/index.html>
// <https://searchfox.org/firefox-main/source/devtools/server/actors/webconsole/eval-with-debugger.js#312>
// we probably don't need adoptDebuggeeValue, as we only have one debugger instance for now
// let value = dbg.adoptDebuggeeValue(completionValue.throw);
resultValue = { completionType: "throw", value: createValueGrip(completionValue.throw), hasException: true };
} else if ("return" in completionValue) {
resultValue = { completionType: "return", value: createValueGrip(completionValue.return), hasException: false };
}
// To avoid recursion errors in the WebIDL, preview needs to live outside of the property descriptor
if (resultValue.value.preview) {
resultValue.preview = resultValue.value.preview;
delete resultValue.value.preview;
}
evalResult(event, resultValue);
});
addEventListener("getPossibleBreakpoints", event => {
const {spidermonkeyId} = event;
const script = sourceIdsToScripts.get(spidermonkeyId);
const result = [];
walkScriptTree(script, (currentScript) => {
for (const location of currentScript.getPossibleBreakpoints()) {
location["scriptId"] = currentScript.sourceStart;
result.push(location);
}
});
getPossibleBreakpointsResult(event, result);
});
function createFrameActor(frame, pipelineId) {
let frameActorId = findKeyByValue(frameActorsToFrames, frame);
if (!frameActorId) {
// TODO: Check if we already have an actor for this frame
frameActorId = registerFrameActor(pipelineId, {
// TODO: Some properties throw if terminated is true
// TODO: arguments: frame.arguments,
displayName: frame.script.displayName,
onStack: frame.onStack,
oldest: frame.older == null,
terminated: frame.terminated,
type_: frame.type,
url: frame.script.url,
});
if (!frameActorId) {
console.error("[debugger] Couldn't create frame");
return undefined;
}
frameActorsToFrames.set(frameActorId, frame);
}
return frameActorId;
}
function handlePauseAndRespond(frame, pauseReason) {
dbg.onEnterFrame = undefined;
clearSteppingHooks(frame);
// Get the pipeline ID for this debuggee
const pipelineId = debuggeesToPipelineIds.get(frame.script.global);
if (!pipelineId) {
console.error("[debugger] No pipeline ID for frame's global");
return undefined;
}
let frameActorId = createFrameActor(frame, pipelineId);
// <https://github.com/mozilla-firefox/firefox/blob/63719d122f9214f37fd1d285a91897b8345b88b0/js/src/doc/Debugger/Debugger.Script.md?plain=1#L293-L303>
const offset = frame.offset;
const offsetMetadata = frame.script.getOffsetMetadata(offset);
const frameOffset = {
frameActorId,
column: offsetMetadata.columnNumber - 1,
line: offsetMetadata.lineNumber
};
// Notify devtools and enter pause loop. This blocks until Resume.
pauseAndRespond(
pipelineId,
frameOffset,
pauseReason
);
// <https://web.archive.org/web/20251212212538/https://firefox-source-docs.mozilla.org/js/Debugger/Conventions.html#resumption-values>
// Return undefined to continue execution normally after resume.
return undefined;
}
addEventListener("frames", event => {
const {pipelineId, start, count} = event;
let frameList = handleListFrames(pipelineId, start, count);
listFramesResult(frameList);
})
// <https://searchfox.org/firefox-main/source/devtools/server/actors/thread.js#1425>
function handleListFrames(pipelineId, start, count) {
let frame = dbg.getNewestFrame()
const walkToParentFrame = () => {
if (!frame) {
return;
}
const currentFrame = frame;
frame = null;
if (currentFrame.older) {
frame = currentFrame.older;
}
}
let i = 0;
while (frame && i < start) {
walkToParentFrame();
i++;
}
// Return count frames, or all remaining frames if count is not defined.
const frames = [];
for (; frame && (!count || i < start + count); i++, walkToParentFrame()) {
const frameActorId = createFrameActor(frame, pipelineId);
frames.push(frameActorId);
}
return frames;
}
addEventListener("setBreakpoint", event => {
const {spidermonkeyId, scriptId, offset} = event;
const script = sourceIdsToScripts.get(spidermonkeyId);
const target = findScriptById(script, scriptId);
if (target) {
target.setBreakpoint(offset, {
// setBreakpoint(offset, handler) in <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.script/index.html#function-properties-of-the-debugger-script-prototype-object>
// The hit handler receives a Debugger.Frame instance representing the currently executing stack frame.
hit: (frame) => handlePauseAndRespond(frame, {type_: "breakpoint"})
});
}
});
// <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.frame/index.html>
addEventListener("interrupt", event => {
dbg.onEnterFrame = (frame) => handlePauseAndRespond(
frame,
{ type_: PAUSE_REASONS.INTERRUPTED, onNext: true }
);
});
function makeSteppingHooks(steppingType, startFrame) {
return {
onEnterFrame: (frame) => {
const { onStep, onPop } = makeSteppingHooks("next", frame);
frame.onStep = onStep;
frame.onPop = onPop;
},
onStep: () => {
const meta = startFrame.script.getOffsetMetadata(startFrame.offset);
if (meta.isBreakpoint && meta.isStepStart) {
return handlePauseAndRespond(startFrame, { type_: PAUSE_REASONS.RESUME_LIMIT });
}
},
onPop: (completion) => {
this.reportedPop = true;
suspendedFrame = startFrame;
if (steppingType !== "finish") {
// TODO: completion contains the return value, we have to send it back
// <https://searchfox.org/firefox-main/source/devtools/server/actors/thread.js#1026>
return handlePauseAndRespond(startFrame, { type_: steppingType });
}
attachSteppingHooks("next", startFrame);
},
}
}
function getNextStepFrame(frame) {
const endOfFrame = frame.reportedPop;
const stepFrame = endOfFrame ? frame.older : frame;
if (!stepFrame || !stepFrame.script) {
return null;
}
return stepFrame;
}
// <https://searchfox.org/firefox-main/source/devtools/server/actors/thread.js#1235>
function attachSteppingHooks(steppingType, frame) {
if (steppingType === "finish" && frame.reportedPop) {
steppingType = "next";
}
const stepFrame = getNextStepFrame(frame);
if (!stepFrame) {
steppingType = "step";
}
const { onEnterFrame, onStep, onPop } = makeSteppingHooks(
steppingType,
frame,
);
if (steppingType === "step") {
dbg.onEnterFrame = onEnterFrame;
}
if (stepFrame) {
switch (steppingType) {
case "step":
case "next":
if (stepFrame.script) {
stepFrame.onStep = onStep;
}
case "finish":
stepFrame.onPop = onPop;
break;
}
}
}
function clearSteppingHooks(suspendedFrame) {
if (suspendedFrame) {
suspendedFrame.onStep = undefined;
suspendedFrame.onPop = undefined;
}
let frame = this.youngestFrame;
if (frame?.onStack) {
while (frame) {
frame.onStep = undefined;
frame.onPop = undefined;
frame = frame.older;
}
}
}
// <https://firefox-source-docs.mozilla.org/devtools/backend/protocol.html#resuming-a-thread>
addEventListener("resume", event => {
const {resumeLimitType: steppingType, frameActorID} = event;
let frame = dbg.getNewestFrame();
if (frameActorID) {
frame = frameActorsToFrames.get(frameActorID);
if (!frame) {
console.error("[debugger] Couldn't find frame");
}
}
if (steppingType) {
attachSteppingHooks(steppingType, frame);
} else {
clearSteppingHooks(frame);
}
});
// <https://firefox-source-docs.mozilla.org/devtools-user/debugger-api/debugger.script/index.html#function-properties-of-the-debugger-script-prototype-object>
// There may be more than one breakpoint at the same offset with different handlers, but we dont handle that case for now.
addEventListener("clearBreakpoint", event => {
const {spidermonkeyId, scriptId, offset} = event;
const script = sourceIdsToScripts.get(spidermonkeyId);
const target = findScriptById(script, scriptId);
if (target) {
// If the instance refers to a JSScript, remove all breakpoints set in this script at that offset.
target.clearAllBreakpoints(offset);
}
});
// TODO: Get variables (scopes don't show if they don't have a variable)
function createEnvironmentActor(environment) {
let actor = findKeyByValue(environmentActorsToEnvironments, environment);
if (!actor) {
let info = {};
if (environment.type == "declarative") {
info.type_ = environment.calleeScript ? "function" : "block";
} else {
info.type_ = environment.type;
}
info.scopeKind = environment.scopeKind;
if (environment.calleeScript) {
info.functionDisplayName = environment.calleeScript.displayName;
}
let parent = null;
if (environment.parent) {
parent = createEnvironmentActor(environment.parent);
}
if (environment.type == "declarative") {
info.bindingVariables = buildBindings(environment)
}
actor = registerEnvironmentActor(info, parent);
environmentActorsToEnvironments.set(actor, environment);
}
return actor;
}
function buildBindings(environment) {
let bindingVars = [];
for (const name of environment.names()) {
const value = environment.getVariable(name);
const property = {
name: name,
configurable: false,
enumerable: true,
writable: !value?.optimizedOut,
isAccessor: false,
value: createValueGrip(value),
};
// To avoid recursion errors in the WebIDL, preview needs to live outside of the property descriptor
let preview = undefined;
if (property.value.preview) {
preview = property.value.preview;
delete property.value.preview;
}
bindingVars.push({ property, preview });
}
return bindingVars;
}
// Get a `Debugger.Environment` instance within which evaluation is taking place.
// <https://searchfox.org/firefox-main/source/devtools/server/actors/frame.js#109>
addEventListener("getEnvironment", event => {
const {frameActorId} = event;
frame = frameActorsToFrames.get(frameActorId);
const actor = createEnvironmentActor(frame.environment);
getEnvironmentResult(actor);
});

View File

@@ -0,0 +1,269 @@
<html>
<head>
<style>
body {
font-family: monospace;
margin: 0;
padding: 0;
background: #fff;
color: #333;
}
#json-raw {
display: none;
}
#viewer {
display: none;
padding: 0.5em 1em;
line-height: 1.5;
&.active {
display: block;
}
}
#toolbar {
display: flex;
gap: 1em;
padding: 0.5em;
align-items: center;
background: #f5f5f5;
border-bottom: 1px solid #ddd;
& button {
min-width: 5em;
&.active {
background: #ddd;
font-weight: bold;
}
}
}
#raw-view {
display: none;
padding: 0.5em 1em;
white-space: pre-wrap;
word-break: break-all;
&.active {
display: block;
}
}
.json-error {
padding: 0.5em 1em;
color: #c00;
font-weight: bold;
}
/* Syntax highlighting for Json data types */
.json-key {
color: #881391;
}
.json-string {
color: #1a1aa6;
}
.json-number {
color: #1c00cf;
}
.json-boolean {
color: #0d22aa;
}
.json-null {
color: #808080;
}
/* Collapsible tree */
.toggle {
cursor: pointer;
user-select: none;
&::before {
content: "\25BC";
display: inline-block;
width: 1em;
transition: transform 0.1s;
}
&.collapsed::before {
transform: rotate(-90deg);
}
}
.collapsible {
margin-left: 1.5em;
&.hidden {
display: none;
}
}
.bracket {
color: #333;
}
.comma {
color: #333;
}
.line {
padding-left: 0;
}
</style>
<script>
// Shortcut to create an element with an optional class and text content.
function createElement(name, classes = null, textContent = null) {
let node = document.createElement(name);
if (classes) {
node.className = classes;
}
if (textContent) {
node.textContent = textContent;
}
return node;
}
function renderNode(value, container) {
if (value === null) {
let s = createElement("span", "json-null", "null");
container.append(s);
} else if (typeof value === "boolean") {
let s = createElement("span", "json-boolean", String(value));
container.append(s);
} else if (typeof value === "number") {
let s = createElement("span", "json-number", String(value));
container.append(s);
} else if (typeof value === "string") {
let s = createElement("span", "json-string", JSON.stringify(value));
container.append(s);
} else if (Array.isArray(value)) {
renderArray(value, container);
} else if (typeof value === "object") {
renderObject(value, container);
}
}
function renderObject(obj, container) {
let keys = Object.keys(obj);
if (keys.length === 0) {
container.append(createElement("span", "bracket", "{}"));
return;
}
let toggle = createElement("span", "toggle");
container.append(toggle);
container.append(createElement("span", "bracket", "{"));
let inner = createElement("div", "collapsible");
container.append(inner);
keys.forEach((key, i) => {
let line = createElement("div", "line");
line.append(createElement("span", "json-key", JSON.stringify(key)));
line.append(document.createTextNode(": "));
renderNode(obj[key], line);
if (i < keys.length - 1) {
line.append(createElement("span", "comma", ","));
}
inner.append(line);
});
container.append(createElement("span", "bracket", "}"));
toggle.onclick = function () {
toggle.classList.toggle("collapsed");
inner.classList.toggle("hidden");
};
}
function renderArray(arr, container) {
if (arr.length === 0) {
container.append(createElement("span", "bracket", "[]"));
return;
}
let toggle = createElement("span", "toggle");
container.append(toggle);
container.append(createElement("span", "bracket", "["));
let inner = createElement("div", "collapsible");
container.append(inner);
arr.forEach((item, i) => {
let line = createElement("div", "line");
renderNode(item, line);
if (i < arr.length - 1) {
line.append(createElement("span", "comma", ","));
}
inner.append(line);
});
container.append(createElement("span", "bracket", "]"));
toggle.onclick = function () {
toggle.classList.toggle("collapsed");
inner.classList.toggle("hidden");
};
}
document.addEventListener("DOMContentLoaded", function () {
const viewer = document.getElementById("viewer");
const prettyButton = document.getElementById("pretty-toggle");
const rawButton = document.getElementById("raw-toggle");
const rawView = document.getElementById("raw-view");
const rawText = rawView.innerText;
let data;
let parseError = null;
try {
data = JSON.parse(rawText);
} catch (e) {
parseError = e;
}
if (parseError) {
let errDiv = createElement(
"div",
"json-error",
"Invalid JSON: " + parseError.message,
);
viewer.append(errDiv);
viewer.append(createElement("pre", null, rawText));
} else {
renderNode(data, viewer);
rawView.textContent = JSON.stringify(data, null, 2);
}
// Toggle buttons
prettyButton.onclick = function () {
viewer.classList.add("active");
rawView.classList.remove("active");
prettyButton.classList.add("active");
rawButton.classList.remove("active");
};
rawButton.onclick = function () {
rawView.classList.add("active");
viewer.classList.remove("active");
rawButton.classList.add("active");
prettyButton.classList.remove("active");
};
});
</script>
</head>
<body>
<div id="toolbar">
<button id="pretty-toggle" class="active">Pretty</button>
<button id="raw-toggle">Raw</button>
</div>
<div id="viewer" class="active"></div>
<pre id="raw-view">

View File

Before

Width:  |  Height:  |  Size: 144 B

After

Width:  |  Height:  |  Size: 144 B

View File

@@ -6,6 +6,8 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
path = "lib.rs"

View File

@@ -6,6 +6,8 @@ license.workspace = true
edition.workspace = true
publish.workspace = true
rust-version.workspace = true
repository.workspace = true
description.workspace = true
[lib]
name = "devtools"
@@ -13,7 +15,6 @@ path = "lib.rs"
[dependencies]
atomic_refcell = { workspace = true }
base = { workspace = true }
base64 = { workspace = true }
chrono = { workspace = true }
crossbeam-channel = { workspace = true }
@@ -24,15 +25,16 @@ http = { workspace = true }
log = { workspace = true }
malloc_size_of = { workspace = true }
malloc_size_of_derive = { workspace = true }
net = { package = "servo-net", path = "../net" }
net = { workspace = true }
net_traits = { workspace = true }
profile_traits = { workspace = true }
rand = { workspace = true }
rustc-hash = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
servo_config = { package = "servo-config", path = "../config" }
servo_url = { package = "servo-url", path = "../url" }
servo-base = { workspace = true }
servo-config = { workspace = true }
servo-url = { workspace = true }
uuid = { workspace = true }
[build-dependencies]

View File

@@ -5,20 +5,19 @@
use std::any::{Any, type_name};
use std::collections::HashMap;
use std::marker::PhantomData;
use std::net::TcpStream;
use std::sync::Arc;
use std::sync::atomic::{AtomicU32, Ordering};
use atomic_refcell::AtomicRefCell;
use base::id::PipelineId;
use log::{debug, warn};
use malloc_size_of::MallocSizeOf;
use malloc_size_of_derive::MallocSizeOf;
use serde::Serialize;
use serde_json::{Map, Value, json};
use servo_base::id::PipelineId;
use crate::StreamId;
use crate::protocol::{ClientRequest, JsonPacketStream};
use crate::protocol::{ClientRequest, DevtoolsConnection, JsonPacketStream};
/// Error replies.
///
@@ -50,7 +49,6 @@ impl ActorError {
/// A common trait for all devtools actors that encompasses an immutable name
/// and the ability to process messages that are directed to particular actors.
/// TODO: ensure the name is immutable
pub(crate) trait Actor: Any + ActorAsAny + Send + Sync + MallocSizeOf {
fn handle_message(
&self,
@@ -158,11 +156,19 @@ impl ActorRegistry {
}
/// Create a unique name based on a monotonically increasing suffix
/// TODO: Merge this with `register/register_later` and don't allow to
/// TODO: Merge this with `register` and don't allow to
/// create new names without registering an actor.
pub fn new_name<T: Actor>(&self) -> String {
let suffix = self.next.fetch_add(1, Ordering::Relaxed);
format!("{}{}", Self::base_name::<T>(), suffix)
let base = Self::base_name::<T>();
// Firefox DevTools client requires "/workerTarget" in actor name to recognize workers
// <https://searchfox.org/firefox-main/source/devtools/client/fronts/watcher.js#65>
if base.contains("WorkerTarget") {
format!("/workerTarget{}", suffix)
} else {
format!("{}{}", base, suffix)
}
}
/// Add an actor to the registry of known actors that can receive messages.
@@ -198,7 +204,7 @@ impl ActorRegistry {
pub(crate) fn handle_message(
&self,
msg: &Map<String, Value>,
stream: &mut TcpStream,
stream: &mut DevtoolsConnection,
stream_id: StreamId,
) -> Result<(), ()> {
let to = match msg.get("to") {
@@ -221,7 +227,7 @@ impl ActorRegistry {
},
Some(actor) => {
let msg_type = msg.get("type").unwrap().as_str().unwrap();
if let Err(error) = ClientRequest::handle(stream, to, |req| {
if let Err(error) = ClientRequest::handle(stream.clone(), to, |req| {
actor.handle_message(req, self, msg_type, msg, stream_id)
}) {
// <https://firefox-source-docs.mozilla.org/devtools/backend/protocol.html#error-packets>

View File

@@ -0,0 +1,34 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use malloc_size_of_derive::MallocSizeOf;
use crate::ActorMsg;
use crate::actor::{Actor, ActorEncode, ActorRegistry};
#[derive(MallocSizeOf)]
pub(crate) struct BlackboxingActor {
name: String,
}
impl Actor for BlackboxingActor {
fn name(&self) -> String {
self.name.clone()
}
}
impl BlackboxingActor {
pub fn register(registry: &ActorRegistry) -> String {
let name = registry.new_name::<Self>();
let actor = Self { name: name.clone() };
registry.register::<Self>(actor);
name
}
}
impl ActorEncode<ActorMsg> for BlackboxingActor {
fn encode(&self, _: &ActorRegistry) -> ActorMsg {
ActorMsg { actor: self.name() }
}
}

View File

@@ -30,7 +30,7 @@ struct BreakpointRequest {
#[derive(MallocSizeOf)]
pub(crate) struct BreakpointListActor {
name: String,
browsing_context: String,
browsing_context_name: String,
}
impl Actor for BreakpointListActor {
@@ -60,10 +60,11 @@ impl Actor for BreakpointListActor {
} = msg.location;
let source_url = source_url.ok_or(ActorError::Internal)?;
let browsing_context =
registry.find::<BrowsingContextActor>(&self.browsing_context);
let thread = registry.find::<ThreadActor>(&browsing_context.thread);
let source = thread
let browsing_context_actor =
registry.find::<BrowsingContextActor>(&self.browsing_context_name);
let thread_actor =
registry.find::<ThreadActor>(&browsing_context_actor.thread_name);
let source = thread_actor
.source_manager
.find_source(registry, &source_url)
.ok_or(ActorError::Internal)?;
@@ -96,10 +97,11 @@ impl Actor for BreakpointListActor {
} = msg.location;
let source_url = source_url.ok_or(ActorError::Internal)?;
let browsing_context =
registry.find::<BrowsingContextActor>(&self.browsing_context);
let thread = registry.find::<ThreadActor>(&browsing_context.thread);
let source = thread
let browsing_context_actor =
registry.find::<BrowsingContextActor>(&self.browsing_context_name);
let thread_actor =
registry.find::<ThreadActor>(&browsing_context_actor.thread_name);
let source = thread_actor
.source_manager
.find_source(registry, &source_url)
.ok_or(ActorError::Internal)?;
@@ -124,11 +126,14 @@ impl Actor for BreakpointListActor {
}
impl BreakpointListActor {
pub fn new(name: String, browsing_context: String) -> Self {
Self {
name,
browsing_context,
}
pub fn register(registry: &ActorRegistry, browsing_context_name: String) -> String {
let name = registry.new_name::<Self>();
let actor = Self {
name: name.clone(),
browsing_context_name,
};
registry.register::<Self>(actor);
name
}
}

View File

@@ -6,17 +6,16 @@
//! Connection point for remote devtools that wish to investigate a particular Browsing Context's contents.
//! Supports dynamic attaching and detaching which control notifications of navigation, etc.
use std::net::TcpStream;
use atomic_refcell::AtomicRefCell;
use base::generic_channel::{self, GenericSender, SendError};
use base::id::PipelineId;
use devtools_traits::DevtoolScriptControlMsg::{self, GetCssDatabase, SimulateColorScheme};
use devtools_traits::{DevtoolsPageInfo, NavigationState};
use embedder_traits::Theme;
use malloc_size_of_derive::MallocSizeOf;
use rustc_hash::FxHashMap;
use serde::Serialize;
use serde_json::{Map, Value};
use servo_base::generic_channel::{self, GenericSender, SendError};
use servo_base::id::PipelineId;
use crate::actor::{Actor, ActorEncode, ActorError, ActorRegistry};
use crate::actors::inspector::InspectorActor;
@@ -28,7 +27,7 @@ use crate::actors::tab::TabDescriptorActor;
use crate::actors::thread::ThreadActor;
use crate::actors::watcher::{SessionContext, SessionContextType, WatcherActor};
use crate::id::{DevtoolsBrowserId, DevtoolsBrowsingContextId, DevtoolsOuterWindowId, IdMap};
use crate::protocol::{ClientRequest, JsonPacketStream};
use crate::protocol::{ClientRequest, DevtoolsConnection, JsonPacketStream};
use crate::resource::ResourceAvailable;
use crate::{EmptyReplyMsg, StreamId};
@@ -140,16 +139,22 @@ pub(crate) struct BrowsingContextActor {
active_pipeline_id: AtomicRefCell<PipelineId>,
active_outer_window_id: AtomicRefCell<DevtoolsOuterWindowId>,
pub browsing_context_id: DevtoolsBrowsingContextId,
accessibility: String,
pub console: String,
css_properties: String,
pub(crate) inspector: String,
reflow: String,
style_sheets: String,
pub thread: String,
accessibility_name: String,
pub console_name: String,
css_properties_name: String,
pub(crate) inspector_name: String,
reflow_name: String,
style_sheets_name: String,
pub thread_name: String,
_tab: String,
pub script_chan: GenericSender<DevtoolScriptControlMsg>,
pub watcher: String,
// Different pipelines may run on different script threads.
// These should be kept around even when the active pipeline is updated,
// in case the browsing context revisits a pipeline via history navigation.
// TODO: Each entry is stored forever; ideally there should be a way to
// detect when `ScriptThread`s are destroyed and remove the associated
// entries.
script_chans: AtomicRefCell<FxHashMap<PipelineId, GenericSender<DevtoolScriptControlMsg>>>,
pub watcher_name: String,
}
impl ResourceAvailable for BrowsingContextActor {
@@ -192,24 +197,25 @@ impl Actor for BrowsingContextActor {
impl BrowsingContextActor {
#[expect(clippy::too_many_arguments)]
pub(crate) fn new(
console: String,
pub(crate) fn register(
registry: &ActorRegistry,
console_name: String,
browser_id: DevtoolsBrowserId,
browsing_context_id: DevtoolsBrowsingContextId,
page_info: DevtoolsPageInfo,
pipeline_id: PipelineId,
outer_window_id: DevtoolsOuterWindowId,
script_sender: GenericSender<DevtoolScriptControlMsg>,
actors: &ActorRegistry,
) -> BrowsingContextActor {
let name = actors.new_name::<BrowsingContextActor>();
) -> String {
let name = registry.new_name::<BrowsingContextActor>();
let DevtoolsPageInfo {
title,
url,
is_top_level_global,
..
} = page_info;
let accessibility = AccessibilityActor::new(actors.new_name::<AccessibilityActor>());
let accessibility_name = AccessibilityActor::register(registry);
let properties = (|| {
let (properties_sender, properties_receiver) = generic_channel::channel()?;
@@ -217,61 +223,69 @@ impl BrowsingContextActor {
properties_receiver.recv().ok()
})()
.unwrap_or_default();
let css_properties =
CssPropertiesActor::new(actors.new_name::<CssPropertiesActor>(), properties);
let css_properties_name = CssPropertiesActor::register(registry, properties);
let inspector = InspectorActor::register(actors, pipeline_id, script_sender.clone());
let inspector_name = InspectorActor::register(registry, name.clone());
let reflow = ReflowActor::new(actors.new_name::<ReflowActor>());
let reflow_name = ReflowActor::register(registry);
let style_sheets = StyleSheetsActor::new(actors.new_name::<StyleSheetsActor>());
let style_sheets_name = StyleSheetsActor::register(registry);
let tabdesc = TabDescriptorActor::new(actors, name.clone(), is_top_level_global);
let tab_descriptor_name =
TabDescriptorActor::register(registry, name.clone(), is_top_level_global);
let thread = ThreadActor::new(actors.new_name::<ThreadActor>(), script_sender.clone());
let thread_name =
ThreadActor::register(registry, script_sender.clone(), Some(name.clone()));
let watcher = WatcherActor::new(
actors,
let watcher_name = WatcherActor::register(
registry,
name.clone(),
SessionContext::new(SessionContextType::BrowserElement),
);
let target = BrowsingContextActor {
name,
script_chan: script_sender,
let mut script_chans = FxHashMap::default();
script_chans.insert(pipeline_id, script_sender);
let actor = BrowsingContextActor {
name: name.clone(),
script_chans: AtomicRefCell::new(script_chans),
title: AtomicRefCell::new(title),
url: AtomicRefCell::new(url.into_string()),
active_pipeline_id: AtomicRefCell::new(pipeline_id),
active_outer_window_id: AtomicRefCell::new(outer_window_id),
browser_id,
browsing_context_id,
accessibility: accessibility.name(),
console,
css_properties: css_properties.name(),
inspector,
reflow: reflow.name(),
style_sheets: style_sheets.name(),
_tab: tabdesc.name(),
thread: thread.name(),
watcher: watcher.name(),
accessibility_name,
console_name,
css_properties_name,
inspector_name,
reflow_name,
style_sheets_name,
_tab: tab_descriptor_name,
thread_name,
watcher_name,
};
actors.register(accessibility);
actors.register(css_properties);
actors.register(reflow);
actors.register(style_sheets);
actors.register(tabdesc);
actors.register(thread);
actors.register(watcher);
registry.register::<Self>(actor);
target
name
}
pub(crate) fn navigate<'a>(
pub(crate) fn handle_new_global(
&self,
pipeline: PipelineId,
script_sender: GenericSender<DevtoolScriptControlMsg>,
) {
self.script_chans
.borrow_mut()
.insert(pipeline, script_sender);
}
pub(crate) fn handle_navigate<'a>(
&self,
state: NavigationState,
id_map: &mut IdMap,
connections: impl Iterator<Item = &'a mut TcpStream>,
connections: impl Iterator<Item = &'a mut DevtoolsConnection>,
) {
let (pipeline_id, title, url, state) = match state {
NavigationState::Start(url) => (None, None, url, "start"),
@@ -325,7 +339,7 @@ impl BrowsingContextActor {
}
pub fn simulate_color_scheme(&self, theme: Theme) -> Result<(), ()> {
self.script_chan
self.script_chan()
.send(SimulateColorScheme(self.pipeline_id(), theme))
.map_err(|_| ())
}
@@ -338,9 +352,18 @@ impl BrowsingContextActor {
*self.active_outer_window_id.borrow()
}
/// Returns the script sender for the active pipeline.
pub(crate) fn script_chan(&self) -> GenericSender<DevtoolScriptControlMsg> {
self.script_chans
.borrow()
.get(&self.pipeline_id())
.unwrap()
.clone()
}
pub(crate) fn instruct_script_to_send_live_updates(&self, should_send_updates: bool) {
let result = self
.script_chan
.script_chan()
.send(DevtoolScriptControlMsg::WantsLiveNotifications(
self.pipeline_id(),
should_send_updates,
@@ -370,13 +393,13 @@ impl ActorEncode<BrowsingContextActorMsg> for BrowsingContextActor {
browsing_context_id: self.browsing_context_id.value(),
outer_window_id: self.outer_window_id().value(),
is_top_level_target: true,
accessibility_actor: self.accessibility.clone(),
console_actor: self.console.clone(),
css_properties_actor: self.css_properties.clone(),
inspector_actor: self.inspector.clone(),
reflow_actor: self.reflow.clone(),
style_sheets_actor: self.style_sheets.clone(),
thread_actor: self.thread.clone(),
accessibility_actor: self.accessibility_name.clone(),
console_actor: self.console_name.clone(),
css_properties_actor: self.css_properties_name.clone(),
inspector_actor: self.inspector_name.clone(),
reflow_actor: self.reflow_name.clone(),
style_sheets_actor: self.style_sheets_name.clone(),
thread_actor: self.thread_name.clone(),
target_type: TargetType::Frame,
}
}

View File

@@ -7,31 +7,26 @@
//! inspection, JS evaluation, autocompletion) in Servo.
use std::collections::HashMap;
use std::net::TcpStream;
use std::sync::atomic::{AtomicBool, Ordering};
use atomic_refcell::AtomicRefCell;
use base::generic_channel::{self, GenericSender};
use base::id::TEST_PIPELINE_ID;
use devtools_traits::EvaluateJSReply::{
ActorValue, BooleanValue, NullValue, NumberValue, StringValue, VoidValue,
};
use devtools_traits::{
ConsoleArgument, ConsoleMessage, ConsoleMessageFields, DevtoolScriptControlMsg, PageError,
StackFrame, get_time_stamp,
ConsoleMessage, ConsoleMessageFields, DevtoolScriptControlMsg, PageError, StackFrame,
get_time_stamp,
};
use malloc_size_of_derive::MallocSizeOf;
use serde::Serialize;
use serde_json::{self, Map, Number, Value};
use serde_json::{self, Map, Value};
use servo_base::generic_channel::{self, GenericSender};
use servo_base::id::TEST_PIPELINE_ID;
use uuid::Uuid;
use crate::actor::{Actor, ActorError, ActorRegistry};
use crate::actors::browsing_context::BrowsingContextActor;
use crate::actors::object::ObjectActor;
use crate::actors::worker::WorkerActor;
use crate::protocol::{ClientRequest, JsonPacketStream};
use crate::actors::worker::WorkerTargetActor;
use crate::protocol::{ClientRequest, DevtoolsConnection, JsonPacketStream};
use crate::resource::{ResourceArrayType, ResourceAvailable};
use crate::{EmptyReplyMsg, StreamId, UniqueId};
use crate::{EmptyReplyMsg, StreamId, UniqueId, debugger_value_to_json};
#[derive(Clone, Serialize, MallocSizeOf)]
#[serde(rename_all = "camelCase")]
@@ -54,95 +49,13 @@ impl DevtoolsConsoleMessage {
arguments: message
.arguments
.into_iter()
.map(|argument| console_argument_to_value(argument, registry))
.map(|argument| debugger_value_to_json(registry, argument))
.collect(),
stacktrace: message.stacktrace,
}
}
}
fn console_argument_to_value(argument: ConsoleArgument, registry: &ActorRegistry) -> Value {
match argument {
ConsoleArgument::String(value) => Value::String(value),
ConsoleArgument::Integer(value) => Value::Number(value.into()),
ConsoleArgument::Number(value) => {
Number::from_f64(value).map(Value::from).unwrap_or_default()
},
ConsoleArgument::Boolean(value) => Value::Bool(value),
ConsoleArgument::Object(object) => {
// Create a new actor for the object.
// These are currently never cleaned up, and we make no attempt at re-using the same actor
// if the same object is logged repeatedly.
let actor = ObjectActor::register(registry, None);
#[derive(Serialize)]
struct PropertyDescriptor {
configurable: bool,
enumerable: bool,
writable: bool,
value: Value,
}
#[derive(Serialize)]
#[serde(rename_all = "camelCase")]
struct DevtoolsConsoleObjectArgument {
r#type: String,
actor: String,
class: String,
own_property_length: usize,
extensible: bool,
frozen: bool,
sealed: bool,
is_error: bool,
preview: DevtoolsConsoleObjectArgumentPreview,
}
#[derive(Serialize)]
#[serde(rename_all = "camelCase")]
struct DevtoolsConsoleObjectArgumentPreview {
kind: String,
own_properties: HashMap<String, PropertyDescriptor>,
own_properties_length: usize,
}
let own_properties: HashMap<String, PropertyDescriptor> = object
.own_properties
.into_iter()
.map(|property| {
let property_descriptor = PropertyDescriptor {
configurable: property.configurable,
enumerable: property.enumerable,
writable: property.writable,
value: console_argument_to_value(property.value, registry),
};
(property.key, property_descriptor)
})
.collect();
let argument = DevtoolsConsoleObjectArgument {
r#type: "object".to_owned(),
actor,
class: object.class,
own_property_length: own_properties.len(),
extensible: true,
frozen: false,
sealed: false,
is_error: false,
preview: DevtoolsConsoleObjectArgumentPreview {
kind: "Object".to_string(),
own_properties_length: own_properties.len(),
own_properties,
},
};
// to_value can fail if the implementation of Serialize fails or there are non-string map keys.
// Neither should be possible here
serde_json::to_value(argument).unwrap()
},
}
}
#[derive(Clone, Serialize, MallocSizeOf)]
#[serde(rename_all = "camelCase")]
struct DevtoolsPageError {
@@ -227,6 +140,7 @@ struct EvaluateJSReply {
timestamp: u64,
exception: Value,
exception_message: Value,
has_exception: bool,
helper_result: Value,
}
@@ -243,6 +157,7 @@ struct EvaluateJSEvent {
result_id: String,
exception: Value,
exception_message: Value,
has_exception: bool,
helper_result: Value,
}
@@ -279,36 +194,38 @@ pub(crate) struct ConsoleActor {
}
impl ConsoleActor {
pub fn new(name: String, root: Root) -> Self {
Self {
name,
pub fn register(registry: &ActorRegistry, name: String, root: Root) -> String {
let actor = Self {
name: name.clone(),
root,
cached_events: Default::default(),
client_ready_to_receive_messages: false.into(),
}
};
registry.register(actor);
name
}
fn script_chan(&self, registry: &ActorRegistry) -> GenericSender<DevtoolScriptControlMsg> {
match &self.root {
Root::BrowsingContext(browsing_context) => registry
.find::<BrowsingContextActor>(browsing_context)
.script_chan
Root::BrowsingContext(browsing_context_name) => registry
.find::<BrowsingContextActor>(browsing_context_name)
.script_chan(),
Root::DedicatedWorker(worker_name) => registry
.find::<WorkerTargetActor>(worker_name)
.script_sender
.clone(),
Root::DedicatedWorker(worker) => {
registry.find::<WorkerActor>(worker).script_chan.clone()
},
}
}
fn current_unique_id(&self, registry: &ActorRegistry) -> UniqueId {
match &self.root {
Root::BrowsingContext(browsing_context) => UniqueId::Pipeline(
Root::BrowsingContext(browsing_context_name) => UniqueId::Pipeline(
registry
.find::<BrowsingContextActor>(browsing_context)
.find::<BrowsingContextActor>(browsing_context_name)
.pipeline_id(),
),
Root::DedicatedWorker(worker) => {
UniqueId::Worker(registry.find::<WorkerActor>(worker).worker_id)
Root::DedicatedWorker(worker_name) => {
UniqueId::Worker(registry.find::<WorkerTargetActor>(worker_name).worker_id)
},
}
}
@@ -319,79 +236,39 @@ impl ConsoleActor {
msg: &Map<String, Value>,
) -> Result<EvaluateJSReply, ()> {
let input = msg.get("text").unwrap().as_str().unwrap().to_owned();
let frame_actor_id = msg
.get("frameActor")
.and_then(|v| v.as_str())
.map(String::from);
let (chan, port) = generic_channel::channel().unwrap();
// FIXME: Redesign messages so we don't have to fake pipeline ids when
// communicating with workers.
// FIXME: Redesign messages so we don't have to fake pipeline ids when communicating with workers.
let pipeline = match self.current_unique_id(registry) {
UniqueId::Pipeline(p) => p,
UniqueId::Worker(_) => TEST_PIPELINE_ID,
};
self.script_chan(registry)
.send(DevtoolScriptControlMsg::Eval(input.clone(), pipeline, chan))
.send(DevtoolScriptControlMsg::Eval(
input.clone(),
pipeline,
frame_actor_id,
chan,
))
.unwrap();
// TODO: Extract conversion into protocol module or some other useful place
let result = match port.recv().map_err(|_| ())? {
VoidValue => {
let mut m = Map::new();
m.insert("type".to_owned(), Value::String("undefined".to_owned()));
Value::Object(m)
},
NullValue => {
let mut m = Map::new();
m.insert("type".to_owned(), Value::String("null".to_owned()));
Value::Object(m)
},
BooleanValue(val) => Value::Bool(val),
NumberValue(val) => {
if val.is_nan() {
let mut m = Map::new();
m.insert("type".to_owned(), Value::String("NaN".to_owned()));
Value::Object(m)
} else if val.is_infinite() {
let mut m = Map::new();
if val < 0. {
m.insert("type".to_owned(), Value::String("-Infinity".to_owned()));
} else {
m.insert("type".to_owned(), Value::String("Infinity".to_owned()));
}
Value::Object(m)
} else if val == 0. && val.is_sign_negative() {
let mut m = Map::new();
m.insert("type".to_owned(), Value::String("-0".to_owned()));
Value::Object(m)
} else {
Value::Number(Number::from_f64(val).unwrap())
}
},
StringValue(s) => Value::String(s),
ActorValue { class, uuid } => {
// TODO: Make initial ActorValue message include these properties?
let mut m = Map::new();
let actor = ObjectActor::register(registry, Some(uuid));
let eval_result = port.recv().map_err(|_| ())?;
let has_exception = eval_result.has_exception;
m.insert("type".to_owned(), Value::String("object".to_owned()));
m.insert("class".to_owned(), Value::String(class));
m.insert("actor".to_owned(), Value::String(actor));
m.insert("extensible".to_owned(), Value::Bool(true));
m.insert("frozen".to_owned(), Value::Bool(false));
m.insert("sealed".to_owned(), Value::Bool(false));
Value::Object(m)
},
};
// TODO: Catch and return exception values from JS evaluation
// TODO: This should have a has_exception field
let reply = EvaluateJSReply {
from: self.name(),
input,
result,
result: debugger_value_to_json(registry, eval_result.value),
timestamp: get_time_stamp(),
exception: Value::Null,
exception_message: Value::Null,
has_exception,
helper_result: Value::Null,
};
std::result::Result::Ok(reply)
Ok(reply)
}
pub(crate) fn handle_console_resource(
@@ -399,7 +276,7 @@ impl ConsoleActor {
resource: ConsoleResource,
id: UniqueId,
registry: &ActorRegistry,
stream: &mut TcpStream,
stream: &mut DevtoolsConnection,
) {
self.cached_events
.borrow_mut()
@@ -414,13 +291,15 @@ impl ConsoleActor {
}
let resource_type = resource.resource_type();
if id == self.current_unique_id(registry) {
if let Root::BrowsingContext(bc) = &self.root {
registry.find::<BrowsingContextActor>(bc).resource_array(
resource,
resource_type,
ResourceArrayType::Available,
stream,
)
if let Root::BrowsingContext(browsing_context_name) = &self.root {
registry
.find::<BrowsingContextActor>(browsing_context_name)
.resource_array(
resource,
resource_type,
ResourceArrayType::Available,
stream,
)
};
}
}
@@ -429,18 +308,20 @@ impl ConsoleActor {
&self,
id: UniqueId,
registry: &ActorRegistry,
stream: &mut TcpStream,
stream: &mut DevtoolsConnection,
) {
if id == self.current_unique_id(registry) {
if let Root::BrowsingContext(bc) = &self.root {
registry.find::<BrowsingContextActor>(bc).resource_array(
ConsoleClearMessage {
level: "clear".to_owned(),
},
"console-message".into(),
ResourceArrayType::Available,
stream,
)
if let Root::BrowsingContext(browsing_context_name) = &self.root {
registry
.find::<BrowsingContextActor>(browsing_context_name)
.resource_array(
ConsoleClearMessage {
level: "clear".to_owned(),
},
"console-message".into(),
ResourceArrayType::Available,
stream,
)
};
}
}
@@ -514,7 +395,7 @@ impl Actor for ConsoleActor {
};
// Emit an eager reply so that the client starts listening
// for an async event with the resultID
let stream = request.reply(&early_reply)?;
let mut stream = request.reply(&early_reply)?;
if msg.get("eager").and_then(|v| v.as_bool()).unwrap_or(false) {
// We don't support the side-effect free evaluation that eager evaluation
@@ -532,6 +413,7 @@ impl Actor for ConsoleActor {
result_id,
exception: reply.exception,
exception_message: reply.exception_message,
has_exception: reply.has_exception,
helper_result: reply.helper_result,
};
// Send the data from evaluateJS along with a resultID

View File

@@ -60,7 +60,7 @@ impl Actor for DeviceActor {
apptype: "servo".to_string(),
version: env!("CARGO_PKG_VERSION").to_string(),
appbuildid: BUILD_ID.to_string(),
platformversion: "145.0".to_string(),
platformversion: "146.0".to_string(),
brand_name: "Servo".to_string(),
},
};
@@ -74,8 +74,11 @@ impl Actor for DeviceActor {
}
impl DeviceActor {
pub fn new(name: String) -> DeviceActor {
DeviceActor { name }
pub fn register(registry: &ActorRegistry) -> String {
let name = registry.new_name::<Self>();
let actor = DeviceActor { name: name.clone() };
registry.register::<Self>(actor);
name
}
pub fn description() -> ActorDescription {

View File

@@ -2,32 +2,20 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use std::collections::HashMap;
use devtools_traits::EnvironmentInfo;
use malloc_size_of_derive::MallocSizeOf;
use serde::Serialize;
use serde_json::{Map, Value};
use serde_json::Value;
use crate::actor::{Actor, ActorEncode, ActorRegistry};
use crate::actors::object::ObjectActorMsg;
#[derive(Serialize)]
#[serde(rename_all = "camelCase")]
pub enum EnvironmentType {
Function,
_Block,
_Object,
}
#[derive(Serialize)]
#[serde(rename_all = "camelCase")]
pub enum EnvironmentScope {
Function,
_Global,
}
use crate::actors::object::{ObjectActorMsg, ObjectPropertyDescriptor};
#[derive(Serialize)]
struct EnvironmentBindings {
arguments: Vec<Value>,
variables: Map<String, Value>,
variables: HashMap<String, ObjectPropertyDescriptor>,
}
#[derive(Serialize)]
@@ -41,8 +29,8 @@ struct EnvironmentFunction {
pub(crate) struct EnvironmentActorMsg {
actor: String,
#[serde(rename = "type")]
type_: EnvironmentType,
scope_kind: EnvironmentScope,
type_: Option<String>,
scope_kind: Option<String>,
#[serde(skip_serializing_if = "Option::is_none")]
parent: Option<Box<EnvironmentActorMsg>>,
#[serde(skip_serializing_if = "Option::is_none")]
@@ -60,8 +48,9 @@ pub(crate) struct EnvironmentActorMsg {
/// <https://searchfox.org/firefox-main/source/devtools/server/actors/environment.js>
#[derive(MallocSizeOf)]
pub(crate) struct EnvironmentActor {
pub name: String,
pub parent: Option<String>,
name: String,
environment: EnvironmentInfo,
parent_name: Option<String>,
}
impl Actor for EnvironmentActor {
@@ -70,22 +59,60 @@ impl Actor for EnvironmentActor {
}
}
impl EnvironmentActor {
pub fn register(
registry: &ActorRegistry,
environment: EnvironmentInfo,
parent_name: Option<String>,
) -> String {
let environment_name = registry.new_name::<Self>();
let environment_actor = Self {
name: environment_name.clone(),
parent_name,
environment,
};
registry.register(environment_actor);
environment_name
}
}
impl ActorEncode<EnvironmentActorMsg> for EnvironmentActor {
fn encode(&self, registry: &ActorRegistry) -> EnvironmentActorMsg {
let parent = self
.parent
.parent_name
.as_ref()
.map(|p| registry.find::<EnvironmentActor>(p))
.map(|p| Box::new(p.encode(registry)));
// TODO: Change hardcoded values.
EnvironmentActorMsg {
actor: self.name(),
type_: EnvironmentType::Function,
scope_kind: EnvironmentScope::Function,
type_: self.environment.type_.clone(),
scope_kind: self.environment.scope_kind.clone(),
parent,
bindings: None,
function: None,
function: self
.environment
.function_display_name
.clone()
.map(|display_name| EnvironmentFunction { display_name }),
object: None,
bindings: Some(EnvironmentBindings {
arguments: [].to_vec(),
variables: self
.environment
.binding_variables
.clone()
.into_iter()
.map(|ref property_descriptor| {
(
property_descriptor.name.clone(),
ObjectPropertyDescriptor::from_property_descriptor(
registry,
property_descriptor,
),
)
})
.collect(),
}),
}
}
}

View File

@@ -3,16 +3,18 @@
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
use atomic_refcell::AtomicRefCell;
use devtools_traits::FrameInfo;
use devtools_traits::{DevtoolScriptControlMsg, FrameInfo};
use malloc_size_of_derive::MallocSizeOf;
use serde::Serialize;
use serde_json::{Map, Value};
use servo_base::generic_channel::channel;
use crate::StreamId;
use crate::actor::{Actor, ActorEncode, ActorError, ActorRegistry};
use crate::actors::environment::{EnvironmentActor, EnvironmentActorMsg};
use crate::actors::object::{ObjectActor, ObjectActorMsg};
use crate::protocol::ClientRequest;
use crate::actors::source::SourceActor;
use crate::protocol::{ClientRequest, JsonPacketStream};
#[derive(Serialize)]
struct FrameEnvironmentReply {
@@ -58,7 +60,7 @@ pub(crate) struct FrameActorMsg {
pub(crate) struct FrameActor {
name: String,
object_actor: String,
source_actor: String,
source_name: String,
frame_result: FrameInfo,
current_offset: AtomicRefCell<(u32, u32)>,
}
@@ -71,7 +73,7 @@ impl Actor for FrameActor {
// https://searchfox.org/firefox-main/source/devtools/shared/specs/frame.js
fn handle_message(
&self,
request: ClientRequest,
mut request: ClientRequest,
registry: &ActorRegistry,
msg_type: &str,
_msg: &Map<String, Value>,
@@ -79,18 +81,24 @@ impl Actor for FrameActor {
) -> Result<(), ActorError> {
match msg_type {
"getEnvironment" => {
let environment = EnvironmentActor {
name: registry.new_name::<EnvironmentActor>(),
parent: None,
let Some((tx, rx)) = channel() else {
return Err(ActorError::Internal);
};
let source_actor = registry.find::<SourceActor>(&self.source_name);
source_actor
.script_sender
.send(DevtoolScriptControlMsg::GetEnvironment(self.name(), tx))
.map_err(|_| ActorError::Internal)?;
let environment_name = rx.recv().map_err(|_| ActorError::Internal)?;
let msg = FrameEnvironmentReply {
from: self.name(),
environment: environment.encode(registry),
environment: registry.encode::<EnvironmentActor, _>(&environment_name),
};
registry.register(environment);
// This reply has a `type` field but it doesn't need a followup,
// unlike most messages. We need to skip the validity check.
request.reply_unchecked(&msg)?;
request.write_json_packet(&msg)?;
request.mark_handled();
},
_ => return Err(ActorError::UnrecognizedPacketType),
};
@@ -101,16 +109,16 @@ impl Actor for FrameActor {
impl FrameActor {
pub fn register(
registry: &ActorRegistry,
source_actor: String,
source_name: String,
frame_result: FrameInfo,
) -> String {
let object_actor = ObjectActor::register(registry, None);
let object_name = ObjectActor::register(registry, None, "Object".to_owned(), None);
let name = registry.new_name::<Self>();
let actor = Self {
name: name.clone(),
object_actor,
source_actor,
object_actor: object_name,
source_name,
frame_result,
current_offset: Default::default(),
};
@@ -145,7 +153,7 @@ impl ActorEncode<FrameActorMsg> for FrameActor {
oldest: self.frame_result.oldest,
state,
where_: FrameWhere {
actor: self.source_actor.clone(),
actor: self.source_name.clone(),
line,
column,
},

View File

@@ -5,10 +5,10 @@
use std::mem;
use atomic_refcell::AtomicRefCell;
use base::generic_channel::GenericSender;
use base::id::PipelineId;
use devtools_traits::DevtoolScriptControlMsg;
use malloc_size_of_derive::MallocSizeOf;
use servo_base::generic_channel::GenericSender;
use servo_base::id::PipelineId;
use crate::actor::{Actor, ActorRegistry};
use crate::actors::timeline::HighResolutionStamp;

View File

@@ -4,10 +4,6 @@
//! Liberally derived from the [Firefox JS implementation](http://mxr.mozilla.org/mozilla-central/source/toolkit/devtools/server/actors/inspector.js).
use atomic_refcell::AtomicRefCell;
use base::generic_channel::GenericSender;
use base::id::PipelineId;
use devtools_traits::DevtoolScriptControlMsg;
use malloc_size_of_derive::MallocSizeOf;
use serde::Serialize;
use serde_json::{self, Map, Value};
@@ -20,11 +16,13 @@ use crate::protocol::ClientRequest;
use crate::{ActorMsg, StreamId};
pub mod accessibility;
pub mod accessible_walker;
pub mod css_properties;
pub mod highlighter;
pub mod layout;
pub mod node;
pub mod page_style;
pub mod simulator;
pub mod style_rule;
pub mod walker;
@@ -56,9 +54,9 @@ struct SupportsHighlightersReply {
#[derive(MallocSizeOf)]
pub(crate) struct InspectorActor {
name: String,
highlighter: String,
page_style: String,
pub(crate) walker: String,
highlighter_name: String,
page_style_name: String,
pub(crate) walker_name: String,
}
impl Actor for InspectorActor {
@@ -78,7 +76,7 @@ impl Actor for InspectorActor {
"getPageStyle" => {
let msg = GetPageStyleReply {
from: self.name(),
page_style: registry.encode::<PageStyleActor, _>(&self.page_style),
page_style: registry.encode::<PageStyleActor, _>(&self.page_style_name),
};
request.reply_final(&msg)?
},
@@ -86,7 +84,7 @@ impl Actor for InspectorActor {
"getHighlighterByType" => {
let msg = GetHighlighterReply {
from: self.name(),
highlighter: registry.encode::<HighlighterActor, _>(&self.highlighter),
highlighter: registry.encode::<HighlighterActor, _>(&self.highlighter_name),
};
request.reply_final(&msg)?
},
@@ -94,7 +92,7 @@ impl Actor for InspectorActor {
"getWalker" => {
let msg = GetWalkerReply {
from: self.name(),
walker: registry.encode::<WalkerActor, _>(&self.walker),
walker: registry.encode::<WalkerActor, _>(&self.walker_name),
};
request.reply_final(&msg)?
},
@@ -114,45 +112,23 @@ impl Actor for InspectorActor {
}
impl InspectorActor {
// TODO: Passing the pipeline id here isn't correct. We should query the browsing
// context for the active pipeline, otherwise reloading or navigating will break the inspector.
pub fn register(
registry: &ActorRegistry,
pipeline: PipelineId,
script_chan: GenericSender<DevtoolScriptControlMsg>,
) -> String {
let highlighter = HighlighterActor {
name: registry.new_name::<HighlighterActor>(),
script_sender: script_chan.clone(),
pipeline,
};
pub fn register(registry: &ActorRegistry, browsing_context_name: String) -> String {
let highlighter_name = HighlighterActor::register(registry, browsing_context_name.clone());
let page_style = PageStyleActor {
name: registry.new_name::<PageStyleActor>(),
script_chan: script_chan.clone(),
pipeline,
};
let page_style_name = PageStyleActor::register(registry);
let walker = WalkerActor {
name: registry.new_name::<WalkerActor>(),
mutations: AtomicRefCell::new(vec![]),
script_chan,
pipeline,
};
let walker_name = WalkerActor::register(registry, browsing_context_name);
let actor = Self {
let inspector_actor = Self {
name: registry.new_name::<InspectorActor>(),
highlighter: highlighter.name(),
page_style: page_style.name(),
walker: walker.name(),
highlighter_name,
page_style_name,
walker_name,
};
let name = actor.name();
let inspector_name = inspector_actor.name();
registry.register(highlighter);
registry.register(page_style);
registry.register(walker);
registry.register(actor);
registry.register(inspector_actor);
name
inspector_name
}
}

View File

@@ -11,6 +11,8 @@ use serde_json::{Map, Value};
use crate::StreamId;
use crate::actor::{Actor, ActorError, ActorRegistry};
use crate::actors::inspector::accessible_walker::AccessibleWalkerActor;
use crate::actors::inspector::simulator::SimulatorActor;
use crate::protocol::ClientRequest;
#[derive(Serialize)]
@@ -90,14 +92,11 @@ impl Actor for AccessibilityActor {
request.reply_final(&msg)?
},
"getSimulator" => {
// TODO: Create actual simulator
let actor = registry.new_name::<SimulatorActor>();
registry.register(SimulatorActor {
name: actor.clone(),
});
let msg = GetSimulatorReply {
from: self.name(),
simulator: ActorMsg { actor },
simulator: ActorMsg {
actor: SimulatorActor::register(registry),
},
};
request.reply_final(&msg)?
},
@@ -111,14 +110,11 @@ impl Actor for AccessibilityActor {
request.reply_final(&msg)?
},
"getWalker" => {
// TODO: Create actual accessible walker
let actor = registry.new_name::<AccessibleWalkerActor>();
registry.register(AccessibleWalkerActor {
name: actor.clone(),
});
let msg = GetWalkerReply {
from: self.name(),
walker: ActorMsg { actor },
walker: ActorMsg {
actor: AccessibleWalkerActor::register(registry),
},
};
request.reply_final(&msg)?
},
@@ -129,29 +125,10 @@ impl Actor for AccessibilityActor {
}
impl AccessibilityActor {
pub fn new(name: String) -> Self {
Self { name }
}
}
#[derive(MallocSizeOf)]
pub(crate) struct SimulatorActor {
name: String,
}
impl Actor for SimulatorActor {
fn name(&self) -> String {
self.name.clone()
}
}
#[derive(MallocSizeOf)]
pub(crate) struct AccessibleWalkerActor {
name: String,
}
impl Actor for AccessibleWalkerActor {
fn name(&self) -> String {
self.name.clone()
pub fn register(registry: &ActorRegistry) -> String {
let name = registry.new_name::<Self>();
let actor = Self { name: name.clone() };
registry.register::<Self>(actor);
name
}
}

Some files were not shown because too many files have changed in this diff Show More