fix
This commit is contained in:
1 parent
9b6fb12c8d
commit
9b3ac8878f
2 files changed
+3
-4
No files matched your search
@@ -11,7 +11,7 @@ class RmComicSpider(scrapy.Spider):
|
||||
main_url = 'https://'+allowed_domains[0]
|
||||
start_urls = main_url+'/books'
|
||||
|
||||
# 遍历网站页数
|
||||
# 遍历网站页数数据
|
||||
def start_requests(self):
|
||||
for x in range(0,60):
|
||||
yield scrapy.Request(self.start_urls+"?&page="+str(x), callback=self.books_comic)
|
||||
@@ -30,8 +30,7 @@ class RmComicSpider(scrapy.Spider):
|
||||
for chapter, link in zip(comic_item.get_chapters(), comic_item.get_chapter_href()):
|
||||
item = comic_item.load_item()
|
||||
cbz_path = ComicPath().get_file_path(item=item, result_type="cbz", convert=True, chapter=chapter)
|
||||
#if not checkUtils().is_error(item) and os.path.exists(cbz_path):
|
||||
if os.path.exists(cbz_path):
|
||||
if not checkUtils().is_error(item) and os.path.exists(cbz_path):
|
||||
logging.info(f"漫画 {cbz_path} 已存在, 跳过中...")
|
||||
yield item
|
||||
else:
|
||||
|
||||
Reference in new issue
Block a user