Giter Club home page Giter Club logo

Comments (4)

CrazybutSolid avatar CrazybutSolid commented on June 29, 2024 4

I had to intall two buildpacks

https://github.com/heroku/heroku-buildpack-google-chrome

https://github.com/heroku/heroku-buildpack-chromedriver

and this is how I call the driver. It works now. Hope it helps.

 def self.driver_setup
    chrome_bin = ENV.fetch('GOOGLE_CHROME_SHIM', nil)


    # chrome_opts = chrome_bin ? { "chromeOptions" => { "binary" => chrome_bin } } : { args: %w[headless disable-gpu] }
    chrome_opts = chrome_bin ? { "chromeOptions" => { "binary" => chrome_bin } } : { args: %w[headless disable-gpu no-sandbox] }

    Capybara.register_driver :chrome do |app|
      Capybara::Selenium::Driver.new(
        app,
        browser: :chrome,
        desired_capabilities: Selenium::WebDriver::Remote::Capabilities.chrome(chrome_opts),
      )
    end

    Capybara.javascript_driver = :chrome

    session = Capybara::Session.new(:chrome)

  end

from heroku-buildpack-chromedriver.

jcohenho avatar jcohenho commented on June 29, 2024

Having the same issue

from heroku-buildpack-chromedriver.

CrazybutSolid avatar CrazybutSolid commented on June 29, 2024

Also, using gems:

  gem 'chromedriver-helper'
  gem "selenium-webdriver"

the webdrivers gem doesn't work for me

from heroku-buildpack-chromedriver.

edmorley avatar edmorley commented on June 29, 2024

Closing stale issues. If the issue persists with the latest version of the buildpack please open a new issue with a minimal reproducable example (but also bear in mind that this buildpack is not an officially supported buildpack, so unless there is an actual bug with the buildpack, application debugging issues are generally out of scope).

from heroku-buildpack-chromedriver.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.