Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
797946e
fix: support async predicates in page.expect_request/expect_response …
Skn0tt Apr 30, 2026
67e59f5
fix(asyncio): do not deadlock in atexit handler (#3056)
dgozman Apr 30, 2026
f3d8fd1
fix: handle ignore_default_args=False in launch params (#3058)
Skn0tt Apr 30, 2026
86415b6
fix(typing): typed overloads for expect_event and wait_for_event (#3061)
dgozman Apr 30, 2026
9035a63
build(deps): bump the actions group across 1 directory with 4 updates…
dependabot[bot] May 4, 2026
58e36b3
build(deps): bump pyopenssl from 25.1.0 to 26.0.0 in the pip group ac…
dependabot[bot] May 4, 2026
2a384b1
build(deps): bump setuptools-scm from 8.3.1 to 9.2.2 (#2994)
dependabot[bot] May 4, 2026
deb2df8
build(deps): bump pytest-cov from 6.3.0 to 7.1.0 (#2976)
dependabot[bot] May 4, 2026
ac9bf29
build(deps): bump types-requests from 2.32.4.20250809 to 2.32.4.20260…
dependabot[bot] May 4, 2026
161bd3d
build(deps): bump flake8 from 7.2.0 to 7.3.0 (#2896)
dependabot[bot] May 4, 2026
856ae37
devops: Update EsrpRelease (#3064)
Skn0tt May 5, 2026
9df9fac
feat: accept datetime.timedelta for timeout parameters (#3059)
Skn0tt May 5, 2026
873c5c7
fix(setup): update auditwheel to 6.4.0 for InWheel tempdir fix (#3063)
Copilot May 6, 2026
b846cee
chore: roll to 1.60.0-beta-1778142790000 (#3069)
Skn0tt May 7, 2026
18810d8
feat: add FormData class for form and multipart requests (#3060)
dgozman May 12, 2026
0ebdf2d
feat(assertions): add expect.soft() for collecting multiple failures …
Skn0tt May 12, 2026
93f3201
chore: roll driver to 1.60.0 (#3079)
Skn0tt May 18, 2026
0c81861
fix(documentation_provider): correct spelling "redundant" in function…
26rahulchoudhary May 18, 2026
d7ec09a
fix(assertions): render aria snapshot in its own section on expect fa…
Skn0tt Jun 8, 2026
7a387f2
chore: drop Conda distribution (#3091)
Skn0tt Jun 8, 2026
7a62e1a
Fix handler wrapping for keyword-only parameters (#3084)
rohan-patnaik Jun 8, 2026
97d57a0
devops: Build driver from source (#3092)
Skn0tt Jun 9, 2026
61c91f9
build(deps-dev): bump wheel from 0.45.1 to 0.47.0 (#3075)
dependabot[bot] Jun 9, 2026
3ae339f
build(deps): bump pyee from 13.0.0 to 13.0.1 (#3074)
dependabot[bot] Jun 9, 2026
0b21ee2
build(deps): bump black from 25.1.0 to 25.11.0 (#3073)
dependabot[bot] Jun 9, 2026
c90d8b1
build(deps): bump pytest-rerunfailures from 15.1 to 16.0.1 (#3072)
dependabot[bot] Jun 9, 2026
e4892fa
build(deps): bump build from 1.3.0 to 1.4.4 (#3071)
dependabot[bot] Jun 9, 2026
95db482
fix: handle missing content-type header in Request.post_data_json (#3…
Skn0tt Jun 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .azure-pipelines/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ extends:
inputs:
versionSpec: '3.9'
displayName: 'Use Python'
- task: NodeTool@0
inputs:
versionSpec: '24.x'
displayName: 'Use Node.js'
- script: |
python -m pip install --upgrade pip
pip install -r local-requirements.txt
Expand All @@ -60,7 +64,7 @@ extends:
targetPath: $(Build.ArtifactStagingDirectory)/esrp-build
steps:
- checkout: none
- task: EsrpRelease@9
- task: EsrpRelease@11
inputs:
connectedservicename: 'Playwright-ESRP-PME'
usemanagedidentity: true
Expand Down
25 changes: 17 additions & 8 deletions .claude/skills/playwright-roll/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description: Roll Playwright Python to a new driver version. Walks the upstream

# Rolling Playwright Python

The goal of a roll is to move `driver_version` in `setup.py` to a new release, port every public API change introduced upstream during that interval, and suppress the rest, so that `./scripts/update_api.sh` runs clean and the test suite still passes.
The goal of a roll is to move the driver pin in `DRIVER_SHA` to a new release, port every public API change introduced upstream during that interval, and suppress the rest, so that `./scripts/update_api.sh` runs clean and the test suite still passes.

The previous human-facing summary lives in `../../../ROLLING.md`. This skill is the operational playbook — read it end to end before starting.

Expand All @@ -15,7 +15,7 @@ The Python port is hand-written code in `playwright/_impl/`, plus a generator (`

1. introspects the Python `_impl` classes via `inspect`,
2. emits typed wrapper classes into `playwright/{async,sync}_api/_generated.py`, and
3. diffs the introspected surface against `playwright/driver/package/api.json` (downloaded inside the new driver wheel).
3. diffs the introspected surface against `playwright/driver/package/api.json` (built into the new driver from source).

Anything in `api.json` that is missing or differently typed in `_impl/` causes generation to fail. Three resolutions:

Expand Down Expand Up @@ -52,18 +52,27 @@ There is sometimes no `vX.Y.0` tag for the latest release (the bots cut release
- If `python3-venv` is missing system-wide, use `uv venv env` instead, then `uv pip install --python env/bin/python --upgrade pip`. Don't try to `apt install` — sudo is denied in the harness.
- Always activate the venv before any `pip`, `pytest`, `mypy`, or `pre-commit` invocation.

### 2. Bump the driver and download it
### 2. Bump the driver and build it from source

```sh
# Edit setup.py
driver_version = "<new>" # e.g. "1.59.1"
# Edit DRIVER_SHA (repo root): replace with the microsoft/playwright commit SHA
# for the new release, e.g. the commit that v<new> points at.
# 87bb9ddbd78f329df18c2b24847bc9409240cd07
# Update the "# microsoft/playwright @ v<new>" comment in scripts/build_driver.sh too.

source env/bin/activate
python -m build --wheel # downloads the new driver from cdn.playwright.dev
python -m build --wheel # clones microsoft/playwright @ DRIVER_SHA and builds the driver from source
playwright install chromium # NOT --with-deps; sudo is denied
```

The wheel build prints `Fetching https://cdn.playwright.dev/builds/driver/playwright-<new>-linux.zip` and unpacks the driver under `playwright/driver/package/`. From this point, `playwright/driver/package/api.json` reflects the new release.
The wheel build clones `microsoft/playwright` at the commit in `DRIVER_SHA`
into `driver/playwright-src`, runs `npm ci && npm run build`, and runs upstream's
`utils/build/build-playwright-driver.sh` to produce the per-platform driver
bundles (`driver/playwright-<sha>-*.zip`), then unpacks the driver under
`playwright/driver/package/`. From this point,
`playwright/driver/package/api.json` reflects the new release. This requires
**Node.js, npm, git and bash** on PATH; the first build is slow (full upstream
build + per-platform Node downloads).

### 3. Identify the commit range

Expand Down Expand Up @@ -240,7 +249,7 @@ For each PORT, add one async test and a matching sync test. Conventions:

### 7. Update existing high-touch artifacts

- `setup.py`: already done in step 2.
- `DRIVER_SHA` (and the version comment in `scripts/build_driver.sh`): already done in step 2.
- `README.md`: gets the chromium/firefox/webkit version table updated automatically by `scripts/update_versions.py` (called from `update_api.sh`). Don't edit by hand.
- The "Backport changes" tracking issue on GitHub (filed by `microsoft-playwright-automation`) is the *intent* tracker, but it's frequently out of sync with what's actually been ported. Treat it as a starting point, not the source of truth — the `docs/src/api/` commit walk is authoritative.

Expand Down
77 changes: 44 additions & 33 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,43 @@ concurrency:
cancel-in-progress: true

jobs:
build-driver:
name: Build driver
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v6
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
- name: Build driver bundles from source
run: bash scripts/build_driver.sh
- name: Upload driver bundles
uses: actions/upload-artifact@v4
with:
name: driver-bundles
path: driver/playwright-*.zip
if-no-files-found: error
# The bundles are already-compressed zips; skip re-compression.
compression-level: 0
retention-days: 1

infra:
name: Lint
needs: build-driver
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.10"
- name: Download driver bundles
uses: actions/download-artifact@v4
with:
name: driver-bundles
path: driver/
- name: Install dependencies & browsers
run: |
python -m pip install --upgrade pip
Expand All @@ -43,6 +71,7 @@ jobs:

build:
name: Build
needs: build-driver
timeout-minutes: 45
strategy:
fail-fast: false
Expand Down Expand Up @@ -91,11 +120,16 @@ jobs:
browser: chromium
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Download driver bundles
uses: actions/download-artifact@v4
with:
name: driver-bundles
path: driver/
- name: Install dependencies & browsers
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -125,6 +159,7 @@ jobs:

test-stable:
name: Stable
needs: build-driver
timeout-minutes: 45
strategy:
fail-fast: false
Expand All @@ -138,11 +173,16 @@ jobs:
browser-channel: msedge
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.10"
- name: Download driver bundles
uses: actions/download-artifact@v4
with:
name: driver-bundles
path: driver/
- name: Install dependencies & browsers
run: |
python -m pip install --upgrade pip
Expand All @@ -166,43 +206,14 @@ jobs:
if: matrix.os == 'ubuntu-latest'
run: xvfb-run pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} --timeout 90

build-conda:
name: Conda Build
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, macos-latest, windows-2022]
runs-on: ${{ matrix.os }}
defaults:
run:
# `setup-miniconda` activates the env only for login shells; using
# `bash -el` (recommended by the action) ensures `conda` and the
# installed `conda-build` are on PATH on every OS, including Windows
# where the default shell is pwsh and skips the activation hooks.
shell: bash -el {0}
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Get conda
uses: conda-incubator/setup-miniconda@v3
with:
python-version: '3.12'
channels: conda-forge
miniconda-version: latest
- name: Prepare
run: conda install -n base "conda-build>=26" conda-verify
- name: Build
run: conda build .

test_examples:
name: Examples
runs-on: ubuntu-22.04
defaults:
run:
working-directory: examples/todomvc/
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
Expand Down
50 changes: 0 additions & 50 deletions .github/workflows/publish.yml

This file was deleted.

10 changes: 7 additions & 3 deletions .github/workflows/publish_docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ jobs:
contents: read # This is required for actions/checkout to succeed
environment: Docker
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Azure login
uses: azure/login@v2
uses: azure/login@v3
with:
client-id: ${{ secrets.AZURE_DOCKER_CLIENT_ID }}
tenant-id: ${{ secrets.AZURE_DOCKER_TENANT_ID }}
Expand All @@ -28,8 +28,12 @@ jobs:
uses: actions/setup-python@v6
with:
python-version: "3.10"
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
- name: Set up Docker QEMU for arm64 docker builds
uses: docker/setup-qemu-action@v3
uses: docker/setup-qemu-action@v4
with:
platforms: arm64
- name: Install dependencies & browsers
Expand Down
10 changes: 9 additions & 1 deletion .github/workflows/test_docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,15 @@ jobs:
- ubuntu-24.04
- ubuntu-24.04-arm
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: "3.10"
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '24'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand All @@ -53,6 +57,10 @@ jobs:
docker exec "${CONTAINER_ID}" pip install -r local-requirements.txt
docker exec "${CONTAINER_ID}" pip install -r requirements.txt
docker exec "${CONTAINER_ID}" pip install -e .
# build.sh (above) already built the driver bundles into driver/ on the
# host. The repo is bind-mounted into the container, so this in-container
# wheel build reuses those bundles (setup.py skips the source build when
# the zip already exists) and therefore needs no Node.js in the image.
docker exec "${CONTAINER_ID}" python -m build --wheel
docker exec "${CONTAINER_ID}" xvfb-run pytest tests/sync/
docker exec "${CONTAINER_ID}" xvfb-run pytest tests/async/
Loading
Loading