From cd64014a9d2af9ddbdcdd028283ccf646aba7225 Mon Sep 17 00:00:00 2001 From: Labrys of Knossos Date: Sun, 10 Mar 2019 10:02:58 -0400 Subject: [PATCH] Refactor ISO file matching to decode process output a single time. --- core/transcoder.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/transcoder.py b/core/transcoder.py index 42bf528e..9abc2fae 100644 --- a/core/transcoder.py +++ b/core/transcoder.py @@ -646,8 +646,8 @@ def rip_iso(item, new_dir, bitbucket): print_cmd(cmd) proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=bitbucket) out, err = proc.communicate() - file_list = [re.match(r'.+(VIDEO_TS[/\\]VTS_[0-9][0-9]_[0-9].[Vv][Oo][Bb])', line.decode()).groups()[0] for line in - out.splitlines() if re.match(r'.+VIDEO_TS[/\\]VTS_[0-9][0-9]_[0-9].[Vv][Oo][Bb]', line.decode())] + file_list = [re.match(r'.+(VIDEO_TS[/\\]VTS_[0-9][0-9]_[0-9].[Vv][Oo][Bb])', line).groups()[0] for line in + out.decode().splitlines() if re.match(r'.+VIDEO_TS[/\\]VTS_[0-9][0-9]_[0-9].[Vv][Oo][Bb]', line)] combined = [] for n in range(99): concat = []