Skip to content
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

"Chromium revision is not downloaded" Error #56

Closed
blaskovicz opened this issue Nov 8, 2019 · 4 comments
Closed

"Chromium revision is not downloaded" Error #56

blaskovicz opened this issue Nov 8, 2019 · 4 comments

Comments

@blaskovicz
Copy link

blaskovicz commented Nov 8, 2019

Hi! When I'm trying to use the buildpack on heroku, I'm seeing the following error message:

Error: Unable to launch browser for worker, error message: 
Chromium revision is not downloaded. Run "npm install" or "yarn install"

I'm using puppeteer-cluster which calls into puppeteer with the --no-sandbox argument as suggested in this buildpack's readme. Has anyone else run into this issue or know what could be going on?

  const cluster = await Cluster.launch({
    monitor: true,
    concurrency: Cluster.CONCURRENCY_BROWSER,
    // see https://devcenter.heroku.com/articles/node-concurrency
    maxConcurrency: WEB_CONCURRENCY ? +WEB_CONCURRENCY : 5,
    // see https://github.com/GoogleChrome/puppeteer/blob/v1.5.0/docs/api.md#puppeteerlaunchoptions
    puppeteerOptions: {
      // see https://peter.sh/experiments/chromium-command-line-switches/
      args: ['--no-sandbox'],
    },
  });
$ grep -i \"version\" ../../node_modules/puppeteer/package.json 
  "version": "1.15.0",
$ grep -i \"version\" ../../node_modules/puppeteer-cluster/package.json 
  "version": "0.17.0",
@jontewks
Copy link
Owner

jontewks commented Nov 8, 2019

Haven't seen it before. Is your code running ok locally?

@blaskovicz
Copy link
Author

Yes, runs locally OK and it "works" after I run yarn again inside a one-off dyno (it says lockfile saved, not sure why since when I run it locally, there are no lockfile updates).
The problem is that I would expect the heroku/nodejs buildpack to have ran yarn already. Also, I'm using lerna and this is a sub-package.

@jontewks
Copy link
Owner

I can only venture some guesses here as I've never dealt with this issue.

Is your lockfile being sent to heroku when its being pushed? It isn't part of your .gitignore correct?

I've run into weird issues in the past with caching problems, so clearing your build cache is at least worth a shot: https://help.heroku.com/18PI5RSY/how-do-i-clear-the-build-cache

Since this issue doesn't have to do with the buildpack itself, as all that is supposed to help with is getting Puppeteer running on heroku, I'm going to close the issue, but still happy to talk through it or throw out more random guesses as you try new things. Good luck!

@blaskovicz
Copy link
Author

@jontewks yes, the build is succeeding, sending the yarn.lock, and i've tried clearing the build cache. When I run yarn in the container, it's removing some versions of puppeteer:

< puppeteer@^1.7.0:
<   version "1.14.0"
<   resolved "http://artifactory.company.com/artifactory/api/npm/npm/puppeteer/-/puppeteer-1.14.0.tgz#828c1926b307200d5fc8289b99df4e13e962d339"
<   integrity sha1-gowZJrMHIA1fyCibmd9OE+li0zk=
<   dependencies:
<     debug "^4.1.0"
<     extract-zip "^1.6.6"
<     https-proxy-agent "^2.2.1"
<     mime "^2.0.3"
<     progress "^2.0.1"
<     proxy-from-env "^1.0.0"
<     rimraf "^2.6.1"
<     ws "^6.1.0"

and leaving:

puppeteer@^1.12.2:
  version "1.15.0"
  resolved "http://artifactory.company.com/artifactory/api/npm/npm/puppeteer/-/puppeteer-1.15.0.tgz#1680fac13e51f609143149a5b7fa99eec392b34f"
  integrity sha1-FoD6wT5R9gkUMUmlt/qZ7sOSs08=
  dependencies:
    debug "^4.1.0"/artifactory.company.com/artifactory/api/npm/npm/@babel/runtime/-/runtime-7.4.3.tgz#79888e452034223ad9609187a0ad1fe0d2ad4bdc"
    extract-zip "^1.6.6"
    https-proxy-agent "^2.2.1"
    mime "^2.0.3"
    progress "^2.0.1"
    proxy-from-env "^1.0.0"
    rimraf "^2.6.1"
    ws "^6.1.0"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants