Open arishoham opened 1 year ago
Experiencing the same issue here with a GitHub-hosted runner. Minimum reproducible steps:
name: Lighthouse
on: [pull_request]
jobs:
lighthouse:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Audit performance with Lighthouse
id: lighthouse_audit
uses: treosh/lighthouse-ci-action@v10
with:
urls: |
https://example.com
Error log:
Running Lighthouse 1 time(s) on https://example.com
Run #1...failed!
Error: Lighthouse failed with exit code 1
at ChildProcess.<anonymous> (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/@lhci/cli/src/collect/node-runner.js:120:21)
at ChildProcess.emit (node:events:513:28)
at Process.ChildProcess._handle.onexit (node:internal/child_process:2[9](https://github.com/planetscale/www/actions/runs/5957221283/job/16159507373?pr=387#step:3:9)3:12)
Runtime error encountered: The CHROME_PATH environment variable must be set to a Chrome/Chromium executable no older than Chrome stable.
Error
at new LauncherError (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/utils.js:26:22)
at new ChromePathNotSetError (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/utils.js:33:[9](https://github.com/planetscale/www/actions/runs/5957221283/job/16159507373?pr=387#step:3:10))
at Object.linux (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/chrome-finder.js:1[28](https://github.com/planetscale/www/actions/runs/5957221283/job/16159507373?pr=387#step:3:30):15)
at Launcher.getFirstInstallation (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/chrome-launcher.js:126:51)
at Launcher.launch (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/chrome-launcher.js:187:43)
at Module.launch (/opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/node_modules/chrome-launcher/dist/chrome-launcher.js:35:20)
at getDebuggableChrome (file:///opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/cli/run.js:86:25)
at runLighthouse (file:///opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/cli/run.js:237:[30](https://github.com/planetscale/www/actions/runs/5957221283/job/16159507373?pr=387#step:3:32))
at begin (file:///opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/cli/bin.js:1[35](https://github.com/planetscale/www/actions/runs/5957221283/job/16159507373?pr=387#step:3:37):10)
at async file:///opt/actions-runner/_work/_actions/treosh/lighthouse-ci-action/v10/node_modules/lighthouse/cli/index.js:10:1
Error: LHCI 'collect' has encountered a problem.
Config from the log:
2023-08-23T22:44:13.7977845Z ##[group]Action config
2023-08-23T22:44:13.8003333Z Input args: {
2023-08-23T22:44:13.8003778Z "urls": [
2023-08-23T22:44:13.8004628Z "https://example.com"
2023-08-23T22:44:13.8007239Z ],
2023-08-23T22:44:13.8007582Z "runs": 1,
2023-08-23T22:44:13.8007964Z "staticDistDir": null,
2023-08-23T22:44:13.8008366Z "budgetPath": "",
2023-08-23T22:44:13.8011750Z "configPath": null,
2023-08-23T22:44:13.8012321Z "serverBaseUrl": "",
2023-08-23T22:44:13.8012864Z "serverToken": "",
2023-08-23T22:44:13.8013325Z "temporaryPublicStorage": false,
2023-08-23T22:44:13.8013842Z "uploadArtifacts": false,
2023-08-23T22:44:13.8014332Z "basicAuthUsername": "lighthouse",
2023-08-23T22:44:13.8014803Z "basicAuthPassword": "",
2023-08-23T22:44:13.8015562Z "artifactName": "lighthouse-results"
Facing the same issue with the latest version, v11, when testing locally using gh act
. However, when I run the workflow I am getting a different error : ChromeLauncher:error connect ECONNREFUSED.
Using a self-hosted github action:
I get the following error from chrome-launcher: