Skip to content

Puppeteer not working with node 14 #5719

Closed

Description

@DRoet

Steps to reproduce

Tell us about your environment:

  • Puppeteer version:3.0.1
  • Platform / OS version:docker (FROM:node:14.0.0-buster)
  • URLs (if applicable):
  • Node.js version: 14.0.0

What steps will reproduce the problem?

Please include code that reproduces the issue.

  1. Upgrade node image from 13.13.0 -> 14.0.0
  2. Run same codebase (puppeteer.launch())

What is the expected result?
code runs without issues, just like on 13.13.0

What happens instead?
Error: Failed to launch the browser process! spawn /opt/app/node_modules/puppeteer/.local-chromium/linux-737027/chrome-linux/chrome ENOENT

Activity

  1. changed the title [-]puppeteer not working with node 14[/-] [+]Puppeteer not working with node 14[/+] on Apr 22, 2020
  2. munrocket commented on Apr 22, 2020

    @munrocket
    Contributor

    @DRoet only with node 14? Try 3.0.1-post

  3. DRoet commented on Apr 22, 2020

    @DRoet
    Author

    @DRoet only with node 14?

    yes I just rebuild my images using 12.16.2 and that version also still works

  4. DRoet commented on Apr 22, 2020

    @DRoet
    Author

    Try 3.0.1-post

    how do I install this? doesn't seem to be a valid tag on the registry

  5. jsoverson commented on Apr 22, 2020

    @jsoverson
    Contributor

    It looks like it's a problem with extraction. A temporary workaround is to extract the downloaded chromium manually:

    $ mv node_modules/puppeteer/.local-chromium/mac-737027 node_modules/puppeteer/.local-chromium/mac-737027.bak 
    $ unzip node_modules/puppeteer/.local-chromium/chrome-mac.zip -d node_modules/puppeteer/.local-chromium/mac-737027
  6. nstepien commented on Apr 22, 2020

    @nstepien
  7. jackfranklin commented on Apr 23, 2020

    @jackfranklin
    Collaborator

    Thanks for the debugging all; looks like extract-zip is indeed the culprit here. It would be nice if Puppeteer gave a more helpful message than /opt/app/node_modules/puppeteer/.local-chromium/linux-737027/chrome-linux/chrome ENOENT so I'll try to look into that.

    We'll see if a fix lands in extract-zip and do some digging.

    @DRoet you can install via the master branch on GitHub to get the very latest.

  8. jackfranklin commented on Apr 24, 2020

    @jackfranklin
    Collaborator

    It also looks like the suspected bug might have been in Node: nodejs/node#32968.

    In which case we may have to sit tight for a Node patch release. In the mean time I'll see if the error message from Puppeteer can be nicer.

  9. jackfranklin commented on Apr 24, 2020

    @jackfranklin
    Collaborator

    I have opened #5732 which at least fixes the silent failures and provides a helpful message.

  10. 6 remaining items

  11. leecade commented on Apr 29, 2020

    @leecade

    same here

  12. AviVahl commented on Apr 30, 2020

    @AviVahl

    Fixed by Node 14.1.0. Verified on Linux/Mac/Windows.

  13. AviVahl commented on Apr 30, 2020

    @AviVahl

    Alright, it failed once in one of our projects because of the (node14-specific) timeout that was added to the extraction process. 10s is too low for our CI.

    Workaround bites back. Any chance for it to be removed, now that Node is fixed?

    FYI @jackfranklin

  14. DRoet commented on May 1, 2020

    @DRoet
    Author

    Can confirm it is working again on 14.1.0, but the new node14 timeout indeed fails sometimes on slower CI runs.

  15. nstepien commented on May 5, 2020

    @nstepien

    It's also intermittently failing for us because of the short timeout.

  16. AviVahl commented on May 6, 2020

    @AviVahl

    @mathiasbynens saw you've just released a patch version which still has this issue. any chance for another one with the node14-specific-timeout removed? :) this is what blocks me from adding Node 14 tests to several projects.

  17. added a commit that references this issue on May 7, 2020
    70d5c7f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions