-
Notifications
You must be signed in to change notification settings - Fork 9.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Lighthouse performance result significantly different when run on CLI vs Dev Tools #14810
Comments
Thanks for the detailed report! I can respond more fully after the weekend, but in the meantime it'd be helpful if you could repeat your analysis using 10.0. you can grab the latest from npm for the CLI, and use Chrome Canary to use 10.0 in DevTools. It's a huge amount of changes between the two versions, so good to rule out that we haven't already fixed whatever this particular problem is first. |
My first observation is that you've used legacy navigation for the CLI (that is the default for 9.x, in 10 it is not), but used the new navigation runner in CDT. It shouldn't matter, but it could be exposing an issue between the two. The chrome that the CLI opens.. can you open a new tab in it for chrome://version/ and share the version you see? Could be #14288 again somehow (are you on Mac?) |
Thanks for the suggestions. Unfortunately, I’ll be unexpectedly without my laptop until Friday. :/ Sorry for the inconvenience! I will try your suggestions on a different laptop tomorrow though.On Feb 18, 2023, at 2:18 AM, Connor Clark ***@***.***> wrote:
My first observation is that you've used legacy navigation for the CLI (that is the default for 9.x, in 10 it is not), but used the new navigation runner in CDT. It shouldn't matter, but it could be exposing an issue between the two.
The chrome that the CLI opens.. can you open a new tab in it for chrome://about and share the version you see? Could be #14288 ...
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Yes
running CLI v10 returns the following:
So, looks like you're guess was correct, this is the same issue as #14288 I'll try to install the correct version of node and reply here with results. |
I upgraded node to v15.14.0 and set Update: I also tried: Any idea what I'm missing here? |
I have the same performance issue between devTools and CLI/node versions. On all platforms, on v10.0.1 and on v9.6.8 with --legacy-navigation false. |
Ok, I fixed the issue and was able to get the arm64 versions of node and lighthouse working and the results are much more consistent! All had a performance score of around 91 except for a couple from devtools which were in the high 80s...still pretty close and can probably be attributed to variances on nytimes.com, like ads. Reports (4 from each): Just in case anyone runs into similar issue, here's how I got it running: Use the latest version of node (as you can see, I'm using nvm to switch versions) Use Chrome Canary $ export CHROME_PATH=~/Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary Open via command line Install the latest lighthouse globally In my case, for some reason, it still tries to use the version of lighthouse in the previous node version: Run lighthouse cli Then, to run devtools, I opened chrome via cmd line like this: Lastly, open dev tools and run lighthouse |
Hey, thanks for sharing, I'm hoping this will fix it for me as I'm encountering the same issues and am also on a Mac. I noticed a small typo and thought I'd let you know. $ nvm ls-remove v16 # find the latest Should be |
Actually after digging deeper I think what fixed this issue for me is that, prompted by noticing you were adding I added desktop throttling to where I was invoking lighthouse like this:
|
hey guys am facing the same issue as am getting difference in lighthouse report while running by dev tool and cmd can anyone point out the solution |
I have not solved this problem, but I have found a better solution. I use the pagespeed insights api and all such runs are done by the google robot instead of me, it's even better than the original version because based on the same metrics, google ranks pages in search and I get data from google itself |
Hi!
I'm having trouble getting consistent results when I run Lighthouse on CLI vs Dev Tools on the same site.
I've run most tests on against our dev server, but I ran against nytimes.com so we can test against a public facing site and got the same results.
The performance score for CI is always significantly lower.
Settings
Here's the command I'm running:
lighthouse "https://www.nytimes.com/" --output json --preset desktop
The settings I'm using in devtools are:
Browser versions:
chrome-debug: Version 110.0.5481.100 (Official Build) (x86_64 translated)
The one I'm running devtools on: Version 110.0.5481.100 (Official Build) (arm64)
I've disabled all extensions in my browser.
When the test runs the browser window is visible and I don't touch anything until the test finishes.
Lighthouse version for both browsers: 9.6.8
Throttling seems to be exactly the same (from looking at the "Custom Throttling" link in the footer of the results
Results
CLI
devtools
Note the huge difference in blocking time. I notice that the page is slower.
Full results for 2 passes here:
lighthouse-reports.zip
I've also played around with various settings on CI and the results are always similar to CLI. This doesn't seem to be an issue with variance because the results for devtools is consistent as are the result for CI and CLI. If it was variance, I'd expect them all to fluctuate more randomly.
Here are some of the settings I tried in CI:
Lastly, I realize that nytimes.com might not be the best site to test against because it's content can change and it runs ads, etc, but I tested it at different times and got the same result. Also, I've ran the comparison 30 times or more against our dev site and the content there doesn't change at all. It must be something with my local machine, but my goal is to get CI set up on Jenkins and I need to have this working first.
Please let me know if you need any more information or if there's anything else I can try here!
Related Issues:
The text was updated successfully, but these errors were encountered: