diff --git a/hardware/Rakefile b/hardware/Rakefile index d833e56..cf1582b 100644 --- a/hardware/Rakefile +++ b/hardware/Rakefile @@ -350,7 +350,7 @@ def scrape_lcsc(sku) # the search page does not always list existing parts, instead it will try url = "https://lcsc.com/pre_search/link?type=lcsc&&value=#{sku}" puts "scraping #{url}" if $scrape_debug - doc = Nokogiri::HTML(open(URI.escape(url),:allow_redirections => :all)) + doc = Nokogiri::HTML(URI.open(url),:allow_redirections => :all) # verify if we have got a product page if doc.xpath('//div[@id="product_details"]').empty? then @@ -381,7 +381,7 @@ def scrape_aliexpress(sku) # get page url = "https://www.aliexpress.com/item/#{sku}.html" puts "scraping #{url}" if $scrape_debug - doc = Nokogiri::HTML(open(URI.escape(url),:allow_redirections => :all)) + doc = Nokogiri::HTML(URI.open(url),:allow_redirections => :all) # all the values can be found in javascript variables (stock is even only there) js_docs = doc.xpath('//script') if js_docs.empty? then