femtopixel / docker-google-lighthouse

Google Lighthouse - Docker Image
https://brands.jaymoulin.me/femtopixel/docker-google-lighthouse
MIT License
69 stars 23 forks source link

Runtime error encountered, likely node update needed #13

Closed tomcudd closed 4 years ago

tomcudd commented 4 years ago

Output of docker inspect lighthouse --format='{{index .Config.Labels.version}}':

v5.6.0

Description

Attempting to test a site with the current docker image results in error output. I will put in a suggested pull request.

Command line I used to start the container

docker run --rm --name lighthouse -it -v /root/docker-tests/lighthouse:/home/chrome/reports --cap-add=SYS_ADMIN femtopixel/google-lighthouse https://URLNAME

Steps to reproduce the issue:

  1. Run the latest command as described above
  2. See error output

Describe the results you received:

Following stdout error:

Runtime error encountered: this._select is not a function
TypeError: this._select is not a function
    at PluralRules.select (/usr/lib/node_modules/lighthouse/node_modules/intl-pluralrules/factory.js:143:21)
    at PluralFormat.getOption (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/compiler.js:161:38)
    at formatPatterns (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/core.js:69:43)
    at IntlMessageFormat.format (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/core.js:139:24)
    at _formatIcuMessage (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:293:37)
    at _resolveIcuMessageInstanceId (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:424:29)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:452:55)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:465:9)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:465:9)
    at Object.replaceIcuMessageInstanceIds (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:472:3)

Describe the results you expected:

I expected the command to complete and the html output of the report to be available.

Additional information you deem important (e.g. issue happens only occasionally):

It would appear that this might be related to an issue with the latest lighthouse version and node 11: https://github.com/GoogleChrome/lighthouse/issues/9860

I'll put in a pull request to see if this will resolve.

Provide some logs (docker logs lighthouse)

Runtime error encountered: this._select is not a function
TypeError: this._select is not a function
    at PluralRules.select (/usr/lib/node_modules/lighthouse/node_modules/intl-pluralrules/factory.js:143:21)
    at PluralFormat.getOption (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/compiler.js:161:38)
    at formatPatterns (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/core.js:69:43)
    at IntlMessageFormat.format (/usr/lib/node_modules/lighthouse/node_modules/intl-messageformat/dist/core.js:139:24)
    at _formatIcuMessage (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:293:37)
    at _resolveIcuMessageInstanceId (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:424:29)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:452:55)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:465:9)
    at replaceInObject (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:465:9)
    at Object.replaceIcuMessageInstanceIds (/usr/lib/node_modules/lighthouse/lighthouse-core/lib/i18n/i18n.js:472:3)