Skip to content

[Bug]: npm run doc (and npm run flint) hard-fails when WebKit cannot launch on Linux #40317

@Dev-iL

Description

@Dev-iL

Version

1.50.0 (main branch)

Steps to reproduce

  1. Set up a Playwright contributor environment on Ubuntu 24.04
  2. Run npm ci && npm run build
  3. Run npm run flint (or npm run doc directly)

Expected behavior

npm run flint completes successfully. Browser version numbers that cannot be obtained at launch are read from browsers.json instead of aborting the run.

Actual behavior

browserType.launch:
╔════════════════════════════════════════════════════════╗
║ Host system is missing dependencies to run browsers.   ║
║ Please install them with the following command:        ║
║                                                        ║
║     sudo npx playwright install-deps                   ║
║                                                        ║
║ Alternatively, use apt:                                ║
║     sudo apt-get install libgstreamer-plugins-bad1.0-0 ║
║                                                        ║
║ <3 Playwright Team                                     ║
╚════════════════════════════════════════════════════════╝

libgstreamer-plugins-bad1.0-0 is not available on Ubuntu 24.04 — its GL component is provided by libgstreamer-gl1.0-0 (already installed). Chromium and Firefox both launch successfully on this system; only WebKit is affected.

Additional context

Root cause

getBrowserVersions() in utils/doclint/cli.js uses Promise.all to launch all three browsers simultaneously. A single launch failure causes the entire promise to reject, aborting npm run doc even though the Chromium and Firefox versions were obtained successfully. WebKit's version is already stored in browsers.json (see #15702), so there is a natural fallback available.

Environment

System:
    OS: Linux 6.8 Ubuntu 24.04.4 LTS 24.04.4 LTS (Noble Numbat)
    CPU: (8) x64 Intel(R) Core(TM) i7-3770 CPU @ 3.40GHz
    Memory: 10.51 GB / 31.29 GB
    Container: Yes
  Binaries:
    Node: 23.5.0 - /home/USER/.nvm/versions/node/v23.5.0/bin/node
    Yarn: 4.5.3 - /usr/local/bin/yarn
    npm: 11.11.1 - /home/USER/.nvm/versions/node/v23.5.0/bin/npm
    pnpm: 10.32.1 - /usr/local/bin/pnpm
  IDEs:
    VSCode: 1.115.0 - /usr/bin/code
    Claude Code: 2.1.114 - /home/USER/.local/bin/claude
    Codex: 0.121.0 - /home/USER/.nvm/versions/node/v23.5.0/bin/codex
  Languages:
    Bash: 5.2.21 - /usr/bin/bash

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions