-
Notifications
You must be signed in to change notification settings - Fork 9.1k
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
What is "Page crashed!" error? #1321
Comments
I cannot replicate this issue outside of Docker. |
There's an example Docker setup and tips and tricks when hitting issues like this in https://github.com/GoogleChrome/puppeteer/blob/master/docs/troubleshooting.md#running-puppeteer-in-docker. |
That answer did not explain what the error means. For anyone running into this issue on K8S, the issue is that You cannot override Docker shm configuration in K8S, however, there is this workaround https://stackoverflow.com/a/46434614/368691. |
This worked
Copied from |
I met this on Ubuntu 16.04 (no docker) |
I still had this
|
I solve my issue already. The problem was that there wasn't enough memory in my VM so it kept giving me this error. Kill all unnecessary processes and running puppeteer one more time did the trick. |
have the same issue, the question here is why is an unhandled promise rejection? How can I catch that error? because looks that normal try catch not working |
There might be a chance if your machine is running out of space. I've faced a similar issue, while my system was running out of space. Once I cleared the issue, it seems to be working fine. |
I got the same on Centos7.10 |
Getting this error on windows 10 (no docker). Nodev10.16.2
Get the following error,
|
@Ta-Run , did you manage to find a fix? Also trying to run this on Windows 10 and getting the same error. |
I faced the same problem for getting full html content on k8s. I tried await puppeteer.launch({ executablePath: '/usr/bin/chromium-browser', args: ['--disable-gpu', '--no-sandbox', '--lang=en-US', '--disable-setuid-sandbox', '--disable-dev-shm-usage'] }) |
Crushing on Windows even before any code with empty test file. It launches 2 Chrome "Aw, snap!" tabs. In console: Headless: true works fine though. |
@iethem @RobinNagpal @rotimi-best
I'm generating PDFs in docker. It's something like:
After creating around 20-25 PDFs it gives uncaughtException.
|
@saurabh147sharma Did you try increasing the memory of your docker container as mentioned in this comment below? Also run your nodejs script and simultaneously run this command
|
@rotimi-best |
- s/bukan-haien/corona/ Also, we've got an error: `UnhandledPromiseRejectionWarning: Error: Page crashed!` Resolved with this: - puppeteer/puppeteer#1321 (comment)
I was getting similar errors running my tests on CircleCI. After employing @RobinNagpal suggestion of using the I needed to run them sequentially to reduce the memory usage and after adding this flag to my jest test command: --runinband, things are working again. This is a rather specific case, but I hope it helps someone. |
On docker following the troubleshoot and using the local executable did solve the problem for me. Not using the local executable throws "Page Crashed!" await puppeteer.launch({
executablePath: 'google-chrome-unstable',
args: [
'--no-sandbox',
'--disable-setuid-sandbox',
'--disable-dev-shm-usage',
'--disable-gpu'],
}); |
I was seeing this in docker, the problem went away when i updated my e.g.
|
Following the doc (https://github.com/puppeteer/puppeteer/blob/master/docs/troubleshooting.md#running-puppeteer-in-docker) I thought we do not need to provide shm_size: '2gb' as this was handled by using: I feel like this this change has somehow been broken. |
Yes, it might be an issue with the latest version. We recently switched to 3.3.0 version and started getting this issue. We reverted back to 2.1.1 our older version and its working without any issue. |
Getting same issues with v3. All been good on v2 with same code. |
Previously we could run 10 chrome at once without any problem inside docker, now same code fails with running 2-3 at once, sometimes even just one crashes it. The problem is the issue is too old and we might need to create different issue. Also we need to mention we tried using puppeteer-extra, applied all different kind of hacks mentioned above, which previously worked without any issue. Now just taking a simple screenshot fails randomly. Puppeteer version 3.0 |
Added '--disable-dev-shm-usage', '--disable-gpu' into the puppeteer launch in order to fix a "(node:117132) UnhandledPromiseRejectionWarning: Error: Page crashed!" error I was constantly getting. Thank you to puppeteer/puppeteer#1321 (comment) for the fix aha! I have no knowledge of Javascript/Node but this seems to work for me.
Page crashed errors are caused because of certain website animation causing huge stress on the CPU, RAM and GPU. This can be easily fixed by adding some sort of delay before capturing the screenshot or completely avoiding taking a screenshot from the website that previously caused this error. All the above resolutions can be used to fix this but addition to that, try adding delay before capturing screenshots. |
Still, I am facing this problem. When I run test scenario from Github Action
|
We are using puppeteer through Gitlab CI with codeceptjs. I haven't looked at the specs of the container's spawned by the Gitlab Runner to run the jobs, but we stopped getting this issue by:
The first point was most important, the other two are mostly optimizations. |
it works for me in Windows11, thanks |
Inspired by puppeteer/puppeteer#1321 where no-sandbox option was being used - not sure why it works though
Inspired by puppeteer/puppeteer#1321 where no-sandbox option was being used - not sure why it works though
Inspired by puppeteer/puppeteer#1321 where no-sandbox option was being used - not sure why it works though
hi.. I'm getting the same error... (in kubuntu, not docker) |
Steps to reproduce
N/A (Not able to reproduce consistently.)
Tell us about your environment:
What steps will reproduce the problem?
Please include code that reproduces the issue.
What is the expected result?
No error.
What happens instead?
I am intermittently getting "Page crashed!" error.
What does the error mean?
The text was updated successfully, but these errors were encountered: