FIX: Latest Selenium gem broke Google Groups import script

Selenium uses Keep-Alive since version 3.141, so the net-http-persistent gem shouldn't be needed anymore.
This commit is contained in:
Gerhard Schlager 2019-07-10 09:45:25 +02:00
parent 629bb8adf2
commit f0fea5991f
1 changed files with 1 additions and 4 deletions

View File

@ -6,7 +6,6 @@ require "bundler/inline"
gemfile(true) do gemfile(true) do
source "https://rubygems.org" source "https://rubygems.org"
gem "net-http-persistent"
gem "nokogiri" gem "nokogiri"
gem "webdrivers" gem "webdrivers"
end end
@ -15,7 +14,6 @@ require "fileutils"
require "nokogiri" require "nokogiri"
require "optparse" require "optparse"
require "webdrivers" require "webdrivers"
require 'selenium/webdriver/remote/http/persistent'
require "set" require "set"
require "yaml" require "yaml"
@ -26,8 +24,7 @@ def driver
chrome_args = ["headless", "disable-gpu"] chrome_args = ["headless", "disable-gpu"]
chrome_args << "no-sandbox" if inside_container? chrome_args << "no-sandbox" if inside_container?
options = Selenium::WebDriver::Chrome::Options.new(args: chrome_args) options = Selenium::WebDriver::Chrome::Options.new(args: chrome_args)
http_client = Selenium::WebDriver::Remote::Http::Persistent.new Selenium::WebDriver.for(:chrome, options: options)
Selenium::WebDriver.for(:chrome, options: options, http_client: http_client)
end end
end end