From d6cc5d5f29cd45192de2f97f1bbe6d7ba7f12289 Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Tue, 20 Oct 2026 14:13:15 -0700 Subject: [PATCH 1/6] chore: mark 1.64.0 (#2013) --- driver-bundle/pom.xml | 2 +- driver/pom.xml | 2 +- examples/pom.xml | 2 +- playwright/pom.xml | 2 +- pom.xml | 2 +- tools/api-generator/pom.xml | 2 +- tools/test-cli-fatjar/pom.xml | 2 +- tools/test-cli-version/pom.xml | 2 +- tools/test-local-installation/pom.xml | 2 +- tools/test-spring-boot-starter/pom.xml | 2 +- tools/update-docs-version/pom.xml | 2 +- 11 files changed, 11 insertions(+), 11 deletions(-) diff --git a/driver-bundle/pom.xml b/driver-bundle/pom.xml index 1f65521ad..84f0b12a7 100644 --- a/driver-bundle/pom.xml +++ b/driver-bundle/pom.xml @@ -6,7 +6,7 @@ com.microsoft.playwright parent-pom - 1.50.0-SNAPSHOT + 1.64.0 driver-bundle diff --git a/driver/pom.xml b/driver/pom.xml index bf621037f..5d352e806 100644 --- a/driver/pom.xml +++ b/driver/pom.xml @@ -6,7 +6,7 @@ com.microsoft.playwright parent-pom - 1.50.0-SNAPSHOT + 1.64.0 driver diff --git a/examples/pom.xml b/examples/pom.xml index 66f426a37..6c32fb950 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -6,7 +6,7 @@ org.example examples - 1.50.0-SNAPSHOT + 1.64.0 Playwright Client Examples UTF-8 diff --git a/playwright/pom.xml b/playwright/pom.xml index 2362d86f2..62cabf52f 100644 --- a/playwright/pom.xml +++ b/playwright/pom.xml @@ -7,7 +7,7 @@ com.microsoft.playwright parent-pom - 1.50.0-SNAPSHOT + 1.64.0 playwright diff --git a/pom.xml b/pom.xml index ef7778a43..7d8fedeb1 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ com.microsoft.playwright parent-pom - 1.50.0-SNAPSHOT + 1.64.0 pom Playwright Parent Project Java library to automate Chromium, Firefox and WebKit with a single API. diff --git a/tools/api-generator/pom.xml b/tools/api-generator/pom.xml index 2e75e4c4e..ad899935c 100644 --- a/tools/api-generator/pom.xml +++ b/tools/api-generator/pom.xml @@ -6,7 +6,7 @@ com.microsoft.playwright api-generator - 1.50.0-SNAPSHOT + 1.64.0 Playwright - API Generator This is an internal module used to generate Java API from the upstream Playwright diff --git a/tools/test-cli-fatjar/pom.xml b/tools/test-cli-fatjar/pom.xml index 916e92187..086083d79 100644 --- a/tools/test-cli-fatjar/pom.xml +++ b/tools/test-cli-fatjar/pom.xml @@ -4,7 +4,7 @@ 4.0.0 com.microsoft.playwright test-cli-fatjar - 1.50.0-SNAPSHOT + 1.64.0 Test Playwright Command Line FatJar 1.8 diff --git a/tools/test-cli-version/pom.xml b/tools/test-cli-version/pom.xml index fcb8a842a..2df6c58d2 100644 --- a/tools/test-cli-version/pom.xml +++ b/tools/test-cli-version/pom.xml @@ -4,7 +4,7 @@ 4.0.0 com.microsoft.playwright test-cli-version - 1.50.0-SNAPSHOT + 1.64.0 Test Playwright Command Line Version 1.8 diff --git a/tools/test-local-installation/pom.xml b/tools/test-local-installation/pom.xml index 6ce2ed4fa..5115abdd3 100644 --- a/tools/test-local-installation/pom.xml +++ b/tools/test-local-installation/pom.xml @@ -4,7 +4,7 @@ 4.0.0 com.microsoft.playwright test-local-installation - 1.50.0-SNAPSHOT + 1.64.0 Test local installation Runs Playwright test suite (copied from playwright module) against locally cached Playwright diff --git a/tools/test-spring-boot-starter/pom.xml b/tools/test-spring-boot-starter/pom.xml index 953e5afcc..96cf3274b 100644 --- a/tools/test-spring-boot-starter/pom.xml +++ b/tools/test-spring-boot-starter/pom.xml @@ -9,7 +9,7 @@ com.microsoft.playwright test-spring-boot-starter - 1.50.0-SNAPSHOT + 1.64.0 Test Playwright With Spring Boot 2.4.3 diff --git a/tools/update-docs-version/pom.xml b/tools/update-docs-version/pom.xml index cf24731ad..24854ffbd 100644 --- a/tools/update-docs-version/pom.xml +++ b/tools/update-docs-version/pom.xml @@ -6,7 +6,7 @@ com.microsoft.playwright update-version - 1.50.0-SNAPSHOT + 1.64.0 Playwright - Update Version in Documentation This is an internal module used to update versions in the documentation based on From 0b8a31e3df2c77e06ee99a60d54bc5e0964035f5 Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Wed, 21 Oct 2026 10:35:05 -0700 Subject: [PATCH 2/6] cherry-pick(#2015): devops(docker): download Maven through the configured Maven mirror --- utils/docker/Dockerfile.jammy | 13 ++++++------- utils/docker/Dockerfile.noble | 13 ++++++------- utils/docker/build.sh | 8 ++++++++ 3 files changed, 20 insertions(+), 14 deletions(-) diff --git a/utils/docker/Dockerfile.jammy b/utils/docker/Dockerfile.jammy index 9b5fa00f3..4440772ea 100644 --- a/utils/docker/Dockerfile.jammy +++ b/utils/docker/Dockerfile.jammy @@ -26,13 +26,12 @@ RUN find /etc/apt -type f \( -name '*.list' -o -name '*.sources' \) \ adduser pwuser # Ubuntu 22.04 and earlier come with Maven 3.6.3 which fails with -# Java 25, so we install latest Maven from Apache instead. -RUN VERSION=3.9.12 && \ - wget --tries=3 --timeout=30 --retry-connrefused -O /tmp/maven.tar.gz \ - https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/$VERSION/apache-maven-$VERSION-bin.tar.gz && \ - tar zxf /tmp/maven.tar.gz -C /opt/ && \ - rm /tmp/maven.tar.gz && \ - ln -s /opt/apache-maven-$VERSION/bin/mvn /usr/local/bin/ +# Java 25, so we install latest Maven from Apache instead. build.sh +# downloads it into utils/docker/maven. +ARG MAVEN_VERSION +RUN --mount=type=bind,source=utils/docker/maven,target=/tmp/maven \ + tar zxf /tmp/maven/apache-maven-$MAVEN_VERSION-bin.tar.gz -C /opt/ && \ + ln -s /opt/apache-maven-$MAVEN_VERSION/bin/mvn /usr/local/bin/ ARG PW_TARGET_ARCH ENV JAVA_HOME=/usr/lib/jvm/java-25-openjdk-${PW_TARGET_ARCH} diff --git a/utils/docker/Dockerfile.noble b/utils/docker/Dockerfile.noble index 29ff1c9b9..52779ce15 100644 --- a/utils/docker/Dockerfile.noble +++ b/utils/docker/Dockerfile.noble @@ -26,13 +26,12 @@ RUN find /etc/apt -type f \( -name '*.list' -o -name '*.sources' \) \ adduser pwuser # Ubuntu 22.04 and earlier come with Maven 3.6.3 which fails with -# Java 25, so we install latest Maven from Apache instead. -RUN VERSION=3.9.12 && \ - wget --tries=3 --timeout=30 --retry-connrefused -O /tmp/maven.tar.gz \ - https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/$VERSION/apache-maven-$VERSION-bin.tar.gz && \ - tar zxf /tmp/maven.tar.gz -C /opt/ && \ - rm /tmp/maven.tar.gz && \ - ln -s /opt/apache-maven-$VERSION/bin/mvn /usr/local/bin/ +# Java 25, so we install latest Maven from Apache instead. build.sh +# downloads it into utils/docker/maven. +ARG MAVEN_VERSION +RUN --mount=type=bind,source=utils/docker/maven,target=/tmp/maven \ + tar zxf /tmp/maven/apache-maven-$MAVEN_VERSION-bin.tar.gz -C /opt/ && \ + ln -s /opt/apache-maven-$MAVEN_VERSION/bin/mvn /usr/local/bin/ ARG PW_TARGET_ARCH ENV JAVA_HOME=/usr/lib/jvm/java-25-openjdk-${PW_TARGET_ARCH} diff --git a/utils/docker/build.sh b/utils/docker/build.sh index efd5e6670..c1225245d 100755 --- a/utils/docker/build.sh +++ b/utils/docker/build.sh @@ -38,6 +38,13 @@ PW_TARGET_ARCH=$(echo $1 | cut -c3-) # it up via `COPY . /tmp/pw-java`. ../../scripts/download_driver.sh +# The jammy and noble images install this Maven (see the Dockerfiles). Fetch it with the +# host's Maven so that it resolves through the configured mirror: the release pipeline +# cannot reach Maven Central directly (see .azure-pipelines/settings.xml). +MAVEN_VERSION=3.9.12 +mvn dependency:copy -Dartifact="org.apache.maven:apache-maven:${MAVEN_VERSION}:tar.gz:bin" \ + -DoutputDirectory=maven --no-transfer-progress -q + SECRET_ARGS=() if [[ -n "${MAVEN_SETTINGS_SECRET:-}" ]]; then SECRET_ARGS+=(--secret "id=mavensettings,src=${MAVEN_SETTINGS_SECRET}") @@ -59,6 +66,7 @@ fi for ((attempt = 1; attempt <= MAX_ATTEMPTS; attempt++)); do if docker build --platform "${PLATFORM}" \ --build-arg "PW_TARGET_ARCH=${PW_TARGET_ARCH}" \ + --build-arg "MAVEN_VERSION=${MAVEN_VERSION}" \ --build-arg ACR_CACHE_PREFIX="${ACR_CACHE_PREFIX}" \ --build-arg UBUNTU_MIRROR_PREFIX="${UBUNTU_MIRROR_PREFIX}" \ "${SECRET_ARGS[@]}" \ From b9159827a5afdd88c1db457feef7c003997c3568 Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Tue, 3 Nov 2026 11:03:27 -0800 Subject: [PATCH 3/6] cherry-pick(#2037): devops(docker): exclude .git from the Docker build context --- .dockerignore | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.dockerignore b/.dockerignore index f609d7b5c..7dc6ab376 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,5 +1,8 @@ -# The repository root is the Docker build context (see utils/docker/build.sh). -# Keep registry credentials written by the release pipeline out of the images. +# The repository root is the Docker build context (see utils/docker/build.sh), +# and the image build copies all of it. Keep VCS metadata, registry credentials +# and local environment files out of the build context. +**/.git **/.npmrc +**/.env* # Downloaded by publish_docker.sh after the first push. utils/docker/oras From 51492472abe97c587149371c79bad301337e99bc Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Tue, 3 Nov 2026 11:03:27 -0800 Subject: [PATCH 4/6] cherry-pick(#2036): devops: add explicit checkout steps to pipelines --- .azure-pipelines/publish-docker.yml | 1 + .azure-pipelines/publish.yml | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/.azure-pipelines/publish-docker.yml b/.azure-pipelines/publish-docker.yml index 48ef7f9a6..53095d1b4 100644 --- a/.azure-pipelines/publish-docker.yml +++ b/.azure-pipelines/publish-docker.yml @@ -47,6 +47,7 @@ extends: timeoutInMinutes: 360 steps: - checkout: self + persistCredentials: false displayName: "Checkout code" - task: UseNode@1 diff --git a/.azure-pipelines/publish.yml b/.azure-pipelines/publish.yml index 4572d6cd8..c17cd96c3 100644 --- a/.azure-pipelines/publish.yml +++ b/.azure-pipelines/publish.yml @@ -36,6 +36,10 @@ extends: path: $(Build.ArtifactStagingDirectory)/esrp-build artifact: esrp-build steps: + - checkout: self + persistCredentials: false + displayName: "Checkout code" + - bash: | if [[ ! "$CURRENT_BRANCH" =~ ^v1\..* ]]; then echo "Can only publish from a release tag branch (v1.*)." From 9d5a72a114869caf22c9b282fee52577e16e64e0 Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Tue, 3 Nov 2026 13:45:02 -0800 Subject: [PATCH 5/6] cherry-pick(#2038): devops: pin the Node.js major version of the driver in scripts/NODE_VERSION --- .github/workflows/test_docker.yml | 1 + CONTRIBUTING.md | 2 +- scripts/NODE_VERSION | 1 + scripts/download_driver.sh | 29 ++++++++++++++++------------- scripts/roll_driver.sh | 10 ++++------ utils/docker/Dockerfile.jammy | 2 ++ utils/docker/Dockerfile.noble | 2 ++ utils/docker/Dockerfile.resolute | 2 ++ 8 files changed, 29 insertions(+), 20 deletions(-) create mode 100644 scripts/NODE_VERSION diff --git a/.github/workflows/test_docker.yml b/.github/workflows/test_docker.yml index 36b07f466..cd8f86606 100644 --- a/.github/workflows/test_docker.yml +++ b/.github/workflows/test_docker.yml @@ -12,6 +12,7 @@ on: - .github/workflows/test_docker.yml - '**/Dockerfile*' - scripts/DRIVER_VERSION + - scripts/NODE_VERSION - '**/pom.xml' branches: - main diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 1a54c0547..4601061f6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -41,7 +41,7 @@ cd playwright-java scripts/download_driver.sh ``` -Each driver is assembled from the [`playwright-core`](https://www.npmjs.com/package/playwright-core) npm package (version pinned in [scripts/DRIVER_VERSION](scripts/DRIVER_VERSION)) and the matching Node.js binary from https://nodejs.org, the same way the upstream Playwright build does it. +Each driver is assembled from the [`playwright-core`](https://www.npmjs.com/package/playwright-core) npm package (version pinned in [scripts/DRIVER_VERSION](scripts/DRIVER_VERSION)) and the latest Node.js binary of the major version pinned in [scripts/NODE_VERSION](scripts/NODE_VERSION) from https://nodejs.org, the same way the upstream Playwright build does it. ### Building and running the tests with Maven diff --git a/scripts/NODE_VERSION b/scripts/NODE_VERSION new file mode 100644 index 000000000..6f4247a62 --- /dev/null +++ b/scripts/NODE_VERSION @@ -0,0 +1 @@ +26 diff --git a/scripts/download_driver.sh b/scripts/download_driver.sh index 5e36f91e3..24a53de7f 100755 --- a/scripts/download_driver.sh +++ b/scripts/download_driver.sh @@ -10,10 +10,10 @@ if [[ ($1 == '-h') || ($1 == '--help') ]]; then echo "" echo "This script downloads and assembles the Playwright driver for all platforms." echo "The platform-independent 'playwright-core' npm package is assembled once into the driver" - echo "module ('driver/src/main/resources/driver/package'), and the matching Node.js binary from" - echo "https://nodejs.org for each platform goes into the driver-bundle module" - echo "('driver-bundle/src/main/resources/driver/'), the same way the upstream" - echo "Playwright build does it." + echo "module ('driver/src/main/resources/driver/package'), and the Node.js binary from" + echo "https://nodejs.org (major version pinned in scripts/NODE_VERSION) for each platform goes" + echo "into the driver-bundle module ('driver-bundle/src/main/resources/driver/'), the" + echo "same way the upstream Playwright build does it." echo "" echo "Usage: scripts/download_driver.sh [option]" echo "" @@ -46,13 +46,19 @@ npm_at_root() { (cd "$ROOT" && npm "$@") } -# The Node.js version used to be pinned in the upstream driver build script. The script was -# removed in microsoft/playwright#41518, so we follow the same policy it had: the latest -# Node.js LTS (see upstream utils/build/update-playwright-node.mjs). -NODE_VERSION=$(curl -fsSL "https://nodejs.org/dist/index.json" \ - | node -e "let s='';process.stdin.on('data',d=>s+=d).on('end',()=>console.log(JSON.parse(s).find(r=>r.lts).version.slice(1)))") +TMP_DIR="$(mktemp -d)" +trap 'rm -rf "$TMP_DIR"' EXIT + +# scripts/NODE_VERSION pins the Node.js major version, like ARG NODE_VERSION in the upstream +# Docker images. Use the latest release of that major version. +NODE_MAJOR_VERSION=$(head -1 ./NODE_VERSION) +# The checksum list of the latest release names every file after the release, e.g. +# d38bd5e5... node-v26.13.0-darwin-arm64.tar.gz +SHASUMS="$TMP_DIR/SHASUMS256.txt" +download "https://nodejs.org/dist/latest-v$NODE_MAJOR_VERSION.x/SHASUMS256.txt" "$SHASUMS" +NODE_VERSION=$(sed -nE 's/.*node-v([0-9]+\.[0-9]+\.[0-9]+)-.*/\1/p' "$SHASUMS" | head -1) if [[ -z "$NODE_VERSION" ]]; then - echo "Failed to determine the latest Node.js LTS version" + echo "Failed to determine the latest Node.js $NODE_MAJOR_VERSION.x version" exit 1 fi @@ -64,9 +70,6 @@ echo "Node.js version: $NODE_VERSION" CORE_DEST="$ROOT/driver/src/main/resources/driver" NODE_DEST="$ROOT/driver-bundle/src/main/resources/driver" -TMP_DIR="$(mktemp -d)" -trap 'rm -rf "$TMP_DIR"' EXIT - # 1. playwright-core package -> driver module (once, shared by every platform). echo "Assembling playwright-core package to $CORE_DEST/package" rm -rf "$CORE_DEST/package" diff --git a/scripts/roll_driver.sh b/scripts/roll_driver.sh index f8535e57f..4b45e85a2 100755 --- a/scripts/roll_driver.sh +++ b/scripts/roll_driver.sh @@ -24,12 +24,10 @@ fi CURRENT_VERSION=$(head -1 ./DRIVER_VERSION) echo "Rolling driver from $CURRENT_VERSION to $NEW_VERSION" -if [[ "$CURRENT_VERSION" == "$NEW_VERSION" ]]; then - echo "Current version is up to date. Skipping driver download."; -else - echo $NEW_VERSION > ./DRIVER_VERSION - ./download_driver.sh -fi; +echo $NEW_VERSION > ./DRIVER_VERSION +# Download even when the driver version is unchanged: the driver bundles the latest release +# of the Node.js major version pinned in NODE_VERSION. +./download_driver.sh ./generate_api.sh ./update_readme.sh diff --git a/utils/docker/Dockerfile.jammy b/utils/docker/Dockerfile.jammy index 4440772ea..316a95d4f 100644 --- a/utils/docker/Dockerfile.jammy +++ b/utils/docker/Dockerfile.jammy @@ -19,6 +19,8 @@ RUN find /etc/apt -type f \( -name '*.list' -o -name '*.sources' \) \ wget \ # Install utilities required for downloading driver unzip \ + # The Node.js binary of the driver links against libatomic (since Node.js 25) + libatomic1 \ # For the MSEdge install script gpg && \ rm -rf /var/lib/apt/lists/* && \ diff --git a/utils/docker/Dockerfile.noble b/utils/docker/Dockerfile.noble index 52779ce15..5ccd4d7bf 100644 --- a/utils/docker/Dockerfile.noble +++ b/utils/docker/Dockerfile.noble @@ -19,6 +19,8 @@ RUN find /etc/apt -type f \( -name '*.list' -o -name '*.sources' \) \ wget \ # Install utilities required for downloading driver unzip \ + # The Node.js binary of the driver links against libatomic (since Node.js 25) + libatomic1 \ # For the MSEdge install script gpg && \ rm -rf /var/lib/apt/lists/* && \ diff --git a/utils/docker/Dockerfile.resolute b/utils/docker/Dockerfile.resolute index 905962beb..7dabf1f96 100644 --- a/utils/docker/Dockerfile.resolute +++ b/utils/docker/Dockerfile.resolute @@ -21,6 +21,8 @@ RUN find /etc/apt -type f \( -name '*.list' -o -name '*.sources' \) \ wget \ # Install utilities required for downloading driver unzip \ + # The Node.js binary of the driver links against libatomic (since Node.js 25) + libatomic1 \ # For the MSEdge install script gpg && \ rm -rf /var/lib/apt/lists/* && \ From eedd89b781af2abb7d67a314461f0534e3910d17 Mon Sep 17 00:00:00 2001 From: Yury Semikhatsky Date: Wed, 4 Nov 2026 12:35:35 -0800 Subject: [PATCH 6/6] devops: pin the driver's Node.js major version to 24 on release-1.64 (#2039) --- scripts/NODE_VERSION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/NODE_VERSION b/scripts/NODE_VERSION index 6f4247a62..a45fd52cc 100644 --- a/scripts/NODE_VERSION +++ b/scripts/NODE_VERSION @@ -1 +1 @@ -26 +24