Skip to content

fix(driver): consider PLAYWRIGHT_NODEJS_PATH from host env win32 #2462

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix(driver): consider PLAYWRIGHT_NODEJS_PATH from host env win32
  • Loading branch information
MikhailSeliakov committed Jun 11, 2024
commit 3b64a9dfd20bf57e942164783a10007c699958cd
5 changes: 4 additions & 1 deletion playwright/_impl/_driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,10 @@ def compute_driver_executable() -> Tuple[str, str]:
driver_path = Path(inspect.getfile(playwright)).parent / "driver"
cli_path = str(driver_path / "package" / "cli.js")
if sys.platform == "win32":
return (str(driver_path / "node.exe"), cli_path)
return (
os.getenv("PLAYWRIGHT_NODEJS_PATH", str(driver_path / "node.exe")),
cli_path,
)
return (os.getenv("PLAYWRIGHT_NODEJS_PATH", str(driver_path / "node")), cli_path)


Expand Down
Loading