Scrapy view returns a blank page

后端 未结 1 1431
情歌与酒
情歌与酒 2021-01-27 00:15

I\'m new at Scrapy and I was just trying to scrape http://www.diseasesdatabase.com/

When I type scrapy view http://www.diseasesdatabase.com/, it displays a

1条回答
  •  不思量自难忘°
    2021-01-27 00:59

    Pretend being a real browser providing a User-Agent header:

    scrapy view http://www.diseasesdatabase.com/ -s USER_AGENT="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.130 Safari/537.36"
    

    Worked for me.

    Note that -s option here helps to override the built-in USER_AGENT setting.

    0 讨论(0)
提交回复
热议问题