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

Upgrade lighthouse dependencies and fix performance tests #7019

Merged
merged 20 commits into from
Sep 30, 2021

Conversation

christian-bromann
Copy link
Member

Proposed changes

supersedes #6961

This patch bumps Lighthouse and Puppeteer versions and makes sure performance tests work again.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

Checklist

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • I have added proper type definitions for new commands (if appropriate)

Further comments

Thanks @esaari for your help on this!

Reviewers: @webdriverio/project-committers

@christian-bromann
Copy link
Member Author

This is blocked on a weird behavior in Chrome where it doesn't install a web manifest if the devtools app is not being opened. This requires some additional investigation.

@esaari
Copy link
Contributor

esaari commented Jun 17, 2021

Will address #6932 and #6604 once complete.

@christian-bromann
Copy link
Member Author

We should also add firstInputDelay metric.

@christian-bromann
Copy link
Member Author

We should also add firstInputDelay metric.

Already added via maxPotentialFID

@christian-bromann
Copy link
Member Author

The problem with moving this forward is that there is a weird behavior with Chrome DevTools. Given you have the following test script:

describe('webdriver.io page', () => {
    it('should have the right title', () => {
        browser.url('https://webdriver.io')
        const result = browser.checkPWA()
        console.log(result)
    })
})

Lighthouse would detect the ServiceWorker to be registered and starting:

[0-0] RECEIVED {
[0-0]   versions: [
[0-0]     {
[0-0]       versionId: '0',
[0-0]       registrationId: '0',
[0-0]       scriptURL: 'https://webdriver.io/sw.js?params=%7B%22offlineMode%22%3Afalse%2C%22debug%22%3Afalse%7D',
[0-0]       runningStatus: 'starting',
[0-0]       status: 'new',
[0-0]       scriptLastModified: 0,
[0-0]       scriptResponseTime: 0,
[0-0]       controlledClients: [],
[0-0]       targetId: '95432B44D4DB8620E7B9509D94E698E7'
[0-0]     }
[0-0]   ]
[0-0] }

But then no other events happen until you open the DevTools app. I wonder which CDP commands trigger the commands to come in. This needs some further investigation.

@esaari
Copy link
Contributor

esaari commented Aug 3, 2021

A couple thoughts -

  1. I had not noticed that Lighthouse 8.0 will be shipping with Chrome version 93: https://github.com/GoogleChrome/lighthouse/blob/v8.1.0/changelog.md#800-2021-06-02
    The latest stable version is still 92.x. It may be worth trying this on a dev build of Chrome 93 or waiting until it hits the stable channel to see if the changes now spin up the worker.
  2. Lighthouse is now bumped to 8.1: https://github.com/GoogleChrome/lighthouse/blob/v8.1.0/changelog.md#800-2021-06-02 I am unsure how to bump that here without opening a superseding PR.

@maleeazeem
Copy link

Any ETA for this issue?

@tobeliketree
Copy link

I am also curious of an update on this. I believe the bug I reported is also related to this. #7233.

It's rendered dev-tools completely inoperable for us and we use dev tools in a number of ways from throttle to performance testing. When this issue shows and it's all the time now pages just don't render and ever test fails.

@christian-bromann
Copy link
Member Author

We still have issues getting PWA testing to work due to a weird Chrome Devtools. Everyone can step in and investigate. I know that a lot of issues are connected to this.

@esaari
Copy link
Contributor

esaari commented Sep 24, 2021

I'm having trouble getting a solid reproduction of the issue. If anybody would like to assist, a good first step would be to file a bug report within the Lighthouse package: https://github.com/GoogleChrome/lighthouse/issues and see what they say, and possibly cross-reference this issue. @tobeliketree perhaps you could help us with this?

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Sep 27, 2021

CLA Signed

The committers are authorized under a signed CLA.

@christian-bromann
Copy link
Member Author

Raised an issue in the Lighthouse project: GoogleChrome/lighthouse#13127

@christian-bromann
Copy link
Member Author

@esaari mind resigning the CLA (we got a new one that is very similar to the old CLA from the JS Foundation).

@christian-bromann
Copy link
Member Author

@esaari good news, I was able to fix the problem. Only need to adjust unit tests and clean up some things.

@christian-bromann
Copy link
Member Author

🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: Bug Fix 🐛 PRs that contain bug fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants