Repository navigation
Conversation
capture.mjs, drive.mjs and turn-check.mjs all fall back to Chrome installed by `npx playwright install` under %LOCALAPPDATA%\ms-playwright on Windows. print.mjs copied the rest of chromePath() but not that block, so on a Windows machine with only Playwright's Chromium (no system Chrome or Edge), every other script finds a browser and print.mjs alone fails with "No Chrome found". scripts/chrome-path-parity.test.mjs checks every chromePath() for this lookup; it fails on main and passes with this change.
SID-6921
force-pushed
the
fix/print-windows-playwright-chrome-path
branch
from
November 11, 2026 00:30
3f82db8 to
e970e7e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
print.mjs'schromePath()now also looks for a browser under%LOCALAPPDATA%\ms-playwright(the directorynpx playwright installwrites to on Windows), the same waycapture.mjs,drive.mjsandturn-check.mjsalready do.Why
All four scripts carry their own copy of
chromePath(). Three of them (capture.mjs,drive.mjs,turn-check.mjs) were given a Windows Playwright fallback in #75.print.mjswas added later in #126 from an older copy of the function and never got that block, so on a Windows machine that only has Playwright's Chromium (no system Chrome or Edge installed), every other script finds a browser andprint.mjsalone fails withNo Chrome found. Set CHROME_PATH to a Chrome or Chromium binary.Confirmed with a repro that extracts each file's
chromePath()and runs it against a fake home directory containing only a Playwright Chromium cache (no system Chrome/Edge):After the fix,
print.mjsmatches the other three.Tests
scripts/chrome-path-parity.test.mjsasserts everychromePath()in the four files contains the Windows Playwright lookup. It fails onmain(onlyprint.mjsis missing it) and passes with this change:I also ran the full suite (
node --test scripts/*.test.mjs) before and after on a Linux machine: the same 6 pre-existing failures (thereact-*tests, which need thetest_depsnpm install from CI, and onedrivetest that needs a real Chrome binary) appear on a clean checkout and with this change; nothing new fails.Checks
git status --shortshows only the changes I meant. (No example or kit change.)kit/change.node scripts/lines.mjs. Not applicable: no figure change.UnreleasedinCHANGELOG.md.Screenshots
No visual change.