from scrapy.loader.processors import MapCompose, Join from scrapy.loader import ItemLoader
l.add_xpath('title','// * [@ itemprop =“name”] [1] / text()',MapCompose(unicode.strip,unicode.title))
MapCompose(unicode.strip, unicode.title)MapCompose(float)MapCompose(lambda i: i.replace(',', ''), floatMapCompose(lambda i: urlparse.urljoin(response.url, i))
myFunction = lambda i: i.replace(',', '')
def myFunction(i):
return i.replace(',', '')