Skip to content
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 viewport is still in mobile view after running test using desktop configuration #85

Open
eysuu opened this issue Apr 24, 2021 · 5 comments

Comments

@eysuu
Copy link

eysuu commented Apr 24, 2021

I am having trouble running sitespeed 17.1.1-plus1 using lighthouse plugin. My configuration settings seems working fine but based on lighthouse report, the screenshot is in mobile view. Here's my command running tests:

docker run --name sitespeed --volumes-from=jenkins --network=host --privileged=true --shm-size=1g --rm -v \"/tmp/sitespeed.io/\":/sitespeed.io \sitespeedio/sitespeed.io:17.1.1-plus1 --plugins.remove browsertime \--lighthouse.settings.screenEmulation.mobile false --lighthouse.settings.formFactor desktop --lighthouse.settings.throttling.rttMs 40 --lighthouse.settings.throttling.throughputKbps 10240 --lighthouse.settings.throttling.cpuSlowdownMultiplier 1 \--graphite.host localhost --graphite.port 2003 --graphite.httpPort 8080 --graphite.namespace TestFolderD.default

See screenshot attached:
Viewport is in mobile
Snag_4d8eddb
But the summary setting is in desktop
Snag_4d98e03

I also tried using the --lighthouse.setting.preset desktop but its not working as well.

Please help me guys, it gives discrepancy on lighthouse opportunities and diagnostics as well. Thanks a lot.

@soulgalore
Copy link
Member

Hi @eysuu hmm I get the same. I can check the Lighthouse documentation to see if I understand how to do it.

@eysuu
Copy link
Author

eysuu commented Apr 27, 2021

@soulgalore I really appreciate the response sir. Thank you. I've been resolving this for 2 days and I really don't know what's wrong that's why I ended up questioning here 😅

@soulgalore
Copy link
Member

@eysuu I tried too but couldn't get it to work, I think something is missing in the Lighthouse documentation.

@eysuu
Copy link
Author

eysuu commented May 6, 2021

It looks like I'm literally running out of options. I already get rid of mobile screenshot but the screen size does not seems to be correct compared on manual audit. Even if I ran this --lighthouse.setting.screenEmulation.disabled --lighthouse.setting.formFactor desktop it will just show the viewport of desktop, but the findings for LCP and CLS are get via mobile viewport.

Thanks @soulgalore

@arquilca
Copy link

arquilca commented Jan 7, 2022

@eysuu I don't think setting --lighthouse.setting.screenEmulation.disabled is enough. You can see this document that mentions two different ways screenEmulation would be configured with objects. Maybe some of the other parameters like width/height/deviceScaleRatio are still using defaults.
https://github.com/GoogleChrome/lighthouse/blob/master/docs/emulation.md

You can see the default values used in Chrome Lighthouse here:
https://github.com/GoogleChrome/lighthouse/blob/master/lighthouse-core/config/constants.js

Also, I've noticed the last few comments you stated lighthouse.setting instead of lighthouse.settings (with an s). So that's also worth double-checking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants