Lighthouse: Non-passive listeners that are removed still warn

Created on 30 Sep 2019  Â·  4Comments  Â·  Source: GoogleChrome/lighthouse

Provide the steps to reproduce

Run LH on https://www.mustakbil.com, and under Best Practices section it thows below error:

Does not use passive listeners to improve scrolling performance

It's an Angular App and I opened an issue (https://github.com/angular/angular/issues/32733) there and with investigation it seems that probably LH is wrongly reporting this error.

What is the current behavior?

LH is reporting Does not use passive listeners to improve scrolling performance despite there aren't any non-passive listeners.

What is the expected behavior?

It shouldn't throw this error, and if there is an error it should provide more details.

Environment Information

  • Affected Channels:
  • Lighthouse version: 5.1
  • Node.js version: v10.16.3
  • Operating System: Windows 10

Related issues

needs-discussion needs-priority

All 4 comments

Thanks for filing @naveedahmed1 and apologies for the runaround but this is in fact a violation and is WAI. I've responded to the Angular folks with additional detail.

(see https://github.com/angular/angular/issues/32733#issuecomment-536388035)

Thank you so much @patrickhulce really appreciate quick response :)

Resolution from https://github.com/angular/angular/issues/32733#issuecomment-536712444 was that while it's installed and that's bad. The listener appears to be removed. Our strategy of reporting only installed non-passive listeners is sub-optimal in that listeners that are transient still receive the failure.

We would have to migrate to whatever protocol methods the DevTools panel uses for event listeners instead of our violations if this were to be fixed, but that's a substantial effort.

Ideally we'd incorporate data about the listeners in the final state of the page, but we're unable to pursue that.

Closing for now.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

devrsi0n picture devrsi0n  Â·  3Comments

dkajtoch picture dkajtoch  Â·  3Comments

muuvmuuv picture muuvmuuv  Â·  3Comments

sanprieto picture sanprieto  Â·  3Comments

timj2 picture timj2  Â·  3Comments