diff --git a/utils/NetUtils.py b/utils/NetUtils.py index f57e814..a9c0ba4 100644 --- a/utils/NetUtils.py +++ b/utils/NetUtils.py @@ -212,6 +212,7 @@ class downloadUtils: proxy=proxy,proxy_type=proxy_type,type=type) except: print(f"下载重试中 {file_name}={image_url}") + time.sleep(1) cls.down_queue.put([file_name,image_url,dst_dir]) @@ -253,8 +254,8 @@ class downloadUtils: #判断漫画名路径是否已存在comicname/cover.jpg, 存在跳过 path_comic_icon = ComicPath.getPathConfComicIcon() if not ciUtils.equIcon() and fu.exists(path_comic_icon): os.remove(path_comic_icon) - while fu.notExists(path_comic_icon): - cls.download_images([icon_url],ComicPath.getDirConfComic(),files_name=[ComicPath.COMIC_ICON_NAME+"."+icon_suffix]) + if fu.notExists(path_comic_icon): + cls.download_images([icon_url],ComicPath.getDirConfComic(),files_name=[ComicPath.COMIC_ICON_NAME+"."+icon_suffix],timeout=30) save_path = ComicPath.getPathCBZComicChapterIcon(icon_suffix) if is_new: #历史版本ICON