Skip to content

OOM in ImageElements gatherer #11289

@paulirish

Description

@paulirish

We were getting OOMs in LR and I managed to confidently bisect down to the commit where #11188 was merged. (its core(image-elements): collect CSS sizing, ShadowRoot, & position)

node lighthouse-cli http://cosmetiqon.gr/ --only-audits=unsized-images -G

Here's one URL where this can sometimes OOM, though I definitely can't get an OOM locally. I'm not entirely sure which context is getting the OOM.. the page or Lighthouse.

I do know that if I comment out these lines...

if (!element.isInShadowDOM) {
await this.fetchSourceRules(driver, element.devtoolsNodePath, element);
}

…the imageGatherer takes 2s instead of 28s.

I attempted to do some memory debugging but didn't get too far. Still requires a bit of investigation


Similar efforts: #7274 #9818

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions