mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-07-05 14:51:28 +08:00
Merge pull request #5371 from cddjr/remove_unused_finished_files
This commit is contained in:
@@ -560,8 +560,6 @@ class TransferChain(ChainBase, metaclass=Singleton):
|
|||||||
processed_num = 0
|
processed_num = 0
|
||||||
# 失败数量
|
# 失败数量
|
||||||
fail_num = 0
|
fail_num = 0
|
||||||
# 已完成文件
|
|
||||||
finished_files = []
|
|
||||||
|
|
||||||
progress = ProgressHelper(ProgressKey.FileTransfer)
|
progress = ProgressHelper(ProgressKey.FileTransfer)
|
||||||
|
|
||||||
@@ -594,10 +592,7 @@ class TransferChain(ChainBase, metaclass=Singleton):
|
|||||||
logger.info(__process_msg)
|
logger.info(__process_msg)
|
||||||
progress.update(value=processed_num / total_num * 100,
|
progress.update(value=processed_num / total_num * 100,
|
||||||
text=__process_msg,
|
text=__process_msg,
|
||||||
data={
|
data={})
|
||||||
"current": Path(fileitem.path).as_posix(),
|
|
||||||
"finished": finished_files
|
|
||||||
})
|
|
||||||
# 整理
|
# 整理
|
||||||
state, err_msg = self.__handle_transfer(task=task, callback=item.callback)
|
state, err_msg = self.__handle_transfer(task=task, callback=item.callback)
|
||||||
if not state:
|
if not state:
|
||||||
@@ -605,7 +600,6 @@ class TransferChain(ChainBase, metaclass=Singleton):
|
|||||||
fail_num += 1
|
fail_num += 1
|
||||||
# 更新进度
|
# 更新进度
|
||||||
processed_num += 1
|
processed_num += 1
|
||||||
finished_files.append(Path(fileitem.path).as_posix())
|
|
||||||
__process_msg = f"{fileitem.name} 整理完成"
|
__process_msg = f"{fileitem.name} 整理完成"
|
||||||
logger.info(__process_msg)
|
logger.info(__process_msg)
|
||||||
progress.update(value=(processed_num / total_num) * 100,
|
progress.update(value=(processed_num / total_num) * 100,
|
||||||
|
|||||||
Reference in New Issue
Block a user