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 Chrome plugin emulates desktop in mobile tests #11873

Closed
SerialTickler opened this issue Dec 22, 2020 · 3 comments · Fixed by #11876
Closed

Lighthouse Chrome plugin emulates desktop in mobile tests #11873

SerialTickler opened this issue Dec 22, 2020 · 3 comments · Fixed by #11876

Comments

@SerialTickler
Copy link

This started on Dec, 20. Even though I select "mobile" in devices, it says "Emulated Desktop" in the report. The user agent is:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) HeadlessChrome/85.0.4183.140 Safari/537.36

If I test the same page in Dev tools it the Lighthouse works as intended and emulates Moto G4 with the following UA:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.88 Safari/537.36

@connorjclark
Copy link
Collaborator

connorjclark commented Dec 22, 2020

You're running from the Chrome Extension, right?

I see PSI is currently on 85 (heh, I'll see about us updating that). Can you provide a URL where you see this issue?

@connorjclark
Copy link
Collaborator

Nevermind, I easily reproduced this with the extension and example.com. Thanks for alerting us!

@connorjclark
Copy link
Collaborator

example.com run

The config is right:

image

I suppose this is an artifact of the new v7 renderer not being able to map the old emulatedFormFactor (it is now formFactor) to the correct UI string.

const deviceEmulation = settings.formFactor === 'mobile'

We should add some back-compat here.

@SerialTickler This means that the bug is simply the report showing the wrong text here. The test is still being run as a mobile report.

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

Successfully merging a pull request may close this issue.

3 participants