GoogleChrome/lighthouse

Launcher ECONNREFUSED flake

Closed this issue · 4 comments

This is a bit of carryover from #2544. It was failing 100% of the time and now its more like 5%.

Example build: https://travis-ci.org/GoogleChrome/lighthouse/jobs/245116083
image

Things to note:

  • Last night, this error thrown for EVERY chrome launch, like all smokehouse runs. After ward's fix it appears to only affect the Launcher tests
  • It's intermittent. On this build, only 1 of the 3 travis jobs had a problem.

There might be still a bug on the travis/chrome side, but seems like we have room to handle this from within launcher. (port sniffing & retry logic?)
At the very least, more usable error messages and extra logging.

wdyt @samccone

edit: he said..

image

not sure it's relevant but in smokehouse we have

// Lighthouse sometimes times out waiting to for a connection to Chrome in CI.
  // Watch for this error and retry relaunching Chrome and running Lighthouse up
  // to RETRIES times. See https://github.com/GoogleChrome/lighthouse/issues/833

just a sidenote on smoke tests we add a delay of 0.5s which maybe gives travis some extra room to breath between runs?

pwmetrics has had a workaround for this issue for a long time now: https://github.com/paulirish/pwmetrics/blob/2eb1266f0997050dd56435a2dac5b34dd26e1b82/lib/index.ts#L129-L154 (basically just adding retry logic. )

I've put up a proposed fix in #2616

hey now, smokehouse has had a workaround for even longer :P