Skip to content

script: Move easy IpcChannel usage to GenericChannel usage#43309

Merged
jdm merged 3 commits into
servo:mainfrom
Narfinger:callbacks
Mar 20, 2026
Merged

script: Move easy IpcChannel usage to GenericChannel usage#43309
jdm merged 3 commits into
servo:mainfrom
Narfinger:callbacks

Conversation

@Narfinger

@Narfinger Narfinger commented Mar 16, 2026

Copy link
Copy Markdown
Contributor

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>
@codecov-commenter

Copy link
Copy Markdown

⚠️ JUnit XML file not found

The CLI was unable to find any JUnit XML files to upload.
For more help, visit our troubleshooting guide.

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
@Narfinger Narfinger marked this pull request as ready for review March 16, 2026 09:43
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Mar 16, 2026
Comment thread components/shared/net/filemanager_thread.rs
@yezhizhen yezhizhen changed the title Script: Move easy IpcChannel usage to GenericChannel usage script: Move easy IpcChannel usage to GenericChannel usage Mar 16, 2026
@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Mar 16, 2026
@jdm jdm added this pull request to the merge queue Mar 16, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Mar 16, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Mar 16, 2026
@servo-highfive servo-highfive added S-tests-failed The changes caused existing tests to fail. and removed S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. labels Mar 16, 2026
Comment thread components/script/dom/cookiestore.rs
@servo-highfive servo-highfive added S-awaiting-review There is new code that needs to be reviewed. and removed S-tests-failed The changes caused existing tests to fail. labels Mar 20, 2026
@Narfinger Narfinger added the T-linux-wpt Do a try run of the WPT label Mar 20, 2026
@github-actions github-actions Bot removed the T-linux-wpt Do a try run of the WPT label Mar 20, 2026
@github-actions

Copy link
Copy Markdown

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

Signed-off-by: Narfinger <Narfinger@users.noreply.github.com>
@github-actions

Copy link
Copy Markdown

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

Flaky unexpected result (24)
  • OK /_mozilla/css/offset_properties_inline.html (#40543)
    • FAIL [expected PASS] subtest: offsetTop

      assert_equals: offsetTop of #inline-1 should be 0. expected 0 but got -1
      

    • FAIL [expected PASS] subtest: offsetLeft

      assert_equals: offsetLeft of #inline-2 should be 40. expected 40 but got 25
      

  • TIMEOUT [expected OK] /_mozilla/mozilla/img_find_non_sibling_map.html
  • CRASH [expected PASS] /_mozilla/shadow-dom/move-element-with-ua-shadow-tree-crash.html (#39473)
  • OK [expected TIMEOUT] /_webgl/conformance/textures/misc/tex-video-using-tex-unit-non-zero.html (#39735)
    • PASS [expected NOTRUN] subtest: Overall test
    • PASS [expected FAIL] subtest: WebGL test #0
  • CRASH [expected OK] /_webgl/conformance2/wasm/readpixels-2gb-in-4gb-wasm-memory.html
  • OK /css/css-cascade/layer-cssom-order-reverse.html (#36094)
    • PASS [expected FAIL] subtest: Delete layer invalidates @font-face
  • OK /css/css-cascade/layer-font-face-override.html (#35935)
    • PASS [expected FAIL] subtest: @font-face override update with appended sheet 2
  • ERROR [expected OK] /fetch/fetch-later/quota/same-origin-iframe/accumulated-oversized-payload.https.window.html (#41705)
  • TIMEOUT /fetch/metadata/generated/css-images.https.sub.tentative.html (#42229)
    • PASS [expected FAIL] subtest: content sec-fetch-site - Same-Origin -&gt; Same Origin
  • OK [expected TIMEOUT] /fullscreen/model/move-to-fullscreen-iframe.html
    • FAIL [expected TIMEOUT] subtest: Moving fullscreen document's body into a fullscreen iframe

      promise_test: Unhandled rejection with value: object "TypeError: fullscreen is not connected"
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/005.html (#27062)
    • PASS [expected FAIL] subtest: Link with onclick navigation and href navigation
  • OK /html/browsers/windows/browsing-context-names/duplicate-name-order.html (#34623)
    • PASS [expected FAIL] subtest: Duplicate name lookup order
  • OK [expected TIMEOUT] /html/interaction/focus/the-autofocus-attribute/update-the-rendering.html (#24145)
    • FAIL [expected TIMEOUT] subtest: "Flush autofocus candidates" should be happen before a scroll event and animation frame callbacks

      assert_array_equals: animationFrame lengths differ, expected array ["autofocus", "scroll", "animationFrame"] length 3, got ["animationFrame"] length 1
      

  • OK /html/semantics/document-metadata/the-meta-element/pragma-directives/attr-meta-http-equiv-refresh/allow-scripts-flag-changing-1.html (#39694)
    • PASS [expected FAIL] subtest: Meta refresh is blocked by the allow-scripts sandbox flag at its creation time, not when refresh comes due
  • TIMEOUT /html/semantics/embedded-content/media-elements/preserves-pitch.html (#40352)
    • PASS [expected TIMEOUT] subtest: Speed-ups should not change the pitch when preservesPitch=true
    • PASS [expected NOTRUN] subtest: Slow-downs should not change the pitch when preservesPitch=true
    • TIMEOUT [expected NOTRUN] subtest: Speed-ups should change the pitch when preservesPitch=false

      Test timed out
      

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

      Test timed out
      

  • TIMEOUT [expected OK] /html/user-activation/navigation-state-reset-sameorigin.html
    • TIMEOUT [expected PASS] subtest: Post-navigation state reset.

      Test timed out
      

  • FAIL [expected PASS] /png/apng/fcTL-dispose-before-region-background.html
  • OK /pointerevents/compat/pointerevent_touch_target_after_pointerdown_target_removed.tentative.html (#42813)
    • FAIL [expected PASS] subtest: After a pointerdown listener removes its target, touch events should be fired on the touchstart target even though an orphan and pointer events should be fired on the parent

      assert_equals: expected "[ { type: pointerdown, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: touchstart, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointerup, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchend, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; } ]" but got "[ { type: pointerdown, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: touchstart, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointerup, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchend, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointerdown, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; } ]"
      

    • FAIL [expected PASS] subtest: After a pointerdown listener removes its target, touchmove event should be fired on the pointerdown target

      assert_equals: expected "[ { type: pointerdown, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: touchstart, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchmove, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointerup, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchend, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; } ]" but got "[ { type: pointerdown, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: touchstart, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchmove, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointerup, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: touchend, target: Element node &lt;div id=\"pointerDownTarget\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointerdown, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; }, { type: pointermove, target: Element node &lt;div id=\"pointerDownTargetParent\"&gt;&lt;/div&gt; } ]"
      

  • TIMEOUT /trusted-types/trusted-types-navigation.html?06-10 (#37920)
    • PASS [expected FAIL] subtest: Navigate a frame via anchor with javascript:-urls in report-only mode.
  • OK [expected TIMEOUT] /trusted-types/trusted-types-navigation.html?31-35 (#38034)
    • PASS [expected TIMEOUT] subtest: Navigate a frame via form-submission with javascript:-urls w/ default policy in report-only mode.
    • FAIL [expected NOTRUN] subtest: Navigate a window via form-submission with javascript:-urls w/ a default policy throwing an exception in enforcing mode.

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

    • FAIL [expected NOTRUN] subtest: Navigate a window via form-submission with javascript:-urls w/ a default policy throwing an exception in report-only mode.

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

    • FAIL [expected NOTRUN] subtest: Navigate a window via form-submission with javascript:-urls w/ a default policy making the URL invalid in enforcing mode.

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

  • OK /webdriver/tests/classic/back/user_prompts.py
    • FAIL [expected PASS] subtest: test_accept[alert]

      AssertionError: assert 'about:blank' == 'https://web-platform.test:8443/webdriver/tests/support/inline.py?doc=%3C%21doctype+html%3E%0A%3Cmeta+charset%3DUTF-8%3E%0A%3Cp+id%3D1%3E&amp;mime=text%2Fhtml&amp;charset=UTF-8'
      

  • OK /webdriver/tests/classic/close_window/user_prompts.py
    • FAIL [expected PASS] subtest: test_accept[alert]

      webdriver.error.NoSuchWindowException: no such window (404): No such window
      

  • OK /webxr/xrSession_features_deviceSupport.https.html (#24357)
    • FAIL [expected PASS] subtest: Immersive XRSession requests with no supported device should reject

      assert_unreached: Should have rejected: undefined Reached unreachable code
      

Stable unexpected results that are known to be intermittent (14)
  • OK /FileAPI/url/url-with-fetch.any.html (#21517)
    • PASS [expected FAIL] subtest: Revoke blob URL after calling fetch, fetch should succeed
  • FAIL [expected PASS] /_mozilla/mozilla/sslfail.html (#10760)
  • TIMEOUT [expected OK] /_mozilla/mozilla/window_resize_event.html (#36741)
    • TIMEOUT [expected PASS] subtest: Popup onresize event fires after resizeTo

      Test timed out
      

  • OK [expected TIMEOUT] /content-security-policy/inheritance/document-write-iframe.html (#41195)
    • PASS [expected TIMEOUT] subtest: document.open() keeps inherited CSPs on transient about:blank.
  • OK /css/css-fonts/generic-family-keywords-001.html (#37467)
    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted generic(fangsong)

      assert_equals: quoted generic(fangsong) matches  @font-face rule expected 50 but got 30
      

  • OK /css/css-fonts/generic-family-keywords-003.html (#38994)
    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted sans-serif (drawing text in a canvas)

      assert_equals: quoted sans-serif matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted cursive (drawing text in a canvas)

      assert_equals: quoted cursive matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted fantasy (drawing text in a canvas)

      assert_equals: quoted fantasy matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted monospace (drawing text in a canvas)

      assert_equals: quoted monospace matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted system-ui (drawing text in a canvas)

      assert_equals: quoted system-ui matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted generic(fangsong) (drawing text in a canvas)

      assert_equals: quoted generic(fangsong) matches  @font-face rule expected 125 but got 40
      

    • FAIL [expected PASS] subtest: @font-face matching for quoted and unquoted generic(khmer-mul) (drawing text in a canvas)

      assert_equals: unquoted generic(khmer-mul) does not match @font-face rule expected 40 but got 125
      

  • OK /html/browsers/browsing-the-web/navigating-across-documents/navigation-unload-cross-origin.sub.window.html (#29056)
    • PASS [expected FAIL] subtest: Cross-origin navigation started from unload handler must be ignored
  • OK /html/browsers/browsing-the-web/navigating-across-documents/replace-before-load/a-click.html (#28697)
    • FAIL [expected PASS] subtest: aElement.click() before the load event must NOT replace

      assert_equals: expected "http://web-platform.test:8000/common/blank.html?thereplacement" but got "http://web-platform.test:8000/html/browsers/browsing-the-web/navigating-across-documents/replace-before-load/resources/code-injector.html?pipe=sub(none)&amp;code=%0A%20%20%20%20const%20a%20%3D%20document.createElement(%22a%22)%3B%0A%20%20%20%20a.href%20%3D%20%22%2Fcommon%2Fblank.html%3Fthereplacement%22%3B%0A%20%20%20%20document.currentScript.before(a)%3B%0A%20%20%20%20a.click()%3B%0A%20%20"
      

  • OK /html/browsers/history/the-history-interface/traverse_the_history_2.html (#21383)
    • FAIL [expected PASS] subtest: Multiple history traversals, last would be aborted

      assert_array_equals: Pages opened during history navigation expected property 1 to be 3 but got 2 (expected array [6, 3] got [6, 2])
      

  • OK [expected TIMEOUT] /html/interaction/focus/the-autofocus-attribute/document-with-fragment-top.html (#28259)
    • FAIL [expected TIMEOUT] subtest: Autofocus elements in top-level browsing context's documents with "top" fragments should work.

      assert_not_equals: got disallowed value Element node &lt;body&gt;&lt;/body&gt;
      

  • OK /navigation-timing/test-navigation-type-reload.html (#33334)
    • FAIL [expected PASS] subtest: Reload fetchStart &gt; Original fetchStart

      assert_true: Reload fetchStart &gt; Original fetchStart expected true got false
      

  • OK /touch-events/single-tap-when-touchend-listener-use-sync-xhr.html (#41175)
    • FAIL [expected PASS] subtest: Click event should be fired when touchend opens synchronous XHR

      assert_equals: expected "touchend@div, mousedown@div, mouseup@div, click@div" but got "touchend@div, mousedown@div"
      

  • TIMEOUT /trusted-types/trusted-types-navigation.html?26-30 (#38807)
    • PASS [expected TIMEOUT] subtest: Navigate a window via form-submission with javascript:-urls in report-only mode.
    • PASS [expected NOTRUN] subtest: Navigate a window via form-submission with javascript:-urls w/ default policy in report-only mode.
    • PASS [expected NOTRUN] subtest: Navigate a frame via form-submission with javascript:-urls in enforcing mode.
    • TIMEOUT [expected NOTRUN] subtest: Navigate a frame via form-submission with javascript:-urls w/ default policy in enforcing mode.

      Test timed out
      

  • OK /visual-viewport/resize-event-order.html (#41981)
    • PASS [expected FAIL] subtest: Popup: DOMWindow resize fired before VisualViewport.

@github-actions

Copy link
Copy Markdown

✨ Try run (#23331843049) succeeded.

@jdm jdm added this pull request to the merge queue Mar 20, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Mar 20, 2026
Merged via the queue into servo:main with commit 81c3bde Mar 20, 2026
71 checks passed
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Mar 20, 2026
@Narfinger Narfinger deleted the callbacks branch March 20, 2026 08:29
Gae24 pushed a commit to Gae24/servo that referenced this pull request Mar 26, 2026
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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-awaiting-review There is new code that needs to be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants