GoogleChrome / lighthouse

Automated auditing, performance metrics, and best practices for the web.
https://developer.chrome.com/docs/lighthouse/overview/
Apache License 2.0
28k stars 9.31k forks source link

Getting a ? on mobile PageSpeed score #11385

Open no-liver opened 3 years ago

no-liver commented 3 years ago

Hi,

Our site is getting a ? mobile PageSpeed score. This issue arised a few days ago. Currently unable to pinpoint the issue from the site side, is there any possibility to assist?

Please view site: https://tinyurl.com/yyfx7kgl

Best

patrickhulce commented 3 years ago

Thanks for filing @rulloliver! I can reproduce this in PSI but no other environment. We'll have to look into it.

connorjclark commented 3 years ago

image

weird issue with the css protocol. attached JSON for the LHR/artifacts from LR for later analysis.

lrdata.txt

paulirish commented 3 years ago

perhaps related to https://github.com/GoogleChrome/lighthouse/issues/10876

connorjclark commented 3 years ago

perhaps related to #10876

I don't think so. I think the root cause is whatever caused SPEEDINDEX_OF_ZERO, aka no screenshots, for some reason ... Nothing painted = whole page was too busy = no CSS parsed yet ???

https://sentry.io/organizations/google-lighthouse/issues/1454681293/?project=174697&query=is%3Aunresolved+No+style+sheet&statsPeriod=14d

image

many (but not all) have a NO_TTI or NO_LCP error too..

But this suggests it's not a PSI issue.

I can't get this to happen anymore with the provided URL. @rulloliver have you since changed the page in a significant way? Perhaps made it use less JS?

brendankenny commented 3 years ago

perhaps related to #10876

I don't think so. I think the root cause is whatever caused SPEEDINDEX_OF_ZERO

I believe I suggested that comment in the last bug bash. It was just based off the CSSUsage/"no style sheet with given id found" error in the screenshot.

Nothing painted = whole page was too busy = no CSS parsed yet ???

We only add a style sheet to be queried when the protocol indicates one has been added (CSS.styleSheetAdded), not on network records. I would assume it would only generate the event/id after it has something that can be queried?

Lots of interesting weird things about these artifacts, though (here's a live version of the report from them)

I'm not sure there's much for us to do here without a test case, though. It may just be there were enough errors in the site/PSI combo to not paint anything screenshottable but it was still enough to trigger the FCP/LCP thresholds.

no-liver commented 3 years ago

Issue resolved currently by itself but lasted for about a week. Haven't been able to replicate it since. Thank you for the feedback and help

connorjclark commented 2 years ago

One possible bug for us here: it's questionable whether SPEEDINDEX_OF_ZERO should use the "Chrome didn't collect any screenshots" string, because it did collect screenshots.

https://github.com/GoogleChrome/lighthouse/blob/d9e84e1d71e04ddae4f53d8e013683d6ca4c17ce/lighthouse-core/computed/speedline.js#L45

should we just check for undefined here, and allow for 0 to continue without error or throw a unique error for it?