Answers for "Browser: driver mechanize has been destroyed"

0

Browser: driver mechanize has been destroyed

# example_spider.rb
require 'kimurai'
require 'net/http'

class ExampleSpider < Kimurai::Base
  @name = "example_spider"
  @engine = :mechanize
  @start_urls = ["https://www.videos.com/test"]
  @config = {
    skip_request_errors: [
      { error: RuntimeError, message: "404 => Net::HTTPNotFound" }
    ]
  }

  def parse(response, url:, data: {})
    logger.info response.title
  end
end

ExampleSpider.crawl!
Posted by: Guest on September-08-2020

Code answers related to "Browser: driver mechanize has been destroyed"

Browse Popular Code Answers by Language