Skip to content

fix(driver): let the client declare lone surrogate support - #43548

Merged
Pavel Feldman (pavelfeldman) merged 1 commit into
microsoft:mainfrom
pavelfeldman:fix-43542
Oct 20, 2026
Merged

Pavel Feldman (pavelfeldman) merged 1 commit into
microsoft:mainfrom
pavelfeldman:fix-43542

Conversation

@pavelfeldman

Copy link
Copy Markdown
Member

Summary

  • Root.initialize gets an optional supportsLoneSurrogates flag. The driver replaces lone surrogates with U+FFFD only when the client does not set it, instead of keying off PW_LANG_NAME.
  • The JavaScript client sets the flag. Python should set it too; .NET and Java need no change.

Fixes #43542

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

Copy link
Copy Markdown
Contributor

Hi, I'm the Playwright bot and I took a first look at the CI failures.

🟢 The reported failures are pre-existing flakes; this PR is clear

The WebKit MCP test has the same timeout on unrelated PRs and main, while the Chromium video test passed on retry and frequently does the same elsewhere. The reports are incomplete because their workflow runs were cancelled, but the failures they contain do not look caused by this PR.

Details

Overall assessment

This PR changes driver initialization and lone-surrogate serialization. It does not change the MCP HTTP lifecycle or video/trace code covered by the reported tests. Both exact test identities have failed or flaked on commits that this PR cannot affect.

Pre-existing flakes

  • [webkit] › mcp/http.spec.ts:92 › http transport browser lifecycle (isolated) — timed out after 30 seconds. For the same project, file, title, and CI bot, recent results show 15 failed runs and 522 passed runs out of 537. The failures include main run 38284917185 at 6885c0c8e0fcbd72861df515dbc2a50fc2c86084, before this PR.
  • [chromium-library] › library/video.spec.ts:762 › screencast › VI-030 should work with video+trace — passed on its fourth attempt. The same test was rescued by retries in 31 of 52 recent runs and also flaked on main run 39361912437 at the PR's base SHA, 27219bd2cc94e1ebceec58f188760a6bf458c192.

Triaged by the Playwright bot - agent run

@github-actions

Copy link
Copy Markdown
Contributor

Test results for "tests 1"

3 flaky ⚠️ [chromium-library] › library/chromium/chromium.spec.ts:416 › CR-018 should produce network events, routing, and annotations for Service Worker (advanced) `@chromium-playwright-x64-ubuntu24-64-core-node22`
⚠️ [chromium-library] › library/video.spec.ts:762 › screencast › VI-030 should work with video+trace `@chromium-playwright-x64-ubuntu24-64-core-node22`
⚠️ [firefox-library] › library/capabilities.spec.ts:105 › CA-008 should support webgl Radoslav Kirilov (@smoke) `@firefox-playwright-x64-ubuntu24-64-core-node22`

23582 passed, 713 skipped


Merge workflow run.

@github-actions

Copy link
Copy Markdown
Contributor

Test results for "MCP"

5189 passed, 614 skipped


Merge workflow run.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] driver: lone surrogates reach the Python client as U+FFFD

2 participants