playwright-community / playwright-go

Playwright for Go a browser automation library to control Chromium, Firefox and WebKit with a single API.
https://playwright-community.github.io/playwright-go/
MIT License
2.11k stars 156 forks source link

Install failed with error and after that next install giving error and exiting #372

Closed tejaskumark closed 11 months ago

tejaskumark commented 1 year ago

Hi Experts,

I observed that while first playwright.Install call failed with below error, and after that subsequent Install calls were always successful but was not able to start playwright successfully

Error logs while first installation -

Downloading Chromium 115.0.5790.24 (playwright build v1067) from https://playwright-verizon.azureedge.net/builds/chromium/1067/chromium-mac-arm64.zip
Failed to install browsers
Error: Failed to download Chromium 115.0.5790.24 (playwright build v1067), caused by
Error: Download failure, code=1
    at ChildProcess.<anonymous> (/Users/testing/Library/Caches/ms-playwright-go/1.35.1/package/lib/server/registry/browserFetcher.js:95:16)
    at ChildProcess.emit (node:events:513:28)
    at ChildProcess._handle.onexit (node:internal/child_process:291:12)

could not send message to server: Executable doesn't exist at /Users/testing/Library/Caches/ms-playwright/chromium-1067/chrome-mac/Chromium.app/Contents/MacOS/Chromium
╔═════════════════════════════════════════════════════════════════════════╗
║ Looks like Playwright Test or Playwright was just installed or updated. ║
║ Please run the following command to download new browsers:              ║
║                                                                         ║
║     npx playwright install                                              ║
║                                                                         ║
║ <3 Playwright Team                                                      ║
╚═════════════════════════════════════════════════════════════════════════╝.```
canstand commented 1 year ago

The temporary solution is to manually delete folders under /Users/testing/Library/Caches/ms-playwright and/Users/testing/Library/Caches/ms-playwright-go.

Consider providing an uninstall method.

canstand commented 11 months ago

v0.3800.0 provides PlaywrightDriver.Uninstall