Skip to content

Commit f62119b

Browse files
authored
Update threader.py
1 parent 068a991 commit f62119b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Interlace/lib/threader.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
import subprocess
2+
import os
23
from concurrent.futures import ThreadPoolExecutor
34
from multiprocessing import Event
4-
55
from tqdm import tqdm
66

7+
shell = os.getenv("SHELL") if os.getenv("SHELL") else "/bin/sh"
78

89
class Task(object):
910
def __init__(self, command):
@@ -49,7 +50,8 @@ def get_lock(self):
4950
def _run_task(self, t=False):
5051
s = subprocess.Popen(self.task, shell=True,
5152
stdout=subprocess.PIPE,
52-
encoding="utf-8")
53+
encoding="utf-8",
54+
executable=shell)
5355
out, _ = s.communicate()
5456

5557
if out != "":

0 commit comments

Comments
 (0)