Commit Graph
5798 Commits
Author SHA1 Message Date
Devin RoussoandGitHub 3e14efd6b7 fix(registry): evaluate defaultCacheDirectory lazily (#41942)
`defaultCacheDirectory` used to be computed inside the `PLAYWRIGHT_BROWSERS_PATH` branch of `registryDirectory`, so setting that variable skipped the platform check
    
<https://github.com/microsoft/playwright/pull/39423> hoisted it into an eagerly evaluated module constant, so it now throws `Unsupported platform: <platform>` at import, before `registryDirectory` consults `PLAYWRIGHT_BROWSERS_PATH`
    
this regressed setups that point `PLAYWRIGHT_BROWSERS_PATH` at their own browsers on platforms without a default cache directory, such as Android/Termux
    
evaluate `defaultCacheDirectory`, `defaultRegistryDirectory`, and `baseDaemonDir` lazily so an explicit `PLAYWRIGHT_BROWSERS_PATH` is honored before any default cache directory is computed
    
`registryDirectory` still throws eagerly when no override is set, since there is nowhere to place browsers

fixes <https://github.com/microsoft/playwright/issues/41852>
2026-07-23 12:31:58 -06:00
Devin RoussoandGitHub fd9395d740 fix(webview): route exposeFunctions callbacks to the originating frame (#41919)
WebKit has no `Runtime.addBinding`, so the webview delegate has to handle bindings through `console.debug(BINDING_CALL_TAG, payload)` instead

the console message carries no execution context id, so every call was dispatched against the main frame, meaning a callback fired from a child frame (e.g. `frame.evaluate(..., { exposeFunctions: true })`) reached the wrong `BindingsController` and never resolved the calling frame's pending promise, hanging until the 30s timeout tore the page down

tag each call with an empty object created in the calling context, as an `objectId` carries the injected script id, meaning that the host can route the call to the frame it came from and release the marker afterwards
2026-07-23 11:35:34 -06:00
Devin RoussoandGitHub 610977b294 fix(mcp): surface the missing executable path when a browser isn't installed (#41941)
when a browser binary is missing, `throwIfExecutableMissing` caught playwright-core's `Executable doesn't exist at <path>` and rethrew a generic `Browser "<name>" is not installed`, dropping the path

that path holds the version-specific directory (e.g. `firefox-1534`), which is what tells a genuinely missing install apart from a version mismatch

browsers from a standalone `playwright install` land in a differently-versioned directory than the bundled `playwright-core` expects

keep the path in the rethrown message so the mismatch is diagnosable

this is a further improvement for <https://github.com/microsoft/playwright/pull/40867>

referenced in <https://github.com/microsoft/playwright/issues/41871>
2026-07-23 09:31:33 -06:00
Dmitry GozmanandGitHub dba907bdbc feat: support pierce-frames selector (#41778) 2026-07-23 15:29:04 +01:00
Dmitry GozmanandGitHub 1299d0f6c4 feat(recorder): record actions by letting page events through naturally (#41902) 2026-07-23 14:51:38 +01:00
4b0cc996cc fix(test): unflake screencast backpressure test on slow macOS runner (#41951)
Co-authored-by: Copilot <[email protected]>
2026-07-23 13:17:07 +02:00
bbbae6dce7 test: fixme WebSocket locale test in Chromium 150 (#41944)
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Simon Knott <[email protected]>
Copilot-Session: 19d8bd17-13fd-482d-8228-94bd104679cf
2026-07-23 12:45:48 +02:00
15c4f55879 fix(mcp): identify downloads explicitly (#41933)
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 0d6d0323-d581-4df1-ae11-bf2d9302c1d2
Copilot-Session: 296e429d-05c3-4f64-be3f-a199a1e00d65
2026-07-23 08:59:07 +02:00
tsushanthandGitHub f5fa967ff5 fix(network): request.postData() returns null for empty string body override (#41882) 2026-07-22 15:51:01 -06:00
Devin RoussoandGitHub 0edafe4baa fix(mcp): launch the Chrome profile that has the extension installed (#41939)
extension mode validated that the playwright extension was installed in any of Chrome's profiles under the user data directory, but then launched without `--profile-directory`, meaning it could open a different profile than the one that was checked

when the opened profile lacks the extension, `connect.html` can't load and the connection silently hangs for ~120s

resolve the profile that actually has the extension (preferring the last-used profile from Local State so we don't switch away from the user's session unnecessarily) and pass it as `--profile-directory`

fixes <https://github.com/microsoft/playwright/issues/41916>
2026-07-22 15:03:44 -06:00
microsoft-playwright-automation[bot]andGitHub 244a1ffdd8 feat(firefox): roll to r1538 (#41938) 2026-07-22 12:06:26 -06:00
Simon KnottandGitHub ac877bc190 test(evaluate): skip using declaration on WebKit (#41929) 2026-07-22 10:03:45 -07:00
Devin RoussoandGitHub 3e95c6c8fc fix(role): name <meter> and <progress> from an associated label (#41911)
`<meter>` and `<progress>` are labelable, but the html-aam per-element name step only ran the associated-labels branch for `TEXTAREA`/`SELECT`/`INPUT` (plus `BUTTON`/`OUTPUT`)

fixes <https://github.com/microsoft/playwright/issues/41891>
2026-07-22 08:58:35 -06:00
Simon KnottandGitHub 18e7ca5421 Revert "fix(cli): don't crash the response when navigating closes the last tab" (#41931) 2026-07-22 14:03:36 +02:00
Dmitry GozmanandGitHub 478b9f05cb test: test for issue 41348 (#41930) 2026-07-22 12:21:44 +01:00
a8a2d54095 test: skip non-utf8 body test on older chromium channels (#41926)
Co-authored-by: Copilot <[email protected]>
2026-07-22 10:41:02 +02:00
Devin RoussoandGitHub 6da1930926 fix(role): map input[type=search] to searchbox unless list is a datalist (#41913)
the `search` branch only checked `hasAttribute('list')`, so an `input[type=search]` whose `list` points at nothing or a non-`<datalist>` element was reported as `combobox`, unlike the neighbouring `text`/`email`/... branch and unlike what the browser computes (`searchbox`)

resolve the `list` idref and only map to `combobox` when it points at an actual `<datalist>`, matching the html spec's concept-input-list

fixes <https://github.com/microsoft/playwright/issues/41899>
2026-07-21 18:05:16 -06:00
Pavel FeldmanandGitHub f39623b16d feat(addInitScript): allow passing functions as init script arguments (#41921) 2026-07-21 15:44:04 -07:00
Yury SemikhatskyandGitHub ba223bb11a chore(webview): mark new screenshot tests as expected failures (#41908) 2026-07-21 15:30:08 -07:00
Devin RoussoandGitHub ce37b096bd fix(mcp): report malformed JSON config instead of falling back to INI (#41909)
`loadConfig` fell back to INI parsing on any JSON error, so a typo'd JSON config (e.g. a trailing comma) was silently accepted as INI: the intended settings were dropped for the defaults and the raw JSON kept as an unused top-level key

surface the original `SyntaxError` when the input is a JSON object (`{`) while keeping the INI fallback (including files whose first line is a `[section]` header) and BOM handling

fixes <https://github.com/microsoft/playwright/issues/41893>
2026-07-21 14:47:59 -06:00
Yury SemikhatskyandGitHub 0e142cef72 fix(webkit): do not override Accept-Language header set by the page (#41904) 2026-07-21 11:19:31 -07:00
Pavel FeldmanandGitHub d83ec3212f chore(skills): move agent skills under playwright-core, add init-skills (#41887) 2026-07-21 11:03:59 -07:00
Pavel FeldmanandGitHub 6227b649ce Revert "feat(expect): add expect.fn() mock functions (#41884)" (#41906) 2026-07-21 11:03:49 -07:00
Pavel FeldmanandGitHub ecf2e53290 feat(expect): add expect.fn() mock functions with awaited assertions (#41884) 2026-07-21 08:41:41 -07:00
Dmitry GozmanandGitHub 06b65dc210 test: add a regression test for #40510 (#41903) 2026-07-21 16:28:22 +01:00
bc97a1306c fix(screencast): acknowledge frames after callbacks (#41898)
Co-authored-by: Copilot App <[email protected]>
2026-07-21 15:36:47 +02:00
microsoft-playwright-automation[bot]GitHubmicrosoft-playwright-automation[bot] <203992400+microsoft-playwright-automation[bot]@users.noreply.github.com>
d58bc892f2 test: roll stable-test-runner to 1.62.0-alpha-2026-07-20 (#41877)
Co-authored-by: microsoft-playwright-automation[bot] <203992400+microsoft-playwright-automation[bot]@users.noreply.github.com>
2026-07-20 18:48:07 -06:00
Yury SemikhatskyandGitHub 8cd58bad73 fix(firefox): do not override Accept-Language header set by the page (#41886) 2026-07-20 15:42:11 -07:00
Dmitry GozmanandGitHub 540ead4ecb chore: infer correct types for evalutes with exposeFunctions (#41876) 2026-07-20 15:00:01 -07:00
Akshat AnandandGitHub e8b395b2b0 fix(extension): pass client name on token-bypass connect (#41845) 2026-07-20 10:21:52 -07:00
Yury SemikhatskyandGitHub f7342d2099 chore(mcp): remove support for extension protocol v1 (#41857) 2026-07-20 10:12:24 -07:00
Dmitry GozmanandGitHub 4cd8608744 chore(chromium): better error message for evaluate result being collected (#41868) 2026-07-20 11:19:54 +01:00
Simon KnottandGitHub e23ccf335f fix(test): increase Intel macOS timeout (#41851) 2026-07-20 11:09:37 +02:00
Pavel FeldmanandGitHub 449349caea feat(test): make reuseContext public (#41858) 2026-07-17 15:36:09 -07:00
Holger BenlandGitHub ff91529ff7 test(bidi): various test updates (#41848) 2026-07-17 13:28:18 -07:00
Holger BenlandGitHub da345fbc37 chore(bidi): enable webp screenshot support (#41849) 2026-07-17 13:25:17 -07:00
Pavel FeldmanandGitHub f5ae97cb5d Revert "feat(test-runner): add httpCache config option" (#41855) 2026-07-17 11:06:53 -07:00
Devin RoussoandGitHub 8eba320a9a feat(webkit): support camera and microphone permissions (#41836)
map `camera` and `microphone` to their WebKit inspector protocol permissions so `context.grantPermissions(['camera', 'microphone'])` no longer throws

rolls WebKit to r2332 so that `navigator.mediaDevices.getUserMedia` now resolves with deterministic mock capture streams gated on the granted permissions (from <https://github.com/microsoft/playwright-browsers/pull/2415>)

fixes <https://github.com/microsoft/playwright/issues/2973>
2026-07-17 10:22:53 -06:00
d333a3aca5 test(firefox): fixme flaky "should create userDataDir" on macOS (#41811)
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Simon Knott <[email protected]>
2026-07-17 16:54:36 +02:00
Dmitry GozmanandGitHub beff82dd59 fix(fetch): use case-insensitive host header lookup on redirect (#41850) 2026-07-17 15:21:21 +01:00
Holger BenlandGitHub f80c4061d7 chore(bidi): add support for download ids (#41847) 2026-07-17 14:57:07 +01:00
Pavel FeldmanandGitHub c04da52811 feat(test-runner): add httpCache config option (#41687) 2026-07-16 14:36:15 -07:00
aa212a9b4a devops(ci): collapse stale triage comments (#41827)
Co-authored-by: Copilot App <[email protected]>
2026-07-16 13:20:13 -07:00
Dmitry GozmanandGitHub 98b2ffebd9 feat(aria): treat frame elements like iframes in aria snapshots (#41828) 2026-07-16 20:34:37 +01:00
2579345e89 fix(devops): normalize parquet file paths (#41823)
Co-authored-by: Copilot App <[email protected]>
2026-07-16 17:22:23 +02:00
Dmitry GozmanandGitHub 6693f583f4 fix(fetch): handle multi-value RDN in certificate security details (#41824) 2026-07-16 15:34:27 +01:00
Pavel FeldmanandGitHub 4e3c4278d2 feat(evaluate): allow passing functions as evaluate arguments (#41801) 2026-07-16 07:30:47 -07:00
Dmitry GozmanandGitHub a98ab942d0 test: unflake/skip some tests (#41817) 2026-07-16 15:02:27 +01:00
Dmitry GozmanandGitHub b7cd442732 fix(test runner): handle fixture option overrides (#41821) 2026-07-16 14:22:05 +01:00
Dmitry GozmanandGitHub 43e262f707 fix(aria): do not hang ai snapshot on frameset pages (#41816) 2026-07-16 13:15:04 +01:00