treosh / lighthouse-ci-action

Audit URLs using Lighthouse and test performance with Lighthouse CI.
MIT License
1.15k stars 81 forks source link

Puppeteer error #99

Closed misterabd closed 2 years ago

misterabd commented 2 years ago

Installing any version of Puppeteer leads to this error in a GitHub Action: TypeError: script is not a function at PuppeteerManager.invokePuppeteerScriptForUrl (/home/runner/work/_actions/treosh/lighthouse-ci-action/v8/node_modules/@lhci/cli/src/collect/puppeteer-manager.js:108:11) at processTicksAndRejections (internal/process/task_queues.js:93:5) at async Object.runCommand (/home/runner/work/_actions/treosh/lighthouse-ci-action/v8/node_modules/@lhci/cli/src/collect/collect.js:244:7) Error: LHCI 'collect' has encountered a problem. at async run (/home/runner/work/_actions/treosh/lighthouse-ci-action/v8/node_modules/@lhci/cli/src/cli.js:103:7) image

misterabd commented 2 years ago

The reason for this was because of multiple function exports from our puppeteerScript which converted the script method to an object instead. Apologies, this is not a bug and can be closed.