{"record":{"id":"544b87f2ac1b1c07","repo":"microsoft/playwright","slug":"label-is-not-installed-location-run-comma","errorCode":null,"errorMessage":"${label} is not installed${location}. Run `${command}` to install","messagePattern":"(.+?) is not installed(.+?)\\. Run `(.+?)` to install","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"critical","filePath":"packages/playwright-core/src/tools/mcp/browserFactory.ts","lineNumber":263,"sourceCode":"  } catch {\n    return false;\n  }\n}\n\nfunction throwIfExecutableMissing(error: Error, config: FullConfig): void {\n  // The \"Executable doesn't exist\" prefix is shared by all managed binaries\n  // (browser, ffmpeg, winldd). Disambiguate by the path so the user is told\n  // which dependency to install, and surface the executable path itself so a\n  // version mismatch (an installed build vs. the expected build) is\n  // diagnosable rather than looking like a missing install.\n  if (!error.message.includes(`Executable doesn't exist`))\n    return;\n  const target = error.message.includes('ffmpeg') ? 'ffmpeg' : (config.browser.launchOptions?.channel ?? config.browser.browserName);\n  const label = target === 'ffmpeg' ? 'FFmpeg' : `Browser \"${target}\"`;\n  const command = config.skillMode ? `playwright-cli install-browser ${target}` : `npx @playwright/mcp install-browser ${target}`;\n  const match = error.message.match(/Executable doesn't exist at ([^\\r\\n]+)/);\n  const location = match ? `; expected executable at ${match[1].trim()}` : '';\n  throw new Error(`${label} is not installed${location}. Run \\`${command}\\` to install`);\n}\n","sourceCodeStart":245,"sourceCodeEnd":265,"githubUrl":"https://github.com/microsoft/playwright/blob/c8fc3bf8d31542d59b4d4d9eaab1df93ff541dc6/packages/playwright-core/src/tools/mcp/browserFactory.ts#L245-L265","documentation":"Thrown by `throwIfExecutableMissing` when a launch error's message includes `Executable doesn't exist` — Playwright's signal that a managed binary (browser or ffmpeg) is absent. The helper extracts the target name and expected path, then produces an actionable install command (`npx @playwright/mcp install-browser <target>` or `playwright-cli install-browser` in skill mode).","triggerScenarios":"Launching a browser channel/binary whose executable was never installed, was uninstalled, or whose installed build revision no longer matches the Playwright version in use. Also fires for ffmpeg (screencast) when its binary is missing.","commonSituations":"Fresh checkout without running `playwright install`; upgrading Playwright (new browser build revision) without reinstalling browsers; a CI cache that restored Playwright but not the browser binaries; explicitly selecting a channel (e.g. `msedge`) that isn't installed on the host; ffmpeg missing when screencast/recording is enabled.","solutions":["Run the exact command in the error message: `npx @playwright/mcp install-browser <target>` (or `playwright-cli install-browser <target>` in skill mode).","For a general fix, run `npx playwright install` to install all managed browsers.","If the path in the error looks wrong (stale cache), clear `~/AppData/Local/ms-playwright` (or `~/.cache/ms-playwright`) and reinstall.","For ffmpeg specifically, install ffmpeg support or disable screencast."],"exampleFix":"# before\nplaywright mcp   # \"Browser \"chromium\" is not installed\"\n# after\nnpx @playwright/mcp install-browser chromium\nplaywright mcp","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n  await launch(opts);\n} catch (e) {\n  if (/is not installed/.test((e as Error).message)) {\n    const { execSync } = require('child_process');\n    execSync('npx @playwright/mcp install-browser <target>', { stdio: 'inherit' });\n    await launch(opts); // retry once\n  } else throw e;\n}","preventionTips":["Run `npx playwright install` during project setup/CI bootstrap.","Reinstall browsers after upgrading Playwright (build revisions change).","Clear the ms-playwright cache if a version mismatch is suspected."],"tags":["browser-launch","install","executable","ffmpeg","version-mismatch"],"backgroundTag":null,"analyzedSha":"c8fc3bf8d31542d59b4d4d9eaab1df93ff541dc6","analyzedAt":"2026-08-12T07:26:36.950Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}