From baa5df1d0103f8136353546d2732ebd3cb0f3a2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Krzysztof=20Otr=C4=99ba?= Date: Fri, 30 Aug 2019 18:59:19 +0200 Subject: [PATCH] fixed KeyError: 'piece_size' when try to download non-optional file using '|all' --- plugins/Bigfile/BigfilePlugin.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/plugins/Bigfile/BigfilePlugin.py b/plugins/Bigfile/BigfilePlugin.py index 13270ca9..e3974ef6 100644 --- a/plugins/Bigfile/BigfilePlugin.py +++ b/plugins/Bigfile/BigfilePlugin.py @@ -753,6 +753,11 @@ class SitePlugin(object): inner_path = inner_path.replace("|all", "") file_info = self.needFileInfo(inner_path) + + # Use default function to download non-optional file + if "piece_size" not in file_info: + return super(SitePlugin, self).needFile(inner_path, *args, **kwargs) + file_size = file_info["size"] piece_size = file_info["piece_size"]