webcontainer-core icon indicating copy to clipboard operation
webcontainer-core copied to clipboard

A few webcontainer examples that crash Chrome (aw snap)

Open cristianbogdan opened this issue 9 months ago • 2 comments

Describe the bug

I filed a few Chromium issues based on some crashes with stackblitz webcontainers. But I guess they are useful for you guys as well. Chrome inttel on a wide range of versions is affected

https://issues.chromium.org/issues/404281206

The crashes occur during npm install mostly when package-lock.json is removed from the project (so npm install probably requires more Chrome window resources) https://stackblitz.com/edit/tv1ndoh4-sntf5lbo

This version does not crash but it completely freezes during the npm install. Pressing Ctrl-C in the terminal and removing the vitest dependency allows for a succesful npm install. https://stackblitz.com/edit/tv1ndoh4-1mbvqpfk

Adding one more package in package.json gets us to the (so far) minimum project that crashes Chrome. It only crashes on Intel, not Arm. see https://issues.chromium.org/issues/404464582 https://stackblitz.com/edit/tv1ndoh4-ggxjkkzp

Link to the blitz that caused the error

https://stackblitz.com/edit/tv1ndoh4-ggxjkkzp

Steps to reproduce

Just load https://stackblitz.com/edit/tv1ndoh4-ggxjkkzp in a Mac Chrome on intel and wait for the npm install

Expected behavior

The browser window crashes during the npm install

Parity with Local

Screenshots

No response

Platform

  • OS: Mac OS 15.3.1 (24D70)
  • Browser: Chrome
  • Version: 134.0.6998.89 (Official Build) (x86_64)

Note that this issue occurs on a wide range of Macs (intel at least) and Chrome versions. Above is the latest.

Additional context

No response

cristianbogdan avatar Mar 18 '25 12:03 cristianbogdan

It's probably because Chrome runs out of memory that it crashes, no? Probably not something Chrome can fix?

SamVerschueren avatar Apr 11 '25 12:04 SamVerschueren

I don't think it's as simple as memory (it happens on a wide range of systems) but it's most probably a chrome bug

cristianbogdan avatar Apr 11 '25 17:04 cristianbogdan