用python的scrapy框架爬取图片时,运行报错信息如下:
ValueError: Missing scheme in request url: //cdn.shopify.com/s/files/1/1182/9792/products/ARD1040_3_100x.jpg?v=1527112369
2018-05-24 23:02:44 [scrapy.core.scraper] ERROR: Error processing {'imageLink': u'//cdn.shopify.com/s/files/1/1182/9792/products/ARD1038_100x.jpg?v=1523948814'}
爬虫源码如下:
# -*- coding: utf-8 -*-
import scrapy
from sheergirl.items import SheergirlItem
class SheerSpider(scrapy.Spider):
name = 'sheer'
allowed_domains = ['sheergirl.com']
offset = 1
url = "https://www.sheergirl.com/collections/prom-dresses?page="
start_urls = [url + str(offset)]
def parse(self, response):
subSelector = response.xpath('//div[contains(@class,"three columns")]')
for each in su