question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Inaccurate and inconsistent results in Google App Engine

See original GitHub issue

I am receiving inaccurate, inconsistent results when running Lighthouse performance audits while deployed from Google App Engine. Not sure if it is Lighthouse or Puppeteer which isn’t playing nice in the Google App Engine environment. Below is the function I am calling.

const lighthouse = require('lighthouse')
const puppeteer = require('puppeteer')
async function launchPuppeteerRunLighthouse(url) {
  try {
    const browser = await puppeteer.launch({
      args: [
        '--no-sandbox',
        '--incognito',
        '--disable-gpu',
        '--disable-dev-shm-usage',
        '--disable-setuid-sandbox',
        '--no-first-run',
        '--no-zygote',
      ],
    })
    const port = browser._connection._url.slice(15, 20)
    const { lhr, report } = await lighthouse(url, {
      port,
      output: 'html',
      onlyCategories: ['performance'],
      logLevel: 'debug',
    })
    browser.close();
    return { report, lhr }
  } catch (error) {
    console.log(error)
  }
}

Here is my app.yaml

runtime: nodejs8
instance_class: F4_1G

When I run a performance audit for https://www.google.com programmatically on my local development server I am observing results consistent with running the performance audit using Lighthouse located in Chrome Dev Tools. When running the performance audit for https://www.google.com programmatically on Google App Engine I am receiving much lower performance scores.
I have tested in both environments with dozens of audits. I am attaching screenshots for what I would consider an average result of a performance audit of https://www.google.com in both environments.

Screen Shot 2019-04-03 at 7 40 48 PM Screen Shot 2019-04-03 at 7 40 20 PM

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
tostaylocommented, Apr 9, 2019

After testing on a Google Compute Engine n1-standard-2 instance, I am observing Lighthouse performance audits consistent with what I observe while testing in my local Chrome. Thank you @patrickhulce and @benschwarz for the recommendation.

2reactions
denar90commented, Apr 5, 2019

@patrickhulce @tostaylo we also faced the same kind of problems at @treosh. After moving to stable dedicated instance we increased results stability as well. Check out the public report for google.com https://treo.sh/demo/4/pages/5?interval=1year btw, @alekseykulikov is champion in that question 🥇

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why is the "last-modified" incorrect on Google Cloud Platform ...
This seems to be a cache caused issue. To ensure that the new index.html is deployed, you would need to run “gcloud beta...
Read more >
urlfetch.fetch reporting inconsistent results? - Google Groups
to Google App Engine. urlfetch.fetch is reporting inconsistent results when querying the facebook graph api. If I curl the same URL from my...
Read more >
Configuration analysis states | Connectivity Tests | Google Cloud
A Connectivity Test configuration analysis goes through a series of test states as it checks the configuration of each Google Cloud resource in...
Read more >
When indexing goes wrong: how Google Search recovered ...
As a consequence of the Search index having the issues we described above, Search Console started to also show inconsistencies. This is because...
Read more >
Fix list for IBM WebSphere Application Server V8.5
IBM WebSphere Application Server provides periodic fixes for the base and Network Deployment editions of release V8.5. The following is a complete listing ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found