heroku / heroku-buildpack-google-chrome

Run (headless) Google Chrome on Heroku
296 stars 365 forks source link

--host-resolver-rules crashing application now #116

Open NemyaNation opened 3 years ago

NemyaNation commented 3 years ago

Following from my previous issue (thanks for replying btw..) https://github.com/heroku/heroku-buildpack-google-chrome/issues/112

Running:

require 'selenium-webdriver'

options = Selenium::WebDriver::Chrome::Options.new(args: ['headless'])

driver = Selenium::WebDriver.for(:chrome, options: options)

driver.get('http://stackoverflow.com/')

puts "source: ",driver.page_source

driver.quit

works fine on heroku.


Running

require 'selenium-webdriver'

options = Selenium::WebDriver::Chrome::Options.new(args: [
    'headless',
    'host-resolver-rules=MAP stackoverflow.com 192.0.2.1'
])

driver = Selenium::WebDriver.for(:chrome, options: options)

driver.get('http://stackoverflow.com/')

puts "source: ",driver.page_source

(notice the added option host-resolver-rules) fails miserabley with error:

Selenium::WebDriver::Error::SessionNotCreatedError (session not created
from tab crashed
(Session info: headless chrome=93.0.4577.82)):