fix
This commit is contained in:
parent
226ca3ef33
commit
5ccbacbc70
@ -59,9 +59,11 @@ class CBZUtils:
|
||||
os.remove(file)
|
||||
except:
|
||||
print(f"删除 {file} 发生错误,已跳过")
|
||||
return False
|
||||
cls.zip_compression(comicInfo.getDirComicChapter(), cls.getCBZ_Path())
|
||||
time.sleep(0.1)
|
||||
fileUtils.remove(comicInfo.getDirComic())
|
||||
return True
|
||||
|
||||
@classmethod
|
||||
def replaceZip(cls,filepath,unpack_dir=None):
|
||||
|
||||
@ -68,8 +68,7 @@ class baseComic:
|
||||
读取某章节下所有图片
|
||||
'''
|
||||
@classmethod
|
||||
def comicChapter(cls,chapter_url,scramble=None,sleep=None):
|
||||
is_next = True
|
||||
def comicChapter(cls,chapter_url,scramble=None,sleep=None,is_next=True):
|
||||
try:
|
||||
is_next = cls.Onechapter(chapter_url,scramble)
|
||||
#进入下个阶段
|
||||
@ -134,8 +133,8 @@ class baseComic:
|
||||
repeat = 1
|
||||
while is_next and repeat <= 2 and not is_unzip:
|
||||
download_images(list_img,ci.getDirComicChapter(), files_name=files_name,concurrency=10,timeout=60)
|
||||
is_next = len(",".join(os.listdir(ci.getDirComicChapter())).split(".jpg"))-1 == len(list_img)
|
||||
if is_next:
|
||||
equ_next = len(",".join(os.listdir(ci.getDirComicChapter())).split(".jpg"))-1 == len(list_img)
|
||||
if not equ_next:
|
||||
sleep_time = 3+int(repeat)*2
|
||||
time.sleep(sleep_time)
|
||||
ntfy.sendMsg(f"下载数据(不完整,{sleep_time}秒钟后尝试第{repeat}次")
|
||||
|
||||
Loading…
Reference in New Issue
Block a user