Sitespeed.io: Add output support for Google Lighthouse

Created on 26 Jul 2017  路  6Comments  路  Source: sitespeedio/sitespeed.io

SiteSpeed.io is already fantastic, and improving all the time. Out of the box support for Web Page Test and Google Page Speed Insights has been invaluable to compare and contrast different scorecards. Could support for output of Google Lighthouse CLI results be added to SiteSpeed.io reports?

feature request help wanted plugin

Most helpful comment

@siteriaitaliana has started on a plugin at https://github.com/siteriaitaliana/plugin-lighthouse help him out there :)

All 6 comments

@tobli suggested using Browsertime to produce the trace logs, then running Lighthouse analysis on the results. Would it be possible to run tests in parallel this way or only queued?

Yes, I think that's the best way to start, since much of the work is already in place. Given the right options, the Browsertime plugin already posts trace messages for other plugins to digest. There might be some parts of Lighthouse we can't fully utilise, but I don't know enough to be sure.

For more reliable results, we only want to be running one browser instance at a time. That's enforced using the concurrency: 1 property on the Browsertime plugin. Decoupling the processing from that restriction will help keep things simpler. So if you'd, in theory, produce trace messages some other way (e.g. from files on disk) many traces could be analysed in parallel. That said it'd still be single threaded (that's how node works) but I'd be surprised if the processing becomes a bottleneck. The need for concurrency that's guiding the sitespeed.io architecture has primarily been for remote services and external processes (e.g. not blocking WPT calls when waiting for Chrome to launch locally).

Cool, I didn't realize that regarding BT output traces (or haven't read the docs and code yet). As for what could or could not be compatible with Lighthouse stdin I don't really know yet either but I could do some investigation.

Re: concurrency it's probably OT for this thread but one example use case I was thinking of would involve running worker nodes to offload a queue or manifest of URLs. If I fed a list of 40 URLs to 4 workers, it would be could completed by those workers in parallel and 4x faster than serially.

I've tried the BT tracing approach and works with very few LH audits, main issue is:
https://github.com/sitespeedio/sitespeed.io/issues/1569
Probably add proper LH support in a plugin would be better to get the full advantages of it. If I make any progress with this I will create a PR.

@siteriaitaliana has started on a plugin at https://github.com/siteriaitaliana/plugin-lighthouse help him out there :)

@soulgalore Peter, is there a chance to output metric values into log.
We use sitespeed in gitlab CI and we want VC99, Full load, Lighthouse TTI (BTW thanks for 9.0plus!).
Whether it is possible?
Ideally would be exporting (*all) metrics available in HTML report to JSON file. Current performance.json is not quite detailed. ;)
sitespeed

Was this page helpful?
0 / 5 - 0 ratings