From b11e9db2a538b46fb416e755ac1055c45d800353 Mon Sep 17 00:00:00 2001 From: prodigysml Date: Tue, 23 Feb 2021 00:59:06 +1100 Subject: [PATCH 1/2] Changed to ensure Interlace waits for the thread to finish --- Interlace/lib/threader.py | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/Interlace/lib/threader.py b/Interlace/lib/threader.py index 1038eaa..8ba4796 100644 --- a/Interlace/lib/threader.py +++ b/Interlace/lib/threader.py @@ -47,23 +47,24 @@ class Task(object): return self.self_lock def _run_task(self, t=False): - if t: - s = subprocess.Popen(self.task, shell=True, - stdout=subprocess.PIPE, - encoding="utf-8") - out, _ = s.communicate() - if out != "": + s = subprocess.Popen(self.task, shell=True, + stdout=subprocess.PIPE, + encoding="utf-8") + out, _ = s.communicate() + + if out != "": + if t: t.write(out) - else: - subprocess.Popen(self.task, shell=True) + else: + print(out) class Worker(object): - def __init__(self, task_queue, timeout, output, tqdm): + def __init__(self, task_queue, timeout, output, tq): self.queue = task_queue self.timeout = timeout self.output = output - self.tqdm = tqdm + self.tqdm = tq def __call__(self): queue = self.queue From 69a65a9fb4844112978816d7131e0164fc620c2c Mon Sep 17 00:00:00 2001 From: prodigysml Date: Tue, 23 Feb 2021 00:59:34 +1100 Subject: [PATCH 2/2] Incremented version --- Interlace/lib/core/__version__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Interlace/lib/core/__version__.py b/Interlace/lib/core/__version__.py index 4175d39..be0b610 100644 --- a/Interlace/lib/core/__version__.py +++ b/Interlace/lib/core/__version__.py @@ -1 +1 @@ -__version__ = '1.9.2' +__version__ = '1.9.3'