|
@@ -13,7 +13,7 @@ class zwcontentlianshangSpider(zwcontentSpider.zwcontentSpider):
|
|
|
base_url = 'http://cp.yqsd.cn/api/book'
|
|
|
custom_settings = {
|
|
|
'DOWNLOAD_DELAY': 0.01,
|
|
|
- 'LOG_FILE': 'content_spider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
+ 'LOG_FILE': 'ydyspider/log/' + name + time.strftime("%Y-%m-%d", time.localtime()) + '.log'
|
|
|
}
|
|
|
|
|
|
def start_requests(self):
|
|
@@ -30,7 +30,7 @@ class zwcontentlianshangSpider(zwcontentSpider.zwcontentSpider):
|
|
|
i = 0
|
|
|
for item in result['data']:
|
|
|
i = i+1
|
|
|
- if i > 1000:
|
|
|
+ if i > 10:
|
|
|
break
|
|
|
bid = item['id']
|
|
|
url = self.base_url + '/bookInfo/{}'.format(bid)
|