Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

ci(playwright): run queue gate jobs on depot runners (#125810)

Raúl Negrón-Otero3e19729cb5df
diff --git a/.agents/skills/authoring-ci-workflows/SKILL.md b/.agents/skills/authoring-ci-workflows/SKILL.md
index a4ddd38091da..937469525911 100644
--- a/.agents/skills/authoring-ci-workflows/SKILL.md
+++ b/.agents/skills/authoring-ci-workflows/SKILL.md
@@ -414,7 +414,7 @@ The only sanctioned exception is a job whose purpose is validating the migration
## Runners
-`depot-ubuntu-<version>[-<vCPU>]` for build/compute-heavy jobs (the `-4`/`-8` suffix bumps CPU from the 2-vCPU default); GitHub-hosted for light jobs.
+`depot-ubuntu-<version>[-<vCPU>]` for build/compute-heavy jobs (the `-4`/`-8` suffix bumps CPU from the 2-vCPU default); GitHub-hosted for light jobs, except light jobs on the critical path of a merge-queue required check, which pick Depot on `trunk-merge/` runs only because GitHub-hosted runners queue longer at busy hours.
**Name the OS version, never `ubuntu-latest`.**
GitHub moves the `-latest` aliases to a new image on its own schedule (24.04 became `latest` in 2025, 26.04 follows), which changes the toolchain and system packages under every job at once with nothing in this repo to bisect.
`WF011` rejects `ubuntu-latest`, `macos-latest`, `windows-latest` and the `depot-*-latest` mirrors in `runs-on` and in `strategy.matrix`, so use `ubuntu-24.04` (or `depot-ubuntu-24.04`) and land an image bump as its own PR.
diff --git a/.github/workflows/ci-e2e-playwright.yml b/.github/workflows/ci-e2e-playwright.yml
index 797468baf3ce..f91574918b48 100644
--- a/.github/workflows/ci-e2e-playwright.yml
+++ b/.github/workflows/ci-e2e-playwright.yml
@@ -101,7 +101,9 @@ jobs:
permissions:
contents: read
pull-requests: read
- runs-on: ubuntu-24.04
+ # Merge-queue runs use Depot because GitHub-hosted runners queue for minutes at busy hours
+ # and this job sits on the queue's required-check path. Other runs stay on free GitHub-hosted runners.
+ runs-on: ${{ startsWith(github.head_ref, 'trunk-merge/') && 'depot-ubuntu-24.04' || 'ubuntu-24.04' }}
# 7 not 5: the debounce step below sleeps up to 60s, so widen the budget to
# keep ample headroom. A timeout here skips Playwright, which the aggregator
# would count as a pass.
@@ -1428,7 +1430,8 @@ jobs:
playwright_tests:
needs: [changes, playwright, vr-complete]
name: Playwright tests pass
- runs-on: ubuntu-24.04
+ # Same runner choice as `changes`.
+ runs-on: ${{ startsWith(github.head_ref, 'trunk-merge/') && 'depot-ubuntu-24.04' || 'ubuntu-24.04' }}
timeout-minutes: 5
if: ${{ !cancelled() }}
steps: