chromium: [BUG]

Environment

  • chromium Version: “@sparticuz/chromium”: “^119.0.2”,
  • puppeteer / puppeteer-core Version: “puppeteer-core”: “^21.5.0”,
  • Node.js Version: nodejs18.17.0
  • Lambda / GCF Runtime: nodejs18.x.x

Expected Behavior

Puppeteer should’ve launched normally.

Current Behavior

Recently lambdas on Nodejs18.x.x have started failing to launch the browser process for chromium with the following error: "error":{"name":"TargetCloseError","cause":{"name":"ProtocolError"}}

Spartacuz chromium v118.0.0 was previously working fine on lambdas and stopped working.

I attempted to upgrade to run on Spartacuz chromium v123, but it fails to run due to the following error: Error: spawn ETXTBSY

Steps to Reproduce

Possible Solution

Not sure, there seems to be some child process issues when loading the binary in the latest version which should be fixed.

About this issue

  • Original URL
  • State: open
  • Created 2 months ago
  • Reactions: 1
  • Comments: 15

Most upvoted comments

I had the same problem, apparently there is a new version in the lambda runtime, in this new version are needed the files that are added in version 119.0. 2 of “@sparticuz/chromium”, so if you had a version lower than this and also had to configure the version of the lambda runtime as “Auto” this will take the latest version making you generate an error when launching the browser, can be solved by updating the package “@sparticuz/chromium” to version 119.0.2 or higher (I updated to version 121), or manually adding the ARN of the previous version of the runtime.

For me, it’s fixed! Thank you

I had the same problem, apparently there is a new version in the lambda runtime, in this new version are needed the files that are added in version 119.0. 2 of “@sparticuz/chromium”, so if you had a version lower than this and also had to configure the version of the lambda runtime as “Auto” this will take the latest version making you generate an error when launching the browser, can be solved by updating the package “@sparticuz/chromium” to version 119.0.2 or higher (I updated to version 121), or manually adding the ARN of the previous version of the runtime.

I updated to 121 but then i get the error relate to Error: spawn ETXTBSY when trying to load the executable path during browser spawn process.

I’m using the following versions:

  • @sparticuz/chromium”: “121.0.0”,
  • “puppeteer-core”: “21.5.2”,
  • runtime: nodejs18.x
  • memorySize: 2048

It’s ok now for me

I had the same problem, apparently there is a new version in the lambda runtime, in this new version are needed the files that are added in version 119.0. 2 of “@sparticuz/chromium”, so if you had a version lower than this and also had to configure the version of the lambda runtime as “Auto” this will take the latest version making you generate an error when launching the browser, can be solved by updating the package “@sparticuz/chromium” to version 119.0.2 or higher (I updated to version 121), or manually adding the ARN of the previous version of the runtime.

We had the same issue happen to us this morning. We change out our versions of puppeteer-core, @sparticuz/chromium, and runtime to match the versions in the comment here 👉 https://github.com/Sparticuz/chromium/issues/270#issuecomment-2083798654.

This worked for us - thank you @joaodezembro

I had the same problem, apparently there is a new version in the lambda runtime, in this new version are needed the files that are added in version 119.0. 2 of “@sparticuz/chromium”, so if you had a version lower than this and also had to configure the version of the lambda runtime as “Auto” this will take the latest version making you generate an error when launching the browser, can be solved by updating the package “@sparticuz/chromium” to version 119.0.2 or higher (I updated to version 121), or manually adding the ARN of the previous version of the runtime.

I updated to 121 but then i get the error relate to Error: spawn ETXTBSY when trying to load the executable path during browser spawn process.

could you share with me the code with which you are running chromium to try to replicate the error?

for now you can change the runtime in the lambda configuration, you can go to the CloudWatch logs and look for a log of when the function was still running, copy the runtime arn, it is the first message that appears in those logs, then go to the function configuration, in the “Code” section look for the runtime configuration and click on edit, mark it as “Manual” and paste the ARN that you just copied.

We had the same ProtocolError in lambda Runtime Version: nodejs:16.v35 failed, nodejs:16.v33 however worked so we changed to this one for now

Error: spawn ETXTBSY

I was trying in node 18 and 20 but in both cases it worked correctly, to replicate your error I had to lower the memory allocated to 128MB and lower the timeout, maybe this is what was causing the error, could you confirm me if the memory you allocated to the lambda is higher than 512MB.

Same problem here. Was also working fine 1 month before