-
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
When running Lighthouse from Webpagetest there is no support of touch device #5659
Comments
Another observation, this time related to the Lighthouse extension. Steps to reproduce:
This seems wrong to me. The lighthouse extension report says, that it was using "Device: Emulated Nexus 5X". This should always have touch support then. |
Thanks for reporting @Svenmay you're right this seems to have regressed. LH certainly used to emulate touch devices but at some point the code was removed because DevTools was supposed to handle it through the protocol. It seems that's not happening though so we might need to bring our support back. |
So it seems like #4914 switched to start using setEmitTouchEventsForMouse instead of setTouchEmulationEnabled, setTouchEmulationEnabled seems to be what we actually want. We don't actually have any mouse input we just want the page to think that touch input is available. Moving back to setTouchEmulationEnabled seems to fix the problem. |
@Svenmay hugely appreciate you reporting this bug! our bad. we'll ship this fix in 3.0.3 in a week or two, and you'll see it in WPT then. |
Provide the steps to reproduce
Test-URL: https://tolwin.spdns.org/test/test_touch.html
URL of webpagetest run: https://www.webpagetest.org/result/180712_GP_88a851ffa3165b62cc505c566d91d4c0/
URL of Lighthouse report from that WPT run: https://www.webpagetest.org/lighthouse.php?test=180712_GP_88a851ffa3165b62cc505c566d91d4c0&run=1
What is the current behavior?
Running a standard test on webpagetest simulates a mobile device with touch support. That is the correct/expected behavior.
But the Lighthouse report, also run from webpagetest seems to be running as a device WITHOUT touch support.
You can see in the screenshots from WPT and from Lighthouse report that they are different. The testpage itself is not doing much useful, other than trying to detect a device with touch support.
NOTE: It is not about the question, if my touch detection is correct or not. It is just about the question why WPT is different from Lighthouse. Both tools should be either "touch detected" or "no touch detected".
Personally I do think Lighthouse is wrong here, not WPT.
What is the expected behavior?
Lighthouse should also run as a device with touch support.
Environment Information
Related issues
The text was updated successfully, but these errors were encountered: